public class ResultSetOptionBuilder extends Object
Modifier and Type | Field and Description |
---|---|
protected CustomErrorContext |
errorContext
Error message context
|
protected long |
maxBatchSize |
protected ProjectionFilter |
projectionFilter |
protected RequestedTuple |
projectionSet |
protected TupleMetadata |
readerSchema |
protected int |
rowCountLimit |
protected long |
scanLimit |
protected ResultVectorCache |
vectorCache |
protected int |
vectorSizeLimit |
Constructor and Description |
---|
ResultSetOptionBuilder() |
Modifier and Type | Method and Description |
---|---|
ResultSetOptionBuilder |
batchSizeLimit(int bytes) |
ResultSetLoaderImpl.ResultSetOptions |
build() |
ResultSetOptionBuilder |
errorContext(CustomErrorContext context)
Provides context for error messages.
|
ResultSetOptionBuilder |
limit(long limit) |
ResultSetOptionBuilder |
projection(RequestedTuple projSet) |
ResultSetOptionBuilder |
projectionFilter(ProjectionFilter projectionFilter) |
ResultSetOptionBuilder |
readerSchema(TupleMetadata readerSchema)
Clients can use the row set builder in several ways:
Provide the schema up front, when known, by using this method to
provide the schema.
Discover the schema on the fly, adding columns during the write
operation.
|
ResultSetOptionBuilder |
rowCountLimit(int limit)
Specify the maximum number of rows per batch.
|
ResultSetOptionBuilder |
vectorCache(ResultVectorCache vectorCache)
Downstream operators require "vector persistence": the same vector
must represent the same column in every batch.
|
protected int vectorSizeLimit
protected int rowCountLimit
protected ResultVectorCache vectorCache
protected RequestedTuple projectionSet
protected ProjectionFilter projectionFilter
protected TupleMetadata readerSchema
protected long maxBatchSize
protected long scanLimit
protected CustomErrorContext errorContext
public ResultSetOptionBuilder rowCountLimit(int limit)
BaseValueVector.INITIAL_VALUE_ALLOCATION
. Batches end either
when this limit is reached, or when a vector overflows, whichever
occurs first. The limit is capped at ValueVector.MAX_ROW_COUNT
.limit
- the row count limitpublic ResultSetOptionBuilder batchSizeLimit(int bytes)
public ResultSetOptionBuilder vectorCache(ResultVectorCache vectorCache)
public ResultSetOptionBuilder readerSchema(TupleMetadata readerSchema)
readerSchema
- the initial schema for the loaderpublic ResultSetOptionBuilder projection(RequestedTuple projSet)
public ResultSetOptionBuilder projectionFilter(ProjectionFilter projectionFilter)
public ResultSetOptionBuilder limit(long limit)
public ResultSetOptionBuilder errorContext(CustomErrorContext context)
public ResultSetLoaderImpl.ResultSetOptions build()
Copyright © 1970 The Apache Software Foundation. All rights reserved.