Package org.apache.beam.sdk.schemas
Class GetterBasedSchemaProvider
java.lang.Object
org.apache.beam.sdk.schemas.GetterBasedSchemaProvider
- All Implemented Interfaces:
Serializable,SchemaProvider
- Direct Known Subclasses:
GetterBasedSchemaProviderV2
@Deprecated
public abstract class GetterBasedSchemaProvider
extends Object
implements SchemaProvider
Deprecated.
A
SchemaProvider base class that vends schemas and rows based on FieldValueGetters.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanDeprecated.abstract List<FieldValueGetter> fieldValueGetters(Class<?> targetClass, Schema schema) Deprecated.new implementations should overridefieldValueGetters(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationException<T> List<FieldValueGetter<@NonNull T, Object>> fieldValueGetters(TypeDescriptor<T> targetTypeDescriptor, Schema schema) Deprecated.Delegates to thefieldValueGetters(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure.abstract List<FieldValueTypeInformation> fieldValueTypeInformations(Class<?> targetClass, Schema schema) Deprecated.new implementations should overridefieldValueTypeInformations(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationExceptionfieldValueTypeInformations(TypeDescriptor<?> targetTypeDescriptor, Schema schema) Deprecated.Delegates to thefieldValueTypeInformations(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure.<T> SerializableFunction<Row, T> fromRowFunction(TypeDescriptor<T> typeDescriptor) Deprecated.Given a type, returns a function that converts from aRowobject to that type.inthashCode()Deprecated.abstract SchemaUserTypeCreatorschemaTypeCreator(Class<?> targetClass, Schema schema) Deprecated.new implementations should overrideschemaTypeCreator(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationExceptionschemaTypeCreator(TypeDescriptor<?> targetTypeDescriptor, Schema schema) Deprecated.Delegates to theschemaTypeCreator(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure.<T> SerializableFunction<T, Row> toRowFunction(TypeDescriptor<T> typeDescriptor) Deprecated.Given a type, return a function that converts that type to aRowobject If no schema exists, returns null.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.beam.sdk.schemas.SchemaProvider
schemaFor
-
Constructor Details
-
GetterBasedSchemaProvider
public GetterBasedSchemaProvider()Deprecated.
-
-
Method Details
-
fieldValueGetters
@Deprecated public abstract List<FieldValueGetter> fieldValueGetters(Class<?> targetClass, Schema schema) Deprecated.new implementations should overridefieldValueGetters(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationExceptionImplementing class should override to return FieldValueGetters. -
fieldValueGetters
public <T> List<FieldValueGetter<@NonNull T,Object>> fieldValueGetters(TypeDescriptor<T> targetTypeDescriptor, Schema schema) Deprecated.Delegates to thefieldValueGetters(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure. -
fieldValueTypeInformations
@Deprecated public abstract List<FieldValueTypeInformation> fieldValueTypeInformations(Class<?> targetClass, Schema schema) Deprecated.new implementations should overridefieldValueTypeInformations(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationExceptionImplementing class should override to return a list of type-informations. -
fieldValueTypeInformations
public List<FieldValueTypeInformation> fieldValueTypeInformations(TypeDescriptor<?> targetTypeDescriptor, Schema schema) Deprecated.Delegates to thefieldValueTypeInformations(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure. -
schemaTypeCreator
@Deprecated public abstract SchemaUserTypeCreator schemaTypeCreator(Class<?> targetClass, Schema schema) Deprecated.new implementations should overrideschemaTypeCreator(TypeDescriptor, Schema)and make this method throw anUnsupportedOperationExceptionImplementing class should override to return a constructor. -
schemaTypeCreator
public SchemaUserTypeCreator schemaTypeCreator(TypeDescriptor<?> targetTypeDescriptor, Schema schema) Deprecated.Delegates to theschemaTypeCreator(Class, Schema)for backwards compatibility, override it if you want to use the richer type signature contained in theTypeDescriptornot subject to the type erasure. -
toRowFunction
Deprecated.Description copied from interface:SchemaProviderGiven a type, return a function that converts that type to aRowobject If no schema exists, returns null.- Specified by:
toRowFunctionin interfaceSchemaProvider
-
fromRowFunction
Deprecated.Description copied from interface:SchemaProviderGiven a type, returns a function that converts from aRowobject to that type. If no schema exists, returns null.- Specified by:
fromRowFunctionin interfaceSchemaProvider
-
hashCode
public int hashCode()Deprecated. -
equals
Deprecated.
-
GetterBasedSchemaProviderV2class' methods which receiveTypeDescriptors instead of ordinaryClasses as arguments, which permits to support generic type signatures during schema inference