Package org.apache.wayang.basic.function
Class ProjectionDescriptor<Input,Output>
java.lang.Object
org.apache.wayang.core.function.FunctionDescriptor
org.apache.wayang.core.function.TransformationDescriptor<Input,Output>
org.apache.wayang.basic.function.ProjectionDescriptor<Input,Output>
- All Implemented Interfaces:
Serializable
This descriptor pertains to projections. It takes field names of the input type to describe the projection.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.wayang.core.function.FunctionDescriptor
FunctionDescriptor.ExtendedSerializableBinaryOperator<Type>, FunctionDescriptor.ExtendedSerializableConsumer<T>, FunctionDescriptor.ExtendedSerializableFunction<Input,
Output>, FunctionDescriptor.ExtendedSerializablePredicate<T>, FunctionDescriptor.SerializableBiFunction<Input0, Input1, Output>, FunctionDescriptor.SerializableBinaryOperator<Type>, FunctionDescriptor.SerializableConsumer<T>, FunctionDescriptor.SerializableFunction<Input, Output>, FunctionDescriptor.SerializableIntUnaryOperator, FunctionDescriptor.SerializableLongUnaryOperator, FunctionDescriptor.SerializablePredicate<T>, FunctionDescriptor.SerializableToDoubleBiFunction<T, U>, FunctionDescriptor.SerializableToLongBiFunction<T, U>, FunctionDescriptor.SerializableToLongFunction<T> -
Field Summary
Fields inherited from class org.apache.wayang.core.function.TransformationDescriptor
inputType, outputType
-
Constructor Summary
ConstructorsConstructorDescriptionProjectionDescriptor
(Class<Input> inputTypeClass, Class<Output> outputTypeClass, String... fieldNames) Creates a new instance.ProjectionDescriptor
(BasicDataUnitType<Input> inputType, BasicDataUnitType<Output> outputType, String... fieldNames) Creates a new instance. -
Method Summary
Modifier and TypeMethodDescriptionstatic ProjectionDescriptor<Record,
Record> createForRecords
(RecordType inputType, String... fieldNames) Creates a new instance that specifically projectsRecord
s.Methods inherited from class org.apache.wayang.core.function.TransformationDescriptor
getInputType, getJavaImplementation, getOutputType, getSqlImplementation, toString, unchecked, withSqlImplementation
Methods inherited from class org.apache.wayang.core.function.FunctionDescriptor
getLoadProfileEstimator, getSelectivity, setLoadEstimators, setLoadProfileEstimator
-
Constructor Details
-
ProjectionDescriptor
public ProjectionDescriptor(Class<Input> inputTypeClass, Class<Output> outputTypeClass, String... fieldNames) Creates a new instance.- Parameters:
inputTypeClass
- input typeoutputTypeClass
- output typefieldNames
- names of the fields to be projected
-
ProjectionDescriptor
public ProjectionDescriptor(BasicDataUnitType<Input> inputType, BasicDataUnitType<Output> outputType, String... fieldNames) Creates a new instance.- Parameters:
inputType
- input typeoutputType
- output typefieldNames
- names of the fields to be projected
-
-
Method Details
-
createForRecords
public static ProjectionDescriptor<Record,Record> createForRecords(RecordType inputType, String... fieldNames) Creates a new instance that specifically projectsRecord
s.- Parameters:
inputType
- inputRecordType
fieldNames
- names of fields to be projected- Returns:
- the new instance
-
getFieldNames
-