Documentation ¶
Index ¶
- type CreateDatabaseExecutor
- type CreateTableExecutor
- type DropDatabaseExecutor
- type DropTableExecutor
- type ExecutorContext
- type ExecutorTree
- type FilterExecutor
- type IExecutor
- func ExecutorFactory(ctx *ExecutorContext, plan planners.IPlan) (IExecutor, error)
- func NewCreateDatabaseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewCreateTableExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewDropDatabaseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewDropTableExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewFilterExecutor(ctx *ExecutorContext, filter *planners.FilterPlan) IExecutor
- func NewInsertExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewLimitExecutor(ctx *ExecutorContext, plan *planners.LimitPlan) IExecutor
- func NewOrderByExecutor(ctx *ExecutorContext, plan *planners.OrderByPlan) IExecutor
- func NewProjectionExecutor(ctx *ExecutorContext, plan *planners.ProjectionPlan) IExecutor
- func NewScanExecutor(ctx *ExecutorContext, plan *planners.ScanPlan) IExecutor
- func NewSelectExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewSelectionExecutor(ctx *ExecutorContext, plan *planners.SelectionPlan) IExecutor
- func NewShowDatabasesExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewShowTablesExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- func NewSinkExecutor(ctx *ExecutorContext, plan *planners.SinkPlan) IExecutor
- func NewTableValuedFunctionExecutor(ctx *ExecutorContext, plan *planners.TableValuedFunctionPlan) IExecutor
- func NewUseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
- type InsertExecutor
- type LimitExecutor
- type OrderByExecutor
- type ProjectionExecutor
- type Result
- type ScanExecutor
- type SelectExecutor
- type SelectionExecutor
- type SinkExecutor
- type TableValuedFunctionExecutor
- type UseExecutor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateDatabaseExecutor ¶
type CreateDatabaseExecutor struct {
// contains filtered or unexported fields
}
CreateDatabaseExecutor 创建数据库的执行器
func (*CreateDatabaseExecutor) Execute ¶
func (executor *CreateDatabaseExecutor) Execute() (*Result, error)
Execute 在执行器中根据传递的参数创建数据库
func (*CreateDatabaseExecutor) String ¶
func (executor *CreateDatabaseExecutor) String() string
type CreateTableExecutor ¶
type CreateTableExecutor struct {
// contains filtered or unexported fields
}
CreateTableExecutor 创建表执行器
func (*CreateTableExecutor) Execute ¶
func (executor *CreateTableExecutor) Execute() (*Result, error)
func (*CreateTableExecutor) String ¶
func (executor *CreateTableExecutor) String() string
type DropDatabaseExecutor ¶
type DropDatabaseExecutor struct {
// contains filtered or unexported fields
}
DropDatabaseExecutor 删除数据库执行器
func (*DropDatabaseExecutor) Execute ¶
func (executor *DropDatabaseExecutor) Execute() (*Result, error)
func (*DropDatabaseExecutor) String ¶
func (executor *DropDatabaseExecutor) String() string
type DropTableExecutor ¶
type DropTableExecutor struct {
// contains filtered or unexported fields
}
DropTableExecutor 删除表的执行器
func (*DropTableExecutor) Execute ¶
func (executor *DropTableExecutor) Execute() (*Result, error)
func (*DropTableExecutor) String ¶
func (executor *DropTableExecutor) String() string
type ExecutorContext ¶
type ExecutorContext struct {
// contains filtered or unexported fields
}
ExecutorContext 执行器上下文
func NewExecutorContext ¶
func (*ExecutorContext) SetProgressCallback ¶
func (ctx *ExecutorContext) SetProgressCallback(fn func(pv *sessions.ProgressValues))
type ExecutorTree ¶
type ExecutorTree struct {
// contains filtered or unexported fields
}
ExecutorTree 是为了把select查询抽象成树方便执行吧?
func NewExecutorTree ¶
func NewExecutorTree(ctx *ExecutorContext) *ExecutorTree
NewExecutorTree 从执行上下文创建执行树
func (*ExecutorTree) BuildPipeline ¶
func (tree *ExecutorTree) BuildPipeline() (*processors.Pipeline, error)
BuildPipeline 要把父查询和的结果和子查询的输入连接起来
type FilterExecutor ¶
type FilterExecutor struct {
// contains filtered or unexported fields
}
func (*FilterExecutor) Execute ¶
func (executor *FilterExecutor) Execute() (*Result, error)
func (*FilterExecutor) String ¶
func (executor *FilterExecutor) String() string
type IExecutor ¶
type IExecutor interface { // String 执行器会有一个名字 String() string // Execute 封装真正执行的逻辑 Execute() (*Result, error) }
IExecutor 定义了执行器方法
func ExecutorFactory ¶
func ExecutorFactory(ctx *ExecutorContext, plan planners.IPlan) (IExecutor, error)
func NewCreateDatabaseExecutor ¶
func NewCreateDatabaseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewCreateTableExecutor ¶
func NewCreateTableExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewDropDatabaseExecutor ¶
func NewDropDatabaseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewDropTableExecutor ¶
func NewDropTableExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewFilterExecutor ¶
func NewFilterExecutor(ctx *ExecutorContext, filter *planners.FilterPlan) IExecutor
func NewInsertExecutor ¶
func NewInsertExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewLimitExecutor ¶
func NewLimitExecutor(ctx *ExecutorContext, plan *planners.LimitPlan) IExecutor
func NewOrderByExecutor ¶
func NewOrderByExecutor(ctx *ExecutorContext, plan *planners.OrderByPlan) IExecutor
func NewProjectionExecutor ¶
func NewProjectionExecutor(ctx *ExecutorContext, plan *planners.ProjectionPlan) IExecutor
func NewScanExecutor ¶
func NewScanExecutor(ctx *ExecutorContext, plan *planners.ScanPlan) IExecutor
func NewSelectExecutor ¶
func NewSelectExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
创建一个查询执行器
func NewSelectionExecutor ¶
func NewSelectionExecutor(ctx *ExecutorContext, plan *planners.SelectionPlan) IExecutor
func NewShowDatabasesExecutor ¶
func NewShowDatabasesExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewShowTablesExecutor ¶
func NewShowTablesExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
func NewSinkExecutor ¶
func NewSinkExecutor(ctx *ExecutorContext, plan *planners.SinkPlan) IExecutor
func NewTableValuedFunctionExecutor ¶
func NewTableValuedFunctionExecutor(ctx *ExecutorContext, plan *planners.TableValuedFunctionPlan) IExecutor
func NewUseExecutor ¶
func NewUseExecutor(ctx *ExecutorContext, plan planners.IPlan) IExecutor
type InsertExecutor ¶
type InsertExecutor struct {
// contains filtered or unexported fields
}
func (*InsertExecutor) Execute ¶
func (executor *InsertExecutor) Execute() (*Result, error)
func (*InsertExecutor) String ¶
func (executor *InsertExecutor) String() string
type LimitExecutor ¶
type LimitExecutor struct {
// contains filtered or unexported fields
}
func (*LimitExecutor) Execute ¶
func (executor *LimitExecutor) Execute() (*Result, error)
func (*LimitExecutor) String ¶
func (executor *LimitExecutor) String() string
type OrderByExecutor ¶
type OrderByExecutor struct {
// contains filtered or unexported fields
}
func (*OrderByExecutor) Execute ¶
func (executor *OrderByExecutor) Execute() (*Result, error)
func (*OrderByExecutor) String ¶
func (executor *OrderByExecutor) String() string
type ProjectionExecutor ¶
type ProjectionExecutor struct {
// contains filtered or unexported fields
}
func (*ProjectionExecutor) Execute ¶
func (executor *ProjectionExecutor) Execute() (*Result, error)
func (*ProjectionExecutor) String ¶
func (executor *ProjectionExecutor) String() string
type Result ¶
type Result struct { In processors.IProcessor Out datastreams.IDataBlockOutputStream }
Result 表示执行器的执行结果
func (*Result) SetInput ¶
func (r *Result) SetInput(in processors.IProcessor)
func (*Result) SetOutput ¶
func (r *Result) SetOutput(out datastreams.IDataBlockOutputStream)
type ScanExecutor ¶
type ScanExecutor struct {
// contains filtered or unexported fields
}
func (*ScanExecutor) Execute ¶
func (executor *ScanExecutor) Execute() (*Result, error)
func (*ScanExecutor) String ¶
func (executor *ScanExecutor) String() string
type SelectExecutor ¶
type SelectExecutor struct {
// contains filtered or unexported fields
}
查询执行器
func (*SelectExecutor) Execute ¶
func (executor *SelectExecutor) Execute() (*Result, error)
真正开始执行select查询了
func (*SelectExecutor) String ¶
func (executor *SelectExecutor) String() string
type SelectionExecutor ¶
type SelectionExecutor struct {
// contains filtered or unexported fields
}
func (*SelectionExecutor) Execute ¶
func (executor *SelectionExecutor) Execute() (*Result, error)
func (*SelectionExecutor) String ¶
func (executor *SelectionExecutor) String() string
type SinkExecutor ¶
type SinkExecutor struct {
// contains filtered or unexported fields
}
func (*SinkExecutor) Execute ¶
func (executor *SinkExecutor) Execute() (*Result, error)
func (*SinkExecutor) String ¶
func (executor *SinkExecutor) String() string
type TableValuedFunctionExecutor ¶
type TableValuedFunctionExecutor struct {
// contains filtered or unexported fields
}
TableValuedFunctionExecutor 函数执行器
func (*TableValuedFunctionExecutor) Execute ¶
func (executor *TableValuedFunctionExecutor) Execute() (*Result, error)
func (*TableValuedFunctionExecutor) String ¶
func (executor *TableValuedFunctionExecutor) String() string
type UseExecutor ¶
type UseExecutor struct {
// contains filtered or unexported fields
}
UseExecutor 切换数据库的执行器
func (*UseExecutor) String ¶
func (executor *UseExecutor) String() string
Source Files ¶
- executor.go
- executor_context.go
- executor_create_database.go
- executor_create_table.go
- executor_drop_database.go
- executor_drop_table.go
- executor_factory.go
- executor_filter.go
- executor_insert.go
- executor_limit.go
- executor_orderby.go
- executor_projection.go
- executor_scan.go
- executor_select.go
- executor_selection.go
- executor_show_databases.go
- executor_show_tables.go
- executor_sink.go
- executor_tree.go
- executor_tvf.go
- executor_use.go
Click to show internal directories.
Click to hide internal directories.