APISonar


com.ibm.bi.dml.lops.OutputParameters.Format.CSV

> com > ibm > bi > dml > lops > OutputParameters > Format > CSV
com APIs ibm APIs bi APIs dml APIs lops APIs OutputParameters APIs Format APIs CSV APIs

Example 1
public void setFileFormatType(FileFormatTypes type) throws LopsException 
	{
		this.formatType = type ;
		if(type == FileFormatTypes.BINARY)
			this.outParams.setFormat(Format.BINARY) ;
		else if(type == FileFormatTypes.TEXT)
			this.outParams.setFormat(Format.TEXT) ;
		else if (type == FileFormatTypes.MM)
			this.outParams.setFormat(Format.MM);
		else if (type == FileFormatTypes.CSV )
			this.outParams.setFormat(Format.CSV);
		else 
			throw new LopsException("Unexpected format: " + type);
	}
Example 2
private boolean sendWriteLopToMR(N node) 
	{
		if ( DMLScript.rtplatform == RUNTIME_PLATFORM.SINGLE_NODE )
			return false;
		N in = (N) node.getInputs().get(0);
		Format nodeFormat = node.getOutputParameters().getFormat();
		
		//send write lop to MR if (1) it is marked with exec type MR (based on its memory consumption), or
		//(2) if the input lop is in MR and the write format allows to pack it into the same job (this does
		//not apply to csv write because MR csvwrite is a separate MR job type)
		if( node.getExecType() == ExecType.MR || (in.getExecType() == ExecType.MR && nodeFormat != Format.CSV ) )
			return true;
		else
			return false;
	}