Documentation ¶
Index ¶
Constants ¶
const FromGeneratorKind = "fromGenerator"
const FromSQLKind = "fromSQL"
Variables ¶
This section is empty.
Functions ¶
func CreateSourceFromDecoder ¶
func CreateSourceFromDecoder(decoder SourceDecoder, dsid execute.DatasetID, a execute.Administration) (execute.Source, error)
CreateSourceFromDecoder takes an implementation of a SourceDecoder, as well as a dataset ID and Administration type and creates an execute.Source.
Types ¶
type FromGeneratorOpSpec ¶
type FromGeneratorOpSpec struct { Start time.Time `json:"start"` Stop time.Time `json:"stop"` Count int64 `json:"count"` Fn *semantic.FunctionExpression `json:"fn"` }
func (*FromGeneratorOpSpec) Kind ¶
func (s *FromGeneratorOpSpec) Kind() flux.OperationKind
type FromGeneratorProcedureSpec ¶
type FromGeneratorProcedureSpec struct { plan.DefaultCost Start time.Time Stop time.Time Count int64 Fn compiler.Func }
func (*FromGeneratorProcedureSpec) Copy ¶
func (s *FromGeneratorProcedureSpec) Copy() plan.ProcedureSpec
func (*FromGeneratorProcedureSpec) Kind ¶
func (s *FromGeneratorProcedureSpec) Kind() plan.ProcedureKind
type FromSQLOpSpec ¶
type FromSQLOpSpec struct { DriverName string `json:"driverName,omitempty"` DataSourceName string `json:"dataSourceName,omitempty"` Query string `json:"query,omitempty"` }
func (*FromSQLOpSpec) Kind ¶
func (s *FromSQLOpSpec) Kind() flux.OperationKind
type FromSQLProcedureSpec ¶
type FromSQLProcedureSpec struct { plan.DefaultCost DriverName string DataSourceName string Query string }
func (*FromSQLProcedureSpec) Copy ¶
func (s *FromSQLProcedureSpec) Copy() plan.ProcedureSpec
func (*FromSQLProcedureSpec) Kind ¶
func (s *FromSQLProcedureSpec) Kind() plan.ProcedureKind
type GeneratorSource ¶
type GeneratorSource struct { Start time.Time Stop time.Time Count int64 Fn compiler.Func // contains filtered or unexported fields }
func NewGeneratorSource ¶
func NewGeneratorSource(a *memory.Allocator) *GeneratorSource
func (*GeneratorSource) Connect ¶
func (s *GeneratorSource) Connect() error
func (*GeneratorSource) Fetch ¶
func (s *GeneratorSource) Fetch() (bool, error)
type SQLIterator ¶
type SQLIterator struct {
// contains filtered or unexported fields
}
func (*SQLIterator) Connect ¶
func (c *SQLIterator) Connect() error
func (*SQLIterator) Fetch ¶
func (c *SQLIterator) Fetch() (bool, error)
type SourceDecoder ¶
Source Decoder is an interface that generalizes the process of retrieving data from an unspecified data source.
Connect implements the logic needed to connect directly to the data source.
Fetch implements a single fetch of data from the source (may be called multiple times). Should return false when there is no more data to retrieve.
Decode implements the process of marshaling the data returned by the source into a flux.Table type.
In executing the retrieval process, Connect is called once at the onset, and subsequent calls of Fetch() and Decode() are called iteratively until the data source is fully consumed.