@Internal public class NestedSerializersSnapshotDelegate extends Object
The NestedSerializersSnapshotDelegate does not implement the TypeSerializerSnapshot
interface. It is not meant to be inherited from, but to be composed with a serializer snapshot
implementation.
The NestedSerializersSnapshotDelegate has its own versioning internally, it does not couple its versioning to the versioning of the TypeSerializerSnapshot that builds on top of this class. That way, the NestedSerializersSnapshotDelegate and enclosing TypeSerializerSnapshot the can evolve their formats independently.
Constructor and Description |
---|
NestedSerializersSnapshotDelegate(TypeSerializer<?>... serializers)
Constructor to create a snapshot for writing.
|
Modifier and Type | Method and Description |
---|---|
TypeSerializerSnapshot<?>[] |
getNestedSerializerSnapshots()
Returns the snapshots of the nested serializers.
|
<T> TypeSerializer<T> |
getRestoredNestedSerializer(int pos)
Creates the restore serializer from the pos-th config snapshot.
|
TypeSerializer<?>[] |
getRestoredNestedSerializers()
Produces a restore serializer from each contained serializer configuration snapshot.
|
static NestedSerializersSnapshotDelegate |
legacyReadNestedSerializerSnapshots(DataInputView in,
ClassLoader cl)
Reads the composite snapshot of all the contained serializers in a way that is compatible
with Version 1 of the deprecated
CompositeTypeSerializerConfigSnapshot . |
static NestedSerializersSnapshotDelegate |
readNestedSerializerSnapshots(DataInputView in,
ClassLoader cl)
Reads the composite snapshot of all the contained serializers.
|
<T> TypeSerializerSchemaCompatibility<T> |
resolveCompatibilityWithNested(TypeSerializerSchemaCompatibility<?> outerCompatibility,
TypeSerializer<?>... newNestedSerializers)
Deprecated.
this no method will be removed in the future. Resolving compatibility for nested
serializers is now handled by
CompositeTypeSerializerSnapshot . |
void |
writeNestedSerializerSnapshots(DataOutputView out)
Writes the composite snapshot of all the contained serializers.
|
public NestedSerializersSnapshotDelegate(TypeSerializer<?>... serializers)
public TypeSerializer<?>[] getRestoredNestedSerializers()
public <T> TypeSerializer<T> getRestoredNestedSerializer(int pos)
public TypeSerializerSnapshot<?>[] getNestedSerializerSnapshots()
@Deprecated public <T> TypeSerializerSchemaCompatibility<T> resolveCompatibilityWithNested(TypeSerializerSchemaCompatibility<?> outerCompatibility, TypeSerializer<?>... newNestedSerializers)
CompositeTypeSerializerSnapshot
.public final void writeNestedSerializerSnapshots(DataOutputView out) throws IOException
IOException
public static NestedSerializersSnapshotDelegate readNestedSerializerSnapshots(DataInputView in, ClassLoader cl) throws IOException
IOException
public static NestedSerializersSnapshotDelegate legacyReadNestedSerializerSnapshots(DataInputView in, ClassLoader cl) throws IOException
CompositeTypeSerializerConfigSnapshot
.IOException
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.