类 FileRecord

java.lang.Object
org.apache.pulsar.io.file.FileRecord
所有已实现的接口:
org.apache.pulsar.functions.api.Record<byte[]>

public class FileRecord extends Object implements org.apache.pulsar.functions.api.Record<byte[]>
Implementation of the Record interface for File Source data. - The key is set to the source file name + the line number of the record. - The value is set to the file contents for the given line number (in bytes) - The following user properties are also set: - The source file name - The absolute path of the source file - The last modified time of the source file.
  • 字段详细资料

  • 构造器详细资料

    • FileRecord

      public FileRecord(File srcFile, int lineNumber, byte[] value)
  • 方法详细资料

    • getKey

      public Optional<String> getKey()
      指定者:
      getKey 在接口中 org.apache.pulsar.functions.api.Record<byte[]>
    • getValue

      public byte[] getValue()
      指定者:
      getValue 在接口中 org.apache.pulsar.functions.api.Record<byte[]>
    • getProperties

      public Map<String,String> getProperties()
      指定者:
      getProperties 在接口中 org.apache.pulsar.functions.api.Record<byte[]>
    • setProperty

      public void setProperty(String key, String value)