Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessMethod ¶ added in v1.3.0
type AccessMethod struct {
Name string
Handler string
Params []AccessMethodParam
// CheckParams validates the combination of storage parameter values, after defaults are applied.
CheckParams func(params map[string]int64) error
}
AccessMethod is an index access method that an extension provides.
type AccessMethodParam ¶ added in v1.3.0
AccessMethodParam is an integer storage parameter that an index access method accepts.
type Aggregate ¶ added in v1.2.0
type Aggregate struct {
Name string
Parameters []Parameter
Returns string
StateType string
Transition string
Final string
Combine string
InitCond string
HasInitCond bool
}
Aggregate is an aggregate function that an extension provides.
type Control ¶
type Control struct {
DefaultVersion string
Comment string
Requires []string
Superuser bool
Trusted bool
Relocatable bool
Schema string
}
Control holds the information that an extension declares in its control file. https://www.postgresql.org/docs/15/extend-extensions.html#id-1.8.3.20.11
type Extension ¶
type Extension struct {
Name string
Control Control
Types []Type
Routines []Routine
Operators []Operator
Casts []Cast
Aggregates []Aggregate
OperatorClasses []OperatorClass
AccessMethods []AccessMethod
}
Extension is a Postgres extension that Doltgres emulates.
type Operator ¶ added in v1.2.0
type Operator struct {
Symbol string
Left string
Right string
Routine string
Commutator string
Negator string
Hashes bool
Merges bool
}
Operator is an operator that an extension provides.
type OperatorClass ¶ added in v1.3.0
type OperatorClass struct {
Name string
AccessMethods []string
// DefaultFor lists the access methods where this is the default operator class for Type.
DefaultFor []string
Type string
// DistanceType is nil when index support for the class is not yet implemented.
DistanceType vector.DistanceType
// MaxDimensions caps the dimension count of an indexed column, when positive.
MaxDimensions int32
}
OperatorClass is an operator class that an extension provides for its index access methods.
type Routine ¶
type Routine struct {
Name string
Symbol string
Parameters []Parameter
Returns string
Strict bool
Impl Function
// DistanceType is set on distance routines whose ascending order a vector index can serve.
DistanceType vector.DistanceType
}
Routine is a function that an extension provides. Symbol is its C link symbol, which is unique within the extension.
type Type ¶ added in v1.2.0
type Type struct {
Name string
Definition pgtypes.BaseTypeDefinition
Input string
Output string
Receive string
Send string
ModIn string
ModOut string
Compare string
// Codec stores values of the type natively instead of through the send and receive routines.
Codec *pgtypes.TypeCodec
}
Type is a base type that an extension provides. Definition carries every option except the support functions, which are named here.