plan

package
v0.0.0-...-c484601 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 24, 2015 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PlanTask

type PlanTask interface {
	json.Marshaler
	json.Unmarshaler
	Accept(visitor expr.Visitor) (interface{}, error)
	Clone() PlanTask
}

A PlanTask is a part of a Plan, each task may have children

type Planner

type Planner struct {
	// contains filtered or unexported fields
}

A planner creates an execution plan for a given Statement, with ability to cache plans

to be re-used. this is very simple planner, but potentially better planners with more
knowledge of schema, distributed runtimes etc could be plugged

func NewPlanner

func NewPlanner(schema string, stmt expr.SqlStatement, sys datasource.RuntimeSchema) (*Planner, error)

func (*Planner) VisitCommand

func (m *Planner) VisitCommand(stmt *expr.SqlCommand) (expr.Task, error)

func (*Planner) VisitDelete

func (m *Planner) VisitDelete(stmt *expr.SqlDelete) (expr.Task, error)

func (*Planner) VisitDescribe

func (m *Planner) VisitDescribe(stmt *expr.SqlDescribe) (expr.Task, error)

func (*Planner) VisitInsert

func (m *Planner) VisitInsert(stmt *expr.SqlInsert) (expr.Task, error)

func (*Planner) VisitPreparedStmt

func (m *Planner) VisitPreparedStmt(stmt *expr.PreparedStatement) (expr.Task, error)

func (*Planner) VisitSelect

func (m *Planner) VisitSelect(stmt *expr.SqlSelect) (expr.Task, error)

func (*Planner) VisitShow

func (m *Planner) VisitShow(stmt *expr.SqlShow) (expr.Task, error)

func (*Planner) VisitUpdate

func (m *Planner) VisitUpdate(stmt *expr.SqlUpdate) (expr.Task, error)

func (*Planner) VisitUpsert

func (m *Planner) VisitUpsert(stmt *expr.SqlUpsert) (expr.Task, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL