|
Spring for Apache Hadoop | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.springframework.data.hadoop.store.output.DelimitedTextFileWriter
public class DelimitedTextFileWriter
A DelimitedTextFileWriter is a DataStoreWriter implementation
able to write Strings into raw hdfs files as delimited fields.
| Field Summary | |
|---|---|
static byte[] |
CSV
CSV Mode |
static byte[] |
TAB
TAB Mode |
| Constructor Summary | |
|---|---|
DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec)
Instantiates a new delimited text file writer. |
|
DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec,
byte[] fieldDelimiter)
Instantiates a new delimited text file writer. |
|
DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec,
byte[] fieldDelimiter,
byte[] textDelimiter)
Instantiates a new delimited text file writer. |
|
| Method Summary | |
|---|---|
void |
close()
|
void |
flush()
|
void |
write(java.util.List<java.lang.String> entity)
Write an entity. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final byte[] CSV
public static final byte[] TAB
| Constructor Detail |
|---|
public DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec)
configuration - the configurationbasePath - the base pathcodec - the codec
public DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec,
byte[] fieldDelimiter)
configuration - the configurationbasePath - the base pathcodec - the codecfieldDelimiter - the field delimiter
public DelimitedTextFileWriter(org.apache.hadoop.conf.Configuration configuration,
org.apache.hadoop.fs.Path basePath,
CodecInfo codec,
byte[] fieldDelimiter,
byte[] textDelimiter)
configuration - the configurationbasePath - the base pathcodec - the codecfieldDelimiter - the field delimitertextDelimiter - the text delimiter| Method Detail |
|---|
public void write(java.util.List<java.lang.String> entity)
throws java.io.IOException
DataWriter
write in interface DataWriter<java.util.List<java.lang.String>>java.io.IOException - if an I/O error occurs
public void flush()
throws java.io.IOException
flush in interface java.io.Flushablejava.io.IOException
public void close()
throws java.io.IOException
close in interface java.io.Closeablejava.io.IOException
|
Spring for Apache Hadoop | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||