|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cascading.scheme.Scheme cascading.scheme.SequenceFile
public class SequenceFile
A SequenceFile is a type of Scheme
, which is a flat file consisting of
binary key/value pairs. This is a space and time efficient means to store data.
Constructor Summary | |
---|---|
protected |
SequenceFile()
Protected for use by TempDfs and other subclasses. |
|
SequenceFile(Fields fields)
Creates a new SequenceFile instance that stores the given field names. |
Method Summary | |
---|---|
void |
sink(TupleEntry tupleEntry,
OutputCollector outputCollector)
Method sink writes out the given Tuple instance to the outputCollector. |
void |
sinkInit(Tap tap,
JobConf conf)
Method sinkInit initializes this instance as a sink. |
Tuple |
source(Object key,
Object value)
Method source takes the given Hadoop key and value and returns a new Tuple instance. |
void |
sourceInit(Tap tap,
JobConf conf)
Method sourceInit initializes this instance as a source. |
Methods inherited from class cascading.scheme.Scheme |
---|
equals, getNumSinkParts, getSinkFields, getSourceFields, getTrace, hashCode, isSink, isSource, isSymmetrical, isWriteDirect, setNumSinkParts, setSinkFields, setSourceFields, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
protected SequenceFile()
@ConstructorProperties(value="fields") public SequenceFile(Fields fields)
fields
- Method Detail |
---|
public void sourceInit(Tap tap, JobConf conf)
Scheme
sourceInit
in class Scheme
tap
- of type Tapconf
- of type JobConfpublic void sinkInit(Tap tap, JobConf conf)
Scheme
sinkInit
in class Scheme
tap
- of type Tapconf
- of type JobConfpublic Tuple source(Object key, Object value)
Scheme
Tuple
instance.
source
in class Scheme
key
- of type WritableComparablevalue
- of type Writable
public void sink(TupleEntry tupleEntry, OutputCollector outputCollector) throws IOException
Scheme
Tuple
instance to the outputCollector.
sink
in class Scheme
outputCollector
- of type OutputCollector @throws IOException when
IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |