Skip to content

DiGi.PostgreSQL.Table.Classes

github-actions[bot] edited this page Jul 15, 2026 · 2 revisions

DiGi.PostgreSQL.Table.Classes Namespace

Classes

Column Class

Represents a column in a PostgreSQL table.

public class Column : DiGi.Core.Classes.SerializableObject

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Column

Constructors

Column() Constructor

Initializes a new instance of the Column class.

public Column();

Column(Column) Constructor

Initializes a new instance of the Column class by cloning another Column instance.

public Column(DiGi.PostgreSQL.Table.Classes.Column? column);

Parameters

column Column

The source Column instance to copy values from.

Column(JsonObject) Constructor

Initializes a new instance of the Column class from a System.Text.Json.Nodes.JsonObject.

public Column(System.Text.Json.Nodes.JsonObject? jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The System.Text.Json.Nodes.JsonObject used to initialize the column properties.

Properties

Column.Category Property

Gets or sets the category of the column.

public string? Category { get; set; }

Property Value

System.String

Column.DataType Property

Gets or sets the values DataType for the column across different contexts.

public System.Nullable<DiGi.Core.Enums.DataType> DataType { get; set; }

Property Value

System.Nullable<DiGi.Core.Enums.DataType>

Column.Description Property

Gets or sets the description of the column reference.

public string? Description { get; set; }

Property Value

System.String

Column.Index Property

Gets or sets the unique identifier of the column.

public int Index { get; set; }

Property Value

System.Int32

Column.Name Property

Gets or sets the name of the column.

public string? Name { get; set; }

Property Value

System.String

Column.UniqueId Property

Gets or sets the unique identifier for the data column across different contexts.

public string? UniqueId { get; set; }

Property Value

System.String

ColumnReference Class

Represents a reference to a column in a PostgreSQL table.

public class ColumnReference : DiGi.Core.Classes.SerializableObject

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → ColumnReference

Constructors

ColumnReference() Constructor

Initializes a new instance of the ColumnReference class.

public ColumnReference();

ColumnReference(ColumnReference) Constructor

Initializes a new instance of the ColumnReference class by copying another ColumnReference instance.

public ColumnReference(DiGi.PostgreSQL.Table.Classes.ColumnReference? columnReference);

Parameters

columnReference ColumnReference

The column reference to copy.

ColumnReference(JsonObject) Constructor

Initializes a new instance of the ColumnReference class from a System.Text.Json.Nodes.JsonObject.

public ColumnReference(System.Text.Json.Nodes.JsonObject? jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object to initialize from.

Properties

ColumnReference.Category Property

Gets or sets the category of the column reference.

public string? Category { get; set; }

Property Value

System.String

ColumnReference.Description Property

Gets or sets the description of the column reference.

public string? Description { get; set; }

Property Value

System.String

ColumnReference.Id Property

Gets or sets the unique identifier of the column.

public int Id { get; set; }

Property Value

System.Int32

ColumnReference.Name Property

Gets or sets the name of the column.

public string? Name { get; set; }

Property Value

System.String

ColumnReference.TableName Property

Gets or sets the name of the table containing the column.

public string? TableName { get; set; }

Property Value

System.String

ColumnReference.UniqueId Property

Gets or sets the unique identifier for the column reference across different contexts.

public string? UniqueId { get; set; }

Property Value

System.String

FilterCondition Class

Represents a single comparison filter condition on a database column.

public class FilterCondition

Inheritance System.Object → FilterCondition

Properties

FilterCondition.ColumnUniqueId Property

Gets or sets the unique identifier of the column to filter.

public string? ColumnUniqueId { get; set; }

Property Value

System.String

FilterCondition.FilterOperator Property

Gets or sets the comparison operator to apply.

public DiGi.PostgreSQL.Table.Enums.FilterOperator FilterOperator { get; set; }

Property Value

FilterOperator

FilterCondition.Value Property

Gets or sets the value to compare against. For list operators like In or NotIn, this should be a collection of values.

public object? Value { get; set; }

Property Value

System.Object

FilterGroup Class

Represents a group of filter conditions and sub-groups combined by a logical operator.

public class FilterGroup

Inheritance System.Object → FilterGroup

Properties

FilterGroup.FilterConditions Property

Gets or sets the list of individual filter conditions within this group.

public System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.FilterCondition> FilterConditions { get; set; }

Property Value

System.Collections.Generic.List<FilterCondition>

FilterGroup.FilterGroups Property

Gets or sets the list of sub-groups nested under this group.

public System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.FilterGroup> FilterGroups { get; set; }

Property Value

System.Collections.Generic.List<FilterGroup>

FilterGroup.LogicalOperator Property

Gets or sets the logical operator (AND or OR) used to combine the elements within this group.

public DiGi.PostgreSQL.Table.Enums.FilterLogicalOperator LogicalOperator { get; set; }

Property Value

FilterLogicalOperator

PartitioningOptions<UColumn> Class

Options for configuring the partitioning of a table.

public class PartitioningOptions<UColumn>
    where UColumn : DiGi.Core.IO.Table.Interfaces.IColumn

Type parameters

UColumn

The type of the column used for partitioning, which must implement DiGi.Core.IO.Table.Interfaces.IColumn.

Inheritance System.Object → PartitioningOptions<UColumn>

Properties

PartitioningOptions<UColumn>.Column Property

Gets or sets the column used as the partition key.

public UColumn? Column { get; set; }

Property Value

UColumn

PartitioningOptions<UColumn>.DefaultSuffix Property

Gets or sets the default suffix applied to partition table names.

public string? DefaultSuffix { get; set; }

Property Value

System.String

PartitioningOptions<UColumn>.PartitioningRule Property

Gets or sets the rule used for partitioning the table.

public DiGi.PostgreSQL.Table.Classes.PartitioningRule? PartitioningRule { get; set; }

Property Value

PartitioningRule

PartitioningRule Class

Represents an abstract base class for defining partitioning rules in a PostgreSQL table.

public abstract class PartitioningRule : DiGi.Core.Classes.SerializableObject

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → PartitioningRule

Derived
↳ RangePartitioningRule
↳ ValuePartitioningRule

Constructors

PartitioningRule() Constructor

Initializes a new instance of the PartitioningRule class.

public PartitioningRule();

PartitioningRule(PartitioningRule) Constructor

Initializes a new instance of the PartitioningRule class by copying an existing partitioning rule.

public PartitioningRule(DiGi.PostgreSQL.Table.Classes.PartitioningRule partitioningRule);

Parameters

partitioningRule PartitioningRule

The source partitioning rule to copy from.

PartitioningRule(JsonObject) Constructor

Initializes a new instance of the PartitioningRule class using a JSON object.

public PartitioningRule(System.Text.Json.Nodes.JsonObject jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object containing the partitioning rule data.

RangePartitioningRule Class

Represents a base rule for range-based partitioning in PostgreSQL.

public abstract class RangePartitioningRule : DiGi.PostgreSQL.Table.Classes.PartitioningRule

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → PartitioningRule → RangePartitioningRule

Derived
↳ RangePartitioningRule<TNumber>

Constructors

RangePartitioningRule() Constructor

Initializes a new instance of the RangePartitioningRule class.

public RangePartitioningRule();

RangePartitioningRule(RangePartitioningRule) Constructor

Initializes a new instance of the RangePartitioningRule class using an existing rule.

public RangePartitioningRule(DiGi.PostgreSQL.Table.Classes.RangePartitioningRule rangePartitioningRule);

Parameters

rangePartitioningRule RangePartitioningRule

The source range partitioning rule to copy from.

RangePartitioningRule(JsonObject) Constructor

Initializes a new instance of the RangePartitioningRule class from a JSON object.

public RangePartitioningRule(System.Text.Json.Nodes.JsonObject jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object containing the rule configuration.

RangePartitioningRule<TNumber> Class

Represents a range partitioning rule for a specific numeric type.

public class RangePartitioningRule<TNumber> : DiGi.PostgreSQL.Table.Classes.RangePartitioningRule
    where TNumber : System.Numerics.INumber<TNumber>

Type parameters

TNumber

The numeric type used for the partition ranges.

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → PartitioningRule → RangePartitioningRule → RangePartitioningRule<TNumber>

Constructors

RangePartitioningRule() Constructor

Initializes a new instance of the RangePartitioningRule<TNumber> class.

public RangePartitioningRule();

RangePartitioningRule(RangePartitioningRule<TNumber>) Constructor

Initializes a new instance of the RangePartitioningRule<TNumber> class using an existing rule.

public RangePartitioningRule(DiGi.PostgreSQL.Table.Classes.RangePartitioningRule<TNumber> rangePartitioningRule);

Parameters

rangePartitioningRule DiGi.PostgreSQL.Table.Classes.RangePartitioningRule<TNumber>

The source range partitioning rule to copy from.

RangePartitioningRule(JsonObject) Constructor

Initializes a new instance of the RangePartitioningRule<TNumber> class from a JSON object.

public RangePartitioningRule(System.Text.Json.Nodes.JsonObject jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object containing the rule configuration.

Properties

RangePartitioningRule<TNumber>.Ranges Property

Gets or sets the list of ranges defined for this partitioning rule.

public System.Collections.Generic.List<DiGi.Core.Classes.Range<TNumber>>? Ranges { get; set; }

Property Value

System.Collections.Generic.List<DiGi.Core.Classes.Range<TNumber>>

Methods

RangePartitioningRule<TNumber>.GetPartitionSufix(TNumber) Method

Gets the partition suffix for a given numeric value based on the defined ranges.

public string? GetPartitionSufix(TNumber value);

Parameters

value TNumber

The numeric value to evaluate.

Returns

System.String
A string representing the partition suffix if a matching range is found; otherwise, null.

RangePartitioningRule<TNumber>.ToString(TNumber) Method

Converts a numeric value to a parametric string representation, replacing the negative sign '-' with 'm' and the decimal separator '.' with 'p'.

public static string ToString(TNumber value);

Parameters

value TNumber

The numeric value to be formatted.

Returns

System.String
A string representing the numeric value in the parametric format.

Table Class

Represents a PostgreSQL table structure and its data.

public class Table : DiGi.Core.Classes.SerializableObject

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Table

Constructors

Table() Constructor

Initializes a new instance of the Table class.

public Table();

Table(Table) Constructor

Initializes a new instance of the Table class by cloning an existing table instance.

public Table(DiGi.PostgreSQL.Table.Classes.Table? table);

Parameters

table Table

The source Table instance to clone from, or null to initialize an empty table.

Table(JsonObject) Constructor

Initializes a new instance of the Table class using the provided System.Text.Json.Nodes.JsonObject.

public Table(System.Text.Json.Nodes.JsonObject? jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The System.Text.Json.Nodes.JsonObject containing the table data, or null to initialize an empty table.

Properties

Table.Columns Property

Gets or sets the list of columns in the table.

public System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.Column?> Columns { get; set; }

Property Value

System.Collections.Generic.List<Column>

Example

[ { "Name": "Reference", "UniqueId": "reference", "Category": "Administrative" }, { "Name": "County Id", "UniqueId": "count_id", "Category": "Administrative" }, { "Name": "Floor area", "UniqueId": "floor_area", "Category": "Shape descriptors" } ]

Table.Rows Property

Gets or sets the data values in rows stored in the table.

public System.Collections.Generic.List<object?[]> Rows { get; set; }

Property Value

System.Collections.Generic.List<System.Object[]>

Example

[ [ "a71b3f91-819f-489a-93c3-a850948c60af", 10365, 308.38 ], [ "b82c4g02-920g-590b-04d4-b961059d71bg", 10366, 309.49 ] ]

TableConversionOptions<UColumn> Class

Provides options for converting a table to PostgreSQL format.

public class TableConversionOptions<UColumn>
    where UColumn : DiGi.Core.IO.Table.Interfaces.IColumn

Type parameters

UColumn

The type of column used in the table conversion, which must implement IColumn.

Inheritance System.Object → TableConversionOptions<UColumn>

Properties

TableConversionOptions<UColumn>.IdentityColumn Property

Gets or sets the column designated as the identity column.

public UColumn? IdentityColumn { get; set; }

Property Value

UColumn

TableConversionOptions<UColumn>.PartitioningOptions Property

Gets or sets the partitioning options for the table.

public DiGi.PostgreSQL.Table.Classes.PartitioningOptions<UColumn>? PartitioningOptions { get; set; }

Property Value

DiGi.PostgreSQL.Table.Classes.PartitioningOptions<UColumn>

TableConversionOptions<UColumn>.PrimaryKeyColumns Property

Gets or sets the list of columns that serve as the primary key for the table.

public System.Collections.Generic.List<UColumn>? PrimaryKeyColumns { get; set; }

Property Value

System.Collections.Generic.List<UColumn>

TableConversionOptions<UColumn>.UniqueColumns Property

Gets or sets the list of columns that are defined with unique constraints.

public System.Collections.Generic.List<UColumn>? UniqueColumns { get; set; }

Property Value

System.Collections.Generic.List<UColumn>

TablePostgreSQLConverter<UColumn> Class

Provides an abstract base class for converters that handle the translation between a DiGi.Core.IO.Table.Classes.Table<> and its PostgreSQL representation.

public abstract class TablePostgreSQLConverter<UColumn> : DiGi.PostgreSQL.Classes.PostgreSQLConverter<DiGi.Core.IO.Table.Classes.Table<UColumn>>
    where UColumn : DiGi.Core.IO.Table.Interfaces.IColumn

Type parameters

UColumn

The type of columns contained within the table, which must implement the DiGi.Core.IO.Table.Interfaces.IColumn interface.

Inheritance System.Object → DiGi.PostgreSQL.Classes.PostgreSQLConverter<DiGi.Core.IO.Table.Classes.Table<UColumn>> → TablePostgreSQLConverter<UColumn>

Constructors

TablePostgreSQLConverter(ConnectionData) Constructor

Initializes a new instance of the TablePostgreSQLConverter class using the specified connection data.

public TablePostgreSQLConverter(DiGi.PostgreSQL.Classes.ConnectionData? connectionData);

Parameters

connectionData DiGi.PostgreSQL.Classes.ConnectionData

The connection configuration details used to connect to the PostgreSQL database. This value can be null.

Properties

TablePostgreSQLConverter<UColumn>.TableConversionOptions Property

Gets the options used to configure the table conversion process.

protected abstract DiGi.PostgreSQL.Table.Classes.TableConversionOptions<UColumn>? TableConversionOptions { protected get; }

Property Value

DiGi.PostgreSQL.Table.Classes.TableConversionOptions<UColumn>

TablePostgreSQLConverter<UColumn>.TableName Property

Gets the name of the database table associated with this entity.

public abstract string TableName { get; }

Property Value

System.String

Methods

TablePostgreSQLConverter<UColumn>.DetectSeparatorAsync(NpgsqlConnection, string, object) Method

Samples partition data to dynamically detect the most common separator (comma, semicolon, or pipe).

Resolves partitioning settings dynamically from TableConversionOptions.

public System.Threading.Tasks.Task<string> DetectSeparatorAsync(Npgsql.NpgsqlConnection npgsqlConnection, string columnUniqueId, object? partitionValue=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active database connection instance.

columnUniqueId System.String

The unique identifier of the column to sample.

partitionValue System.Object

The partition key value; ignored if partitioning is disabled.

Returns

System.Threading.Tasks.Task<System.String>
A task representing the async operation, returning the detected separator character string (e.g. ",", ";", or "|").

TablePostgreSQLConverter<UColumn>.GetAggregateSummaryAsync<TColumn>(NpgsqlConnection, string, MultivalueAggregateFunction, object, string, FilterGroup) Method

Computes multi-value aggregate statistics on a specific column in a partition with optional dynamic filtering.

Resolves partitioning settings dynamically from TableConversionOptions.

public System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonNode?> GetAggregateSummaryAsync<TColumn>(Npgsql.NpgsqlConnection npgsqlConnection, string columnUniqueId, DiGi.PostgreSQL.Table.Enums.MultivalueAggregateFunction multivalueAggregateFunction, object? partitionValue=null, string? separator=null, DiGi.PostgreSQL.Table.Classes.FilterGroup? filterGroup=null)
    where TColumn : UColumn;

Type parameters

TColumn

The column type implementation.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active database connection instance.

columnUniqueId System.String

The unique identifier of the column to aggregate.

multivalueAggregateFunction MultivalueAggregateFunction

The multi-value aggregation function to perform.

partitionValue System.Object

The partition key value; ignored if partitioning is disabled.

separator System.String

The custom separator character; if null, it is dynamically detected.

filterGroup FilterGroup

The dynamic hierarchical filters to apply prior to aggregation.

Returns

System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonNode>
A task representing the async operation, returning the aggregation result as a System.Text.Json.Nodes.JsonNode.

TablePostgreSQLConverter<UColumn>.GetAggregateSummaryAsync<TColumn>(NpgsqlConnection, string, SinglevalueAggregateFunction, object, FilterGroup) Method

Computes single-value aggregate statistics on a specific column in a partition with optional dynamic filtering.

Resolves partitioning settings dynamically from TableConversionOptions.

public System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonNode?> GetAggregateSummaryAsync<TColumn>(Npgsql.NpgsqlConnection npgsqlConnection, string columnUniqueId, DiGi.PostgreSQL.Table.Enums.SinglevalueAggregateFunction singlevalueAggregateFunction, object? partitionValue=null, DiGi.PostgreSQL.Table.Classes.FilterGroup? filterGroup=null)
    where TColumn : UColumn;

Type parameters

TColumn

The column type implementation.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active database connection instance.

columnUniqueId System.String

The unique identifier of the column to aggregate.

singlevalueAggregateFunction SinglevalueAggregateFunction

The single-value aggregation function to perform.

partitionValue System.Object

The partition key value; ignored if partitioning is disabled.

filterGroup FilterGroup

The dynamic hierarchical filters to apply prior to aggregation.

Returns

System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonNode>
A task representing the async operation, returning the aggregation result as a System.Text.Json.Nodes.JsonNode.

TablePostgreSQLConverter<UColumn>.GetCategoriesAsync() Method

Asynchronously retrieves a unique set of categories from the database.

public System.Threading.Tasks.Task<System.Collections.Generic.HashSet<string>?> GetCategoriesAsync();

Returns

System.Threading.Tasks.Task<System.Collections.Generic.HashSet<System.String>>
A task that represents the asynchronous operation. The task result contains a System.Collections.Generic.HashSet<> of category strings if successful; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetCategoriesAsync(NpgsqlConnection) Method

Asynchronously retrieves a unique set of categories from the database using the provided connection.

public System.Threading.Tasks.Task<System.Collections.Generic.HashSet<string>?> GetCategoriesAsync(Npgsql.NpgsqlConnection? npgsqlConnection);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to execute the query. This value can be null.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.HashSet<System.String>>
A task that represents the asynchronous operation. The task result contains a System.Collections.Generic.HashSet<> of category strings if retrieved successfully; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByCategoriesAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of column references filtered by the specified categories.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByCategoriesAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? categories=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection to be used for the database operation.

categories System.Collections.Generic.IEnumerable<System.String>

An optional collection of category names used to filter the column references.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if successful; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByCategoriesAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of column references filtered by the specified categories.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByCategoriesAsync(System.Collections.Generic.IEnumerable<string>? categories=null);

Parameters

categories System.Collections.Generic.IEnumerable<System.String>

An optional collection of category names to filter the results. If null, the filtering criteria may be omitted.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByNamesAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of column references based on the specified names.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByNamesAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? names=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to execute the database query.

names System.Collections.Generic.IEnumerable<System.String>

An optional collection of column names to filter the search results.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByNamesAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of column references that match the specified names.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByNamesAsync(System.Collections.Generic.IEnumerable<string>? names=null);

Parameters

names System.Collections.Generic.IEnumerable<System.String>

An optional collection of column names to filter by. If null, the retrieval criteria may vary based on the underlying implementation.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByUniqueIdsAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of column references associated with the specified unique identifiers.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByUniqueIdsAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? columnUniqueIds=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to communicate with the database.

columnUniqueIds System.Collections.Generic.IEnumerable<System.String>

An optional collection of unique identifier strings used to filter the column references.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnReferencesByUniqueIdsAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of column references associated with the specified unique identifiers.

public System.Threading.Tasks.Task<System.Collections.Generic.List<DiGi.PostgreSQL.Table.Classes.ColumnReference>?> GetColumnReferencesByUniqueIdsAsync(System.Collections.Generic.IEnumerable<string>? columnUniqueIds=null);

Parameters

columnUniqueIds System.Collections.Generic.IEnumerable<System.String>

An optional collection of unique identifiers used to filter the column references. If null, the retrieval behavior is determined by the underlying data source.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<ColumnReference>>
A task that represents the asynchronous operation. The task result contains a list of ColumnReference objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsAsync() Method

Asynchronously retrieves a list of all available column definitions.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsAsync();

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects if columns are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsByCategoriesAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of columns filtered by the specified categories.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByCategoriesAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? categories=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection to be used for the database operation.

categories System.Collections.Generic.IEnumerable<System.String>

An optional collection of category names used to filter the retrieved columns.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects if successful; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsByCategoriesAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of columns filtered by the specified categories.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByCategoriesAsync(System.Collections.Generic.IEnumerable<string>? categories=null);

Parameters

categories System.Collections.Generic.IEnumerable<System.String>

An optional collection of category names to filter the columns by. If null, the filtering behavior is determined by the underlying data source.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects matching the categories, or null if no results are found.

TablePostgreSQLConverter<UColumn>.GetColumnsByNamesAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of columns filtered by the specified names.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByNamesAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? names=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to execute the database query.

names System.Collections.Generic.IEnumerable<System.String>

An optional collection of column names to retrieve. If null, the filter may be ignored or return no results depending on the underlying implementation.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects if successful; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsByNamesAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of columns filtered by the specified names.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByNamesAsync(System.Collections.Generic.IEnumerable<string>? names=null);

Parameters

names System.Collections.Generic.IEnumerable<System.String>

An optional collection of column names to retrieve. If null, the behavior depends on the underlying data source implementation.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects if matches are found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsByUniqueIdsAsync(NpgsqlConnection, IEnumerable<string>) Method

Asynchronously retrieves a list of columns based on their unique identifiers.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByUniqueIdsAsync(Npgsql.NpgsqlConnection? npgsqlConnection, System.Collections.Generic.IEnumerable<string>? columnUniqueIds=null);

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to execute the database query.

columnUniqueIds System.Collections.Generic.IEnumerable<System.String>

An optional collection of unique identifier strings used to filter the results.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects if found; otherwise, null.

TablePostgreSQLConverter<UColumn>.GetColumnsByUniqueIdsAsync(IEnumerable<string>) Method

Asynchronously retrieves a list of columns based on the provided unique identifiers.

public System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>?> GetColumnsByUniqueIdsAsync(System.Collections.Generic.IEnumerable<string>? columnUniqueIds=null);

Parameters

columnUniqueIds System.Collections.Generic.IEnumerable<System.String>

An optional collection of unique identifier strings used to filter the columns. If null, the behavior is determined by the underlying data source.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.List<UColumn>>
A task that represents the asynchronous operation. The task result contains a list of UColumn objects matching the specified identifiers, or null if no matches are found.

TablePostgreSQLConverter<UColumn>.GetHistogramSummaryAsync<TColumn>(NpgsqlConnection, string, int, object, FilterGroup) Method

Generates a value distribution histogram for a specific column in a partition with optional dynamic filtering.

Resolves partitioning settings dynamically from TableConversionOptions.

public System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonArray?> GetHistogramSummaryAsync<TColumn>(Npgsql.NpgsqlConnection npgsqlConnection, string columnUniqueId, int bucketCount, object? partitionValue=null, DiGi.PostgreSQL.Table.Classes.FilterGroup? filterGroup=null)
    where TColumn : UColumn;

Type parameters

TColumn

The type of column, which must implement UColumn.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active database connection instance.

columnUniqueId System.String

The unique identifier of the column to aggregate.

bucketCount System.Int32

The total number of buckets to segment the value range into.

partitionValue System.Object

The partition key value; ignored if partitioning is disabled.

filterGroup FilterGroup

The dynamic hierarchical filters to apply prior to aggregation.

Returns

System.Threading.Tasks.Task<System.Text.Json.Nodes.JsonArray>
A task representing the async operation, returning the histogram data as a System.Text.Json.Nodes.JsonArray.

TablePostgreSQLConverter<UColumn>.GetUniqueValuesAsync<T>(NpgsqlConnection, string, FilterGroup) Method

Retrieves a distinct list of values from a specified column in the database.

public System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<T?>?> GetUniqueValuesAsync<T>(Npgsql.NpgsqlConnection? npgsqlConnection, string? columnUniqueId, DiGi.PostgreSQL.Table.Classes.FilterGroup? filterGroup=null);

Type parameters

T

The target type for the retrieved values.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active PostgreSQL connection instance.

columnUniqueId System.String

The name of the database column to query.

filterGroup FilterGroup

The optional hierarchical filters to apply prior to retrieving the unique values.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<T>>
An enumerable containing unique values from the column, or null if input is invalid.

TablePostgreSQLConverter<UColumn>.GetUniqueValuesAsync<T>(string, FilterGroup) Method

Asynchronously retrieves a collection of unique values associated with the specified identifier.

public System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<T?>?> GetUniqueValuesAsync<T>(string? columnUniqueId, DiGi.PostgreSQL.Table.Classes.FilterGroup? filterGroup=null);

Type parameters

T

The type of the elements contained in the returned collection.

Parameters

columnUniqueId System.String

The unique identifier of the column used to query for the values; may be null.

filterGroup FilterGroup

The optional hierarchical filters to apply prior to retrieving the unique values.

Returns

System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<T>>
A task that represents the asynchronous operation. The task result contains an enumerable collection of nullable values of type T, or null if the operation cannot be completed or no data is found.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(Table<TColumn,TRow>, FilterGroup, int) Method

Asynchronously pulls data from the database for the specified table using a filter group.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, DiGi.PostgreSQL.Table.Classes.FilterGroup filterGroup, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance to pull data for. This value can be null.

filterGroup FilterGroup

The filter group used to restrict the data retrieved from the database.

batchSize System.Int32

The maximum number of rows to retrieve in each batch. The default value is 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result contains true if the data was pulled successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(Table<TColumn,TRow>, int) Method

Asynchronously pulls data from the database for the specified table using a defined batch size.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance to pull data for. This value can be null.

batchSize System.Int32

The number of records to retrieve in each batch. The default value is 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result contains true if the data was pulled successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(Table<TColumn,TRow>, string, object) Method

Asynchronously pulls specific data from the specified table based on a unique column value.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, string columnUniqueId, object? value)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance from which data is being pulled. May be null.

columnUniqueId System.String

The unique identifier of the column used to filter the data.

value System.Object

The value used to identify the record to pull. May be null.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the pull operation completed successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, FilterGroup, int) Method

Asynchronously pulls data from the specified table using the provided Npgsql connection, applying a filter group in batches.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(Npgsql.NpgsqlConnection? npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, DiGi.PostgreSQL.Table.Classes.FilterGroup filterGroup, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql database connection to use for the operation. May be null.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance from which data is being pulled. May be null.

filterGroup FilterGroup

The filter group used to restrict the data retrieved from the database.

batchSize System.Int32

The maximum number of rows to retrieve in each batch. The default value is 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the pull operation completed successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, int) Method

Asynchronously pulls data from the specified table using the provided Npgsql connection in batches.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(Npgsql.NpgsqlConnection? npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql database connection to use for the operation. May be null.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance from which data is being pulled. May be null.

batchSize System.Int32

The number of records to process per batch. Defaults to 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the pull operation completed successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, string, object) Method

Asynchronously pulls specific data from the specified table based on a unique column value using the provided PostgreSQL connection.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(Npgsql.NpgsqlConnection? npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, string columnUniqueId, object? value)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The PostgreSQL connection to be used for the operation. May be null.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance from which data is being pulled. May be null.

columnUniqueId System.String

The unique identifier of the column used to filter the data.

value System.Object

The value used to identify the record to pull. May be null.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the pull operation completed successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, string, object, int, object) Method

Asynchronously pulls a chunk of data from a table using keyset (cursor-based) pagination.

Resolves partitioning settings dynamically from TableConversionOptions.

public System.Threading.Tasks.Task<bool> PullAsync<TColumn,TRow>(Npgsql.NpgsqlConnection npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, string seekColumnUniqueId, object? lastSeekValue, int pageSize, object? partitionValue=null)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of column, which must implement UColumn.

TRow

The type of row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The active database connection instance.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance to populate with page data.

seekColumnUniqueId System.String

The unique identifier of the column to sort and seek by.

lastSeekValue System.Object

The seek column value of the last row from the previous page.

pageSize System.Int32

The maximum number of records to retrieve in this page.

partitionValue System.Object

The partition key value; ignored if partitioning is disabled.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task representing the asynchronous operation, returning true if successful; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TObject,TColumn,TRow>(Table<TColumn,TRow>, string, IEnumerable<TObject>) Method

Asynchronously pulls specific data from the specified table based on unique column values.

public System.Threading.Tasks.Task<bool> PullAsync<TObject,TColumn,TRow>(DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, string columnUniqueId, System.Collections.Generic.IEnumerable<TObject>? values)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TObject

The type of the values used for filtering.

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance from which data is being pulled. May be null.

columnUniqueId System.String

The unique identifier of the column used to filter the data.

values System.Collections.Generic.IEnumerable<TObject>

A collection of values used to identify the records to pull. May be null.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the pull operation completed successfully; otherwise, false.

TablePostgreSQLConverter<UColumn>.PullAsync<TObject,TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, string, IEnumerable<TObject>) Method

Asynchronously pulls specific data from the specified table based on unique column values.

public System.Threading.Tasks.Task<bool> PullAsync<TObject,TColumn,TRow>(Npgsql.NpgsqlConnection? npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, string columnUniqueId, System.Collections.Generic.IEnumerable<TObject>? values)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TObject

The type of the values being used for the pull operation.

TColumn

The type of columns in the table, which must inherit from UColumn.

TRow

The type of rows in the table, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The PostgreSQL connection to be used for the operation.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table object from which data is being pulled.

columnUniqueId System.String

The unique identifier of the column used to filter or identify the data.

values System.Collections.Generic.IEnumerable<TObject>

A collection of values associated with the specified column unique ID.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result contains a System.Boolean value indicating whether the pull operation was successful.

TablePostgreSQLConverter<UColumn>.PushAsync<TColumn,TRow>(Table<TColumn,TRow>, int) Method

Asynchronously pushes the contents of the specified table to the database using batch processing.

public System.Threading.Tasks.Task<bool> PushAsync<TColumn,TRow>(DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table instance containing the data to be pushed. This value can be null.

batchSize System.Int32

The number of records to process in each batch. The default value is 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result contains true if the push operation was successful; otherwise, false.

TablePostgreSQLConverter<UColumn>.PushAsync<TColumn,TRow>(NpgsqlConnection, Table<TColumn,TRow>, int) Method

Asynchronously pushes data from the specified table to the database using the provided Npgsql connection.

public System.Threading.Tasks.Task<bool> PushAsync<TColumn,TRow>(Npgsql.NpgsqlConnection? npgsqlConnection, DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>? table, int batchSize=1000)
    where TColumn : UColumn
    where TRow : DiGi.Core.IO.Table.Interfaces.IRow<TRow>;

Type parameters

TColumn

The type of the column, which must derive from UColumn.

TRow

The type of the row, which must implement DiGi.Core.IO.Table.Interfaces.IRow<>.

Parameters

npgsqlConnection Npgsql.NpgsqlConnection

The Npgsql connection instance used to communicate with the database. May be null.

table DiGi.Core.IO.Table.Classes.Table<TColumn,TRow>

The table containing the data to be pushed. May be null.

batchSize System.Int32

The number of records to process per batch. Defaults to 1000.

Returns

System.Threading.Tasks.Task<System.Boolean>
A task that represents the asynchronous operation. The task result is true if the data was successfully pushed; otherwise, false.

ValuePartitioningRule Class

Represents a partitioning rule based on specific values.

public class ValuePartitioningRule : DiGi.PostgreSQL.Table.Classes.PartitioningRule

Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → PartitioningRule → ValuePartitioningRule

Constructors

ValuePartitioningRule() Constructor

Initializes a new instance of the ValuePartitioningRule class.

public ValuePartitioningRule();

ValuePartitioningRule(ValuePartitioningRule) Constructor

Initializes a new instance of the ValuePartitioningRule class using an existing partitioning rule.

public ValuePartitioningRule(DiGi.PostgreSQL.Table.Classes.ValuePartitioningRule valuePartitioningRule);

Parameters

valuePartitioningRule ValuePartitioningRule

The source partitioning rule to copy from.

ValuePartitioningRule(JsonObject) Constructor

Initializes a new instance of the ValuePartitioningRule class using a JSON object.

public ValuePartitioningRule(System.Text.Json.Nodes.JsonObject jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object containing the rule definition.

Clone this wiki locally