E - public class AvroOutputFormat<E> extends org.apache.flink.api.common.io.FileOutputFormat<E> implements Serializable
FileOutputFormat for Avro records.| 限定符和类型 | 类和说明 |
|---|---|
static class |
AvroOutputFormat.Codec
Wrapper which encapsulates the supported codec and a related serialization byte.
|
| 构造器和说明 |
|---|
AvroOutputFormat(Class<E> type) |
AvroOutputFormat(org.apache.flink.core.fs.Path filePath,
Class<E> type) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
close() |
protected String |
getDirectoryFileName(int taskNumber) |
void |
open(int taskNumber,
int numTasks) |
void |
setCodec(AvroOutputFormat.Codec codec)
Set avro codec for compression.
|
void |
setSchema(org.apache.avro.Schema schema) |
void |
writeRecord(E record) |
protected String getDirectoryFileName(int taskNumber)
getDirectoryFileName 在类中 org.apache.flink.api.common.io.FileOutputFormat<E>public void setSchema(org.apache.avro.Schema schema)
public void setCodec(AvroOutputFormat.Codec codec)
codec - avro codec.public void writeRecord(E record) throws IOException
writeRecord 在接口中 org.apache.flink.api.common.io.OutputFormat<E>IOExceptionpublic void open(int taskNumber,
int numTasks)
throws IOException
open 在接口中 org.apache.flink.api.common.io.OutputFormat<E>open 在类中 org.apache.flink.api.common.io.FileOutputFormat<E>IOExceptionpublic void close()
throws IOException
close 在接口中 org.apache.flink.api.common.io.OutputFormat<E>close 在类中 org.apache.flink.api.common.io.FileOutputFormat<E>IOExceptionCopyright © 2014–2023 The Apache Software Foundation. All rights reserved.