PgOperatorAttribute
Namespace: Ankus
Assembly: Ankus.Runtime.dll
Exposes a static method or C# operator declaration as a PostgreSQL function and a binary or prefix operator in the function’s schema. Add PgFunction to customize the backing function’s name, schema, or execution options.
[AttributeUsage(AttributeTargets.Method)]public sealed class PgOperatorAttribute : AttributeDeclares an operator using PostgreSQL’s operator punctuation syntax. C# operator declarations retain their exact implementation, including checked operators.
Inheritance: object, Attribute
Constructors
Section titled “Constructors”PgOperatorAttribute(string)
Section titled “PgOperatorAttribute(string)”Exposes a static method or C# operator declaration as a PostgreSQL function and a binary or prefix operator in the function’s schema. Add PgFunction to customize the backing function’s name, schema, or execution options.
public PgOperatorAttribute(string name)Parameters:
name — string
The unqualified SQL operator name.
Declares an operator using PostgreSQL’s operator punctuation syntax. C# operator declarations retain their exact implementation, including checked operators.
Properties
Section titled “Properties”Commutator
Section titled “Commutator”Gets or sets the operator with reversed operands. An unqualified name uses this operator’s schema.
public string? Commutator { get; set; }Value: string
Hashes
Section titled “Hashes”Gets or sets whether this binary boolean operator supports hash joins. This is a semantic promise; compatible hash operator families are declared separately.
public bool Hashes { get; set; }Value: bool
Gets or sets the dependency identifier for the operator, independently of its backing function.
public string? Id { get; set; }Value: string
JoinEstimator
Section titled “JoinEstimator”Gets or sets a join selectivity function, optionally qualified with one schema. PostgreSQL validates its signature at installation.
public string? JoinEstimator { get; set; }Value: string
Merges
Section titled “Merges”Gets or sets whether this binary boolean operator supports merge joins. This is a semantic promise; compatible B-tree operator families are declared separately.
public bool Merges { get; set; }Value: bool
Gets the operator name. A one-parameter method defines a prefix operator.
public string Name { get; }Value: string
Negator
Section titled “Negator”Gets or sets the boolean complement operator. An unqualified name uses this operator’s schema.
public string? Negator { get; set; }Value: string
Requires
Section titled “Requires”Gets or sets declarations that must precede CREATE OPERATOR.
public string[] Requires { get; set; }Value: string[]
RestrictionEstimator
Section titled “RestrictionEstimator”Gets or sets a restriction selectivity function, optionally qualified with one schema. PostgreSQL validates its signature at installation.
public string? RestrictionEstimator { get; set; }Value: string