com.ebay.erl.mobius.core.builder
Class TSVDataset

java.lang.Object
  extended by com.ebay.erl.mobius.core.builder.Dataset
      extended by com.ebay.erl.mobius.core.builder.TSVDataset
All Implemented Interfaces:
java.io.Serializable

public class TSVDataset
extends Dataset

Represents a dataset backed with the Hadoop text format.

This product is licensed under the Apache License, Version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0. This product contains portions derived from Apache hadoop which is licensed under the Apache License, Version 2.0, available at http://hadoop.apache.org. © 2007 – 2012 eBay Inc., Evan Chiu, Woody Zhou, Neel Sundaresan

See Also:
TSVDatasetBuilder, TSVMapper, Serialized Form

Field Summary
 
Fields inherited from class com.ebay.erl.mobius.core.builder.Dataset
computedColumns, conf, input_format, job, mapper, name, schema, tupleConstraint
 
Constructor Summary
protected TSVDataset(MobiusJob job, java.lang.String name)
          Create an instance of dataset with TextInputFormat and TSVMapper as default.
 
Method Summary
 org.apache.hadoop.mapred.JobConf createJobConf(int jobSequenceNumber)
          Create a Hadoop JobConf that represents this dataset.
protected  void setInputFormat(java.lang.Class<? extends org.apache.hadoop.mapred.InputFormat> input_format)
          Always throw UnsupportedOperationException as one cannot change the input format, the input format is fixed to TextInputFormat.
protected  void setMapper(java.lang.Class<? extends AbstractMobiusMapper> mapper)
          only accept a mapper which is the subclass of TSVMapper
 
Methods inherited from class com.ebay.erl.mobius.core.builder.Dataset
addComputedColumn, equals, getDatasetID, getInputFormat, getInputs, getMapper, getName, getSchema, hashCode, initialize, orderBy, orderBy, orderBy, orderBy, setSchema, toString, validate, withinSchema
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TSVDataset

protected TSVDataset(MobiusJob job,
                     java.lang.String name)
Create an instance of dataset with TextInputFormat and TSVMapper as default.

User should not create instance of this class directly through constructor, but to use TSVDatasetBuilder to build one.

Parameters:
job - a Mobius job contains an analysis flow.
name - the name of this dataset.
Method Detail

setInputFormat

protected void setInputFormat(java.lang.Class<? extends org.apache.hadoop.mapred.InputFormat> input_format)
Always throw UnsupportedOperationException as one cannot change the input format, the input format is fixed to TextInputFormat.

Overrides:
setInputFormat in class Dataset

setMapper

protected void setMapper(java.lang.Class<? extends AbstractMobiusMapper> mapper)
only accept a mapper which is the subclass of TSVMapper

Overrides:
setMapper in class Dataset

createJobConf

public org.apache.hadoop.mapred.JobConf createJobConf(int jobSequenceNumber)
                                               throws java.io.IOException
Description copied from class: Dataset
Create a Hadoop JobConf that represents this dataset.

This method is called by Mobius.

Overrides:
createJobConf in class Dataset
Throws:
java.io.IOException