This base class implements access to objects, with a primary and secondary key (composite) and with an identity column. This base class is not intended for use by application data providers. These use one of the more specialized derived classes instead.
Namespace: YetaWF.DataProvider.SQL
Assembly: YetaWF.DataProvider.SQL
Inheritance
public class SQLSimpleIdentityObjectBase<KEYTYPE,KEYTYPE2,OBJTYPE> : YetaWF.DataProvider.SQL.SQLSimpleObjectBase<KEYTYPE,KEYTYPE2,OBJTYPE>, YetaWF.Core.DataProvider.IDataProviderIdentity<KEYTYPE,KEYTYPE2,OBJTYPE>;
This class cannot be instantiated.
Cacheable | Defines whether the data is cacheable. This corresponds to the Cacheable parameter of the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method. | |
Conn | The underlying Microsoft.Data.SqlClient.SqlConnection object used to connect to the database. | |
ConnDynamic | Dynamically allocated SQL connection with a use count, otherwise it's explicitly allocated. | |
ConnectionString | Defines the SQL connection string used by this data provider. | |
Database | The database used by this data provider. This information is extracted from the SQL connection string. | |
Dataset | The dataset provided to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider was created. | |
Dbo | Defines the database owner used by this data provider. | |
HasKey2 | Defines whether the model defines a secondary key. | |
IdentityColumn | Defines the column name of the identity column used in tables. Not all tables use an identity column. | |
IdentityName | The column name of the identity column. | |
IdentitySeed | The initial value of the identity seed. The default value is defined by YetaWF.Core.DataProvider.DataProviderImpl.IDENTITY_SEED, but this can be overridden by passing an optional IdentitySeed parameter to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider is created. | |
Key1Name | The column name of the primary key. | |
Key2Name | The column name of the secondary key. | |
Languages | Defines the languages supported by the data provider. If NoLanguages is true, no language data is available. Otherwise, the languages supported are identical to collection of active languages defined by YetaWF.Core.Models.MultiString.Languages. | |
Logging | Defines whether logging is wanted for the data provider. The default value is false, but this can be overridden by passing an optional Logging parameter to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider is created. | |
NoLanguages | Defines whether language support (for YetaWF.Core.Models.MultiString) is wanted for the data provider. The default is true. This can be overridden by passing an optional NoLanguages parameter to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider is created. | |
Options | A dictionary of options and optional parameters as provided to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider was created. | |
Package | The package implementing the data provider. | |
SiteColumn | Defines the column name used to associate a site with a data record. The __Site column contains the site ID, or 0 if there is no associated site. Not all tables use the __Site column. | |
SiteIdentity | The site identity provided to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider was created. This may be 0 if no specific site is associated with the data provider. | |
SubTableKeyColumn | Defines the column name in subtables to connect a subtable and its records to the main table. The __Key column in a subtable contains the identity column used in the main table, used to join record data across tables. | |
WebConfigArea | The section in AppSettings.json, where SQL connection string, database owner, etc. are located. WebConfigArea is normally not specified and all connection information is derived from the AppSettings.json section that corresponds to the table name used by the data provider. This can be overridden by passing an optional WebConfigArea parameter to the YetaWF.Core.DataProvider.DataProviderImpl.MakeDataProvider method when the data provider is created. | |
CalculatedPropertyCallbackAsync | An optional callback which is called whenever an object is retrieved to update some properties. | |
IdentityNameOrDefault | Returns the identity column name or the default identity column name for the current object type. |
DefaultString | Defines the default key used in appsettings.json. | |
ExternalName | Defines the name of the SQL low-level data provider. This name is used in AppSettings.json ("IOMode": "SQL"). | |
SQLConnectString | Defines the key used in AppSettings.json to define a SQL connection string ("SQLConnect": "Data Source=...datasource...;Initial Catalog=...catalog...;User ID=..userid..;Password=..password.."). | |
SQLDboString | Defines the key used in AppSettings.json to define a SQL dbo. |
AbortTransaction | Aborts a transaction, abandoning all updates. | |
AddAsync | Adds a new record to the database table. | |
AddSiteDataAsync | Adds data for a new site. | |
ColumnFromPropertyWithLanguage | Returns a column name based on language id. | |
CommitTransactionAsync | Commits a transaction, saving all updates. | |
Direct_QueryAsync | Executes the provided SQL statement(s). | |
Direct_QueryListAsync | Executes the provided SQL statement(s) and returns a collection of objects (one for each row retrieved) of type TYPE. | |
Direct_QueryPagedListAsync | Executes the provided SQL statement(s) and returns a paged collection of objects (one for each row retrieved) of type TYPE. | |
Direct_ScalarIntAsync | Executes the provided SQL statement(s) and returns a scalar integer. | |
Direct_StoredProcAsync | Executes the provided SQL stored procedure returns a collection of objects (one for each row retrieved) of type TYPE. | |
Dispose | Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. | |
EnsureOpenAsync | Called to make sure that the database connection has been opened. Any public API must call this as a data provider no longer opens the connection immediately. | |
Equals | Determines whether the specified object is equal to the current object. | |
ExportChunkAsync | Exports data from the data provider. | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. | |
GetAsync | Retrieves one record from the database table that satisfies the specified keys. | |
GetByIdentityAsync | Retrieves one record from the database table that satisfies the specified identity identity. | |
GetConnectionString | Returns the connection string used by the data provider. | |
GetDatabaseName | Returns the database name used by the data provider. | |
GetDbOwner | Returns the database owner used by the data provider. | |
GetHashCode | Serves as the default hash function. | |
GetIdentityName | Returns the identity column name. | |
GetISQLTableInfoAsync | Returns an ISQLTableInfo interface for the data provider. | |
GetKey1Name | Returns the primary key's column name. | |
GetKey2Name | Returns the secondary key's column name. | |
GetLanguageSuffix | Returns the suffix appended to language dependent columns using the active language. | |
GetOneRecordAsync | Retrieves one record using filtering criteria. | |
GetPropertyData | Retrieves the property information for the model used. | |
GetRecordsAsync | Retrieves a collection of records using filtering criteria with sorting, with support for paging. | |
GetTableName | Returns the table name used by the data provider. | |
GetType | Gets the Type of the current instance. | |
HasIdentity | Returns whether the specified identity name string identityName is a valid identity name. | |
ImportChunkAsync | Imports data into the data provider. | |
InstallModelAsync | Installs all data models (files, tables, etc.) for the data provider. | |
IsInstalledAsync | Returns whether the data provider is installed and available. | |
LocalizeModelAsync | Called to translate the data managed by the data provider to another language. | |
MemberwiseClone | Creates a shallow copy of the current Object. | |
NormalizeFilter | Normalizes filters and updates column names for constructed names (as used in MultiString). | |
NormalizeSort | Normalizes sort filters. | |
ReferenceEquals | Determines whether the specified Object instances are the same instance. | |
RemoveAsync | Removes an existing record with the specified keys. | |
RemoveByIdentityAsync | Removes an existing record with the specified identity value. | |
RemoveRecordsAsync | Removes records using filtering criteria. | |
RemoveSiteDataAsync | Removes data when a site is deleted. | |
ReplaceWithLanguage | Replaces search text in a SQL string fragment with the language used by the data provider. | |
ReplaceWithTableName | Replaces search text in a SQL string fragment with the table name used by the data provider. | |
StartTransaction | Starts a transaction that can be committed, saving all updates, or aborted to abandon all updates. | |
SupportTransactions | Used when creating a dataprovider within StartTransAction(). | |
ToString | Returns a string that represents the current object. | |
TryGetDataType | Tests whether a given type is a simple type that can be stored in one column. | |
UninstallModelAsync | Uninstalls all data models (files, tables, etc.) for the data provider. | |
UpdateAsync | Updates an existing record with the specified existing primary keys in the database table. The primary keys can be changed to new values. | |
UpdateByIdentityAsync | Updates an existing record with the specified existing identity value identity in the database table. The primary/secondary keys can be changed in the object. |
See Also YetaWF.DataProvider.SQLYetaWF.Core
Documentation Feedback
© 2024 - Softel vdm, Inc. - YetaWF.com