Class DatasourceData
java.lang.Object
se.kuseman.payloadbuilder.api.catalog.DatasourceData
Data used when a catalog is asked for creation of a data source
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionextractEqualsPredicate(QualifiedName column) Convenience method for extracting a equals predicate for specific column.intReturn the node id for this datasource.Return defined options for this data sourceReturn predicates if any to push down to data source if supported by catalogReturn the projected columns needed for this data source.Return the planned schema for this data source.Return sort items if any to push down to data soource if supported by catalog.
-
Constructor Details
-
DatasourceData
-
-
Method Details
-
getNodeId
public int getNodeId()Return the node id for this datasource. The operator ID that this data source belongs to. Can be used inIStatementContext.getNodeData(Integer)to store custom data. -
getSchema
Return the planned schema for this data source. If the table was planned with a non asterisk schema then this schema should be used in the returnedTupleVector's. Otherwise this value isOptional.empty()and the actual runtime schema should be provided in tuples. -
getPredicates
Return predicates if any to push down to data source if supported by catalog -
getSortItems
Return sort items if any to push down to data soource if supported by catalog. NOTE! All or no sort items must be consumed -
getProjection
Return the projected columns needed for this data source. This is a optimization hint that can be used for catalogs that supports fetching of specific columns only like RDMBS:es. If empty then all column should be returned -
getOptions
Return defined options for this data source -
extractEqualsPredicate
Convenience method for extracting a equals predicate for specific column.Ie. select * from table t where 'val' = t.col Calling this method with value 'col' would return in the literal string expression 'val' NOTE! Mutates the
predicateslist if column was found.
-