Table of Contents

Class DatasourceConnection

Namespace
YndigoBlue.Velocity.Connections
Assembly
YndigoBlue.Velocity.dll

Base class for all database connection configurations. Provides common connection properties and settings management.

public abstract class DatasourceConnection : IDatasourceConnection
Inheritance
DatasourceConnection
Implements
Derived

Remarks

This abstract class defines the core connection parameters used across all supported database types. Database-specific implementations inherit from this class and provide additional configuration options.

Constructors

DatasourceConnection()

Properties

AdvancedSettings
CommandTimeout

Gets or sets the default command timeout in seconds for database operations.

ConnectTimeout

Gets or sets the connection timeout in seconds.

ContextSettings
Database

Gets or sets the database name to connect to.

DatasourceType

Gets the type of database system for this connection.

DefaultSrid

Gets or sets the default Spatial Reference System Identifier (SRID) for geospatial operations.

EscapeIdentifiers

Gets or sets whether database identifiers (table names, column names) should be escaped.

Hostname

Gets or sets the database server hostname or IP address.

ImportBatchSize

Gets or sets the batch size for import operations.

ImportTimeout

Gets or sets the timeout in seconds for import operations.

MaxPoolSize

Gets or sets the maximum number of connections in the connection pool.

MinPoolSize

Gets or sets the minimum number of connections in the connection pool.

Password

Gets or sets the password for database authentication.

Pooling

Gets or sets whether connection pooling is enabled.

Port

Gets or sets the port number for the database server.

ReservedSettings
Username

Gets or sets the username for database authentication.

Methods

PopulateAdvancedSettings()
PopulateContextSettings()
ReadAdvancedSetting(string, bool)
ReadAdvancedSetting(string, double)
ReadAdvancedSetting(string, int)
ReadAdvancedSetting(string, float)
ReadAdvancedSetting(string, string)
ReadContextSetting(string, bool)
ReadContextSetting(string, double)
ReadContextSetting(string, int)
ReadContextSetting(string, float)
ReadContextSetting(string, string)
SetAdvancedSetting(string, string)
SetAdvancedSettings(DbConnectionStringBuilder)

Takes a connection stringbuilder object and builds up a list of advanced settings including the named properties

SetAdvancedSettings(string)

Parses and applies advanced connection string settings from a semicolon-separated key-value pair string.

SetContextSettings(string)

Takes a connection string like formatted list of key value pairs and turns them into properties, anything passed in has to be processed through a call to one of the parse functions to have it get added to the context settings.