drm

package
v0.3.293 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2023 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DRMConfig

type DRMConfig interface {
	ColumnsToRelationalColumns(cols []internaldto.ColumnMetadata) []relationaldto.RelationalColumn
	ColumnToRelationalColumn(cols internaldto.ColumnMetadata) relationaldto.RelationalColumn
	ExtractFromGolangValue(interface{}) interface{}
	ExtractObjectFromSQLRows(r *sql.Rows, nonControlColumns []internaldto.ColumnMetadata, stream streaming.MapStream) (map[string]map[string]interface{}, map[int]map[int]interface{})
	GetCurrentTable(internaldto.HeirarchyIdentifiers) (internaldto.DBTable, error)
	GetRelationalType(string) string
	GenerateDDL(util.AnnotatedTabulation, *openapistackql.OperationStore, int, bool) ([]string, error)
	GetControlAttributes() sqlcontrol.ControlAttributes
	GetGolangValue(string) interface{}
	GetGolangSlices([]internaldto.ColumnMetadata) ([]interface{}, []string)
	GetNamespaceCollection() tablenamespace.TableNamespaceCollection
	GetParserTableName(internaldto.HeirarchyIdentifiers, int) sqlparser.TableName
	GetSQLSystem() sql_system.SQLSystem
	GetTable(internaldto.HeirarchyIdentifiers, int) (internaldto.DBTable, error)
	GenerateInsertDML(util.AnnotatedTabulation, *openapistackql.OperationStore, internaldto.TxnControlCounters) (PreparedStatementCtx, error)
	GenerateSelectDML(util.AnnotatedTabulation, internaldto.TxnControlCounters, string, string) (PreparedStatementCtx, error)
	ExecuteInsertDML(sqlengine.SQLEngine, PreparedStatementCtx, map[string]interface{}, string) (sql.Result, error)
	OpenapiColumnsToRelationalColumns(cols []openapistackql.ColumnDescriptor) []relationaldto.RelationalColumn
	OpenapiColumnsToRelationalColumn(col openapistackql.ColumnDescriptor) relationaldto.RelationalColumn
	QueryDML(sqlmachinery.Querier, PreparedStatementParameterized) (*sql.Rows, error)
}

func GetDRMConfig

func GetDRMConfig(sqlSystem sql_system.SQLSystem, namespaceCollection tablenamespace.TableNamespaceCollection, controlAttributes sqlcontrol.ControlAttributes) (DRMConfig, error)

type PreparedStatementArgs

type PreparedStatementArgs interface {
	Analyze() error

	GetArgs() []interface{}
	GetChild(int) PreparedStatementArgs
	GetChildren() map[int]PreparedStatementArgs
	GetExpandedArgs() []interface{}
	GetExpandedQuery() string
	GetQuery() string
	SetArgs([]interface{})
	SetChild(int, PreparedStatementArgs)
	// contains filtered or unexported methods
}

func NewPreparedStatementArgs

func NewPreparedStatementArgs(query string) PreparedStatementArgs

type PreparedStatementCtx

type PreparedStatementCtx interface {
	GetAllCtrlCtrs() []internaldto.TxnControlCounters
	GetGCCtrlCtrs() internaldto.TxnControlCounters
	GetIndirectContexts() []PreparedStatementCtx
	GetNonControlColumns() []internaldto.ColumnMetadata
	GetGCHousekeepingQueries() string
	GetQuery() string
	SetGCCtrlCtrs(tcc internaldto.TxnControlCounters)
	SetIndirectContexts(indirectContexts []PreparedStatementCtx)
	SetKind(kind string)
}

func NewPreparedStatementCtx

func NewPreparedStatementCtx(
	query string,
	kind string,
	genIdControlColName string,
	sessionIdControlColName string,
	tableNames []string,
	txnIdControlColName string,
	insIdControlColName string,
	insEncodedColName string,
	nonControlColumns []internaldto.ColumnMetadata,
	ctrlColumnRepeats int,
	txnCtrlCtrs internaldto.TxnControlCounters,
	secondaryCtrs []internaldto.TxnControlCounters,
	namespaceCollection tablenamespace.TableNamespaceCollection,
	sqlSystem sql_system.SQLSystem,
) PreparedStatementCtx

func NewQueryOnlyPreparedStatementCtx

func NewQueryOnlyPreparedStatementCtx(query string, nonControlCols []internaldto.ColumnMetadata) PreparedStatementCtx

type PreparedStatementParameterized

type PreparedStatementParameterized interface {
	AddChild(int, PreparedStatementParameterized)
	GetArgs() map[string]interface{}
	GetChildren() map[int]PreparedStatementParameterized
	GetCtx() PreparedStatementCtx
	GetRequestEncoding() string
	IsControlArgsRequired() bool
	WithRequestEncoding(string) PreparedStatementParameterized
}

func NewPreparedStatementParameterized

func NewPreparedStatementParameterized(ctx PreparedStatementCtx, args map[string]interface{}, controlArgsRequired bool) PreparedStatementParameterized

Jump to

Keyboard shortcuts

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