TKey
- Key typeTValue
- Tuple typeT
- Writable node tuple typepublic abstract class AbstractLineBasedNodeTupleWriter<TKey,TValue,T extends AbstractNodeTupleWritable<TValue>>
extends org.apache.hadoop.mapreduce.RecordWriter<TKey,T>
The implementation only writes the value portion of the key value pair since it is the value portion that is used to convey the node tuples
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_SEPARATOR
Default separator written between nodes
|
static String |
DEFAULT_TERMINATOR
Default terminator written at the end of each line
|
Constructor and Description |
---|
AbstractLineBasedNodeTupleWriter(Writer writer)
Creates a new tuple writer using the default NTriples node formatter
|
AbstractLineBasedNodeTupleWriter(Writer writer,
NodeFormatter formatter)
Creates a new tuple writer
|
Modifier and Type | Method and Description |
---|---|
void |
close(org.apache.hadoop.mapreduce.TaskAttemptContext context) |
void |
write(TKey key,
T value) |
public static final String DEFAULT_SEPARATOR
public static final String DEFAULT_TERMINATOR
public AbstractLineBasedNodeTupleWriter(Writer writer)
writer
- Writerpublic AbstractLineBasedNodeTupleWriter(Writer writer, NodeFormatter formatter)
writer
- Writerformatter
- Node formatterpublic void write(TKey key, T value)
write
in class org.apache.hadoop.mapreduce.RecordWriter<TKey,T extends AbstractNodeTupleWritable<TValue>>
public void close(org.apache.hadoop.mapreduce.TaskAttemptContext context)
close
in class org.apache.hadoop.mapreduce.RecordWriter<TKey,T extends AbstractNodeTupleWritable<TValue>>
Licenced under the Apache License, Version 2.0