Class StreamElementSerializer<T>

java.lang.Object
org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
org.apache.flink.streaming.runtime.streamrecord.StreamElementSerializer<T>
Type Parameters:
T - The type of value in the StreamRecord
All Implemented Interfaces:
Serializable

@Internal public final class StreamElementSerializer<T> extends org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
Serializer for StreamRecord, Watermark, LatencyMarker, and WatermarkStatus.

This does not behave like a normal TypeSerializer, instead, this is only used at the stream task/operator level for transmitting StreamRecords and Watermarks.

See Also:
  • Constructor Details

    • StreamElementSerializer

      public StreamElementSerializer(org.apache.flink.api.common.typeutils.TypeSerializer<T> serializer)
  • Method Details

    • getContainedTypeSerializer

      public org.apache.flink.api.common.typeutils.TypeSerializer<T> getContainedTypeSerializer()
    • isImmutableType

      public boolean isImmutableType()
      Specified by:
      isImmutableType in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • duplicate

      public StreamElementSerializer<T> duplicate()
      Specified by:
      duplicate in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • createInstance

      public StreamRecord<T> createInstance()
      Specified by:
      createInstance in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • getLength

      public int getLength()
      Specified by:
      getLength in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • copy

      public StreamElement copy(StreamElement from)
      Specified by:
      copy in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • copy

      public StreamElement copy(StreamElement from, StreamElement reuse)
      Specified by:
      copy in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • copy

      public void copy(org.apache.flink.core.memory.DataInputView source, org.apache.flink.core.memory.DataOutputView target) throws IOException
      Specified by:
      copy in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
      Throws:
      IOException
    • serialize

      public void serialize(StreamElement value, org.apache.flink.core.memory.DataOutputView target) throws IOException
      Specified by:
      serialize in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
      Throws:
      IOException
    • deserialize

      public StreamElement deserialize(org.apache.flink.core.memory.DataInputView source) throws IOException
      Specified by:
      deserialize in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
      Throws:
      IOException
    • deserialize

      public StreamElement deserialize(StreamElement reuse, org.apache.flink.core.memory.DataInputView source) throws IOException
      Specified by:
      deserialize in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
      Throws:
      IOException
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>
    • snapshotConfiguration

      Specified by:
      snapshotConfiguration in class org.apache.flink.api.common.typeutils.TypeSerializer<StreamElement>