Class ListViewSerializer<T>

  • Type Parameters:
    T - The type of element in the list.
    All Implemented Interfaces:
    Serializable, org.apache.flink.api.common.typeutils.LegacySerializerSnapshotTransformer<ListView<T>>

    @Internal
    @Deprecated
    public class ListViewSerializer<T>
    extends org.apache.flink.api.common.typeutils.TypeSerializer<ListView<T>>
    implements org.apache.flink.api.common.typeutils.LegacySerializerSnapshotTransformer<ListView<T>>
    Deprecated.
    A serializer for [[ListView]]. The serializer relies on an element serializer for the serialization of the list's elements.

    The serialization format for the list is as follows: four bytes for the length of the list, followed by the serialized representation of each element.

    See Also:
    Serialized Form
    • Constructor Detail

      • ListViewSerializer

        public ListViewSerializer​(org.apache.flink.api.common.typeutils.TypeSerializer<List<T>> listSerializer)
        Deprecated.
    • Method Detail

      • isImmutableType

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

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

        public ListView<T> createInstance()
        Deprecated.
        Specified by:
        createInstance in class org.apache.flink.api.common.typeutils.TypeSerializer<ListView<T>>
      • copy

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

        public ListView<T> copy​(ListView<T> from,
                                ListView<T> reuse)
        Deprecated.
        Specified by:
        copy in class org.apache.flink.api.common.typeutils.TypeSerializer<ListView<T>>
      • getLength

        public int getLength()
        Deprecated.
        Specified by:
        getLength in class org.apache.flink.api.common.typeutils.TypeSerializer<ListView<T>>
      • serialize

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

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

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

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

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

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

        public org.apache.flink.api.common.typeutils.TypeSerializerSnapshot<ListView<T>> snapshotConfiguration()
        Deprecated.
        Specified by:
        snapshotConfiguration in class org.apache.flink.api.common.typeutils.TypeSerializer<ListView<T>>
      • transformLegacySerializerSnapshot

        public <U> org.apache.flink.api.common.typeutils.TypeSerializerSnapshot<ListView<T>> transformLegacySerializerSnapshot​(org.apache.flink.api.common.typeutils.TypeSerializerSnapshot<U> legacySnapshot)
        Deprecated.
        We need to override this as a LegacySerializerSnapshotTransformer because in Flink 1.6.x and below, this serializer was incorrectly returning directly the snapshot of the nested list serializer as its own snapshot.

        This method transforms the incorrect list serializer snapshot to be a proper ListViewSerializerSnapshot.

        Specified by:
        transformLegacySerializerSnapshot in interface org.apache.flink.api.common.typeutils.LegacySerializerSnapshotTransformer<T>
      • getListSerializer

        public org.apache.flink.api.common.typeutils.TypeSerializer<List<T>> getListSerializer()
        Deprecated.