Try our conversational search powered by Generative AI!

Class DataStoreProvider

Base class for data store providers

Inheritance
System.Object
DataStoreProvider
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Data.Dynamic.Providers
Assembly: EPiServer.Data.dll
Version: 11.20.7
Syntax
public abstract class DataStoreProvider
Remarks

This class in not thread safe

Constructors

DataStoreProvider()

Declaration
protected DataStoreProvider()

Properties

DataStoreNameValueCollection

Declaration
[Obsolete("No longer used")]
protected NameValueCollection DataStoreNameValueCollection { get; }
Property Value
Type Description
System.Collections.Specialized.NameValueCollection

Name

Gets the friendly name used to refer to the provider

Declaration
public virtual string Name { get; set; }
Property Value
Type Description
System.String
Remarks

Default name is 'default'

ReferenceTableInformation

Declaration
public abstract TableInformation ReferenceTableInformation { get; }
Property Value
Type Description
TableInformation

Methods

CanMoveDataBetweenProperties(InlinePropertyMap, InlinePropertyMap)

Declaration
public abstract bool CanMoveDataBetweenProperties(InlinePropertyMap fromProperty, InlinePropertyMap toProperty)
Parameters
Type Name Description
InlinePropertyMap fromProperty
InlinePropertyMap toProperty
Returns
Type Description
System.Boolean

ConvertStoreNameToInternal(String)

Convert the store name to that used internally by the provider

Declaration
public virtual string ConvertStoreNameToInternal(string storeName)
Parameters
Type Name Description
System.String storeName

The name of the store to convert

Returns
Type Description
System.String

A System.String

CreateInstance()

Create an instance of the configured data store provider

Declaration
[Obsolete("Use IDataStoreProviderFactory to get instance of DataStoreProvider")]
public static DataStoreProvider CreateInstance()
Returns
Type Description
DataStoreProvider

CreateInstance(Object)

Create a new instance of a provider using the providerSettings passed

Declaration
[Obsolete("Use IDataStoreProviderFactory to get instance of DataStoreProvider")]
public static DataStoreProvider CreateInstance(object providerSettings)
Parameters
Type Name Description
System.Object providerSettings
Returns
Type Description
DataStoreProvider

A new DataStoreProvider instance

CreateInstance(String)

Declaration
[Obsolete("Use IDataStoreProviderFactory to get instance of DataStoreProvider")]
public static DataStoreProvider CreateInstance(string providerTypeName)
Parameters
Type Name Description
System.String providerTypeName
Returns
Type Description
DataStoreProvider

Delete(Identity)

Declaration
public abstract void Delete(Identity id)
Parameters
Type Name Description
Identity id

DeleteAll(String)

Declaration
public abstract void DeleteAll(string storeName)
Parameters
Type Name Description
System.String storeName

DeleteStoreDefinition(String, Boolean)

Declaration
public abstract void DeleteStoreDefinition(string storeName, bool deleteObjects)
Parameters
Type Name Description
System.String storeName
System.Boolean deleteObjects

ExecuteList<T>(Query)

Declaration
protected abstract IList<T> ExecuteList<T>(Query query)
Parameters
Type Name Description
Query query
Returns
Type Description
System.Collections.Generic.IList<T>
Type Parameters
Name Description
T

ExecuteLocked(String, Action)

Executes an action with acuiring a lock.

Declaration
public abstract void ExecuteLocked(string resourceName, Action action)
Parameters
Type Name Description
System.String resourceName

Name of the resource.

System.Action action

The action.

ExecuteScalar<T>(Query)

Declaration
protected abstract T ExecuteScalar<T>(Query query)
Parameters
Type Name Description
Query query
Returns
Type Description
T
Type Parameters
Name Description
T

ExecuteTransaction(Action)

Execute an action in a transactional manner.

Declaration
public abstract void ExecuteTransaction(Action action)
Parameters
Type Name Description
System.Action action

The System.Action delegate to execute

Find<T>(ProviderCallContext, IDictionary<String, Object>, DynamicDataStore)

Declaration
public abstract IEnumerable<T> Find<T>(ProviderCallContext context, IDictionary<string, object> parameters, DynamicDataStore store)
Parameters
Type Name Description
ProviderCallContext context
System.Collections.Generic.IDictionary<System.String, System.Object> parameters
DynamicDataStore store
Returns
Type Description
System.Collections.Generic.IEnumerable<T>
Type Parameters
Name Description
T

GetQueryObject<T>(DynamicDataStore, LoadAsObjectType)

Declaration
protected abstract Query<T> GetQueryObject<T>(DynamicDataStore store, LoadAsObjectType loadObjectAs)
Parameters
Type Name Description
DynamicDataStore store
LoadAsObjectType loadObjectAs
Returns
Type Description
Query<T>
Type Parameters
Name Description
T

GetStoreNameForItem(Identity, String)

Declaration
public abstract string GetStoreNameForItem(Identity id, string tableName)
Parameters
Type Name Description
Identity id
System.String tableName
Returns
Type Description
System.String

GetStoreNames()

Declaration
public abstract IEnumerable<string> GetStoreNames()
Returns
Type Description
System.Collections.Generic.IEnumerable<System.String>

GetStoreViewName(String)

Get the database specific view name for a store

Declaration
public abstract string GetStoreViewName(string storeName)
Parameters
Type Name Description
System.String storeName

The name of the store the item will be saved to

Returns
Type Description
System.String

A System.String

GetTableInformation(String)

Declaration
public abstract TableInformation GetTableInformation(string tableName)
Parameters
Type Name Description
System.String tableName
Returns
Type Description
TableInformation

GetValueOverflowCount(String, InlinePropertyMap, InlinePropertyMap, Object, Object)

Declaration
public abstract int GetValueOverflowCount(string storeName, InlinePropertyMap propertyMap, InlinePropertyMap oldPropertyMap, object minValue, object maxValue)
Parameters
Type Name Description
System.String storeName
InlinePropertyMap propertyMap
InlinePropertyMap oldPropertyMap
System.Object minValue
System.Object maxValue
Returns
Type Description
System.Int32

Initialize(String, NameValueCollection)

Initializes the provider.

Declaration
public virtual void Initialize(string name, NameValueCollection config)
Parameters
Type Name Description
System.String name

The friendly name of the provider

System.Collections.Specialized.NameValueCollection config

A collection of the name/value pairs representing the provider-specific attributes specified in the configuration for this provider.

IsProviderSpecificException(Exception)

Determines if an exception is specific to the data provider or a standard .NET exception

Declaration
public abstract bool IsProviderSpecificException(Exception exception)
Parameters
Type Name Description
System.Exception exception

The exception to check

Returns
Type Description
System.Boolean

true if the exception is data provider specific, otherwise false

Load(ProviderCallContext)

Declaration
public abstract object Load(ProviderCallContext context)
Parameters
Type Name Description
ProviderCallContext context
Returns
Type Description
System.Object

LoadStoreDefinition(String)

Declaration
public abstract StoreDefinition LoadStoreDefinition(string storeName)
Parameters
Type Name Description
System.String storeName
Returns
Type Description
StoreDefinition

Save(ProviderCallContext)

Declaration
public abstract void Save(ProviderCallContext context)
Parameters
Type Name Description
ProviderCallContext context

SaveStoreDefinition(StoreDefinition)

Declaration
public abstract void SaveStoreDefinition(StoreDefinition storeDefinition)
Parameters
Type Name Description
StoreDefinition storeDefinition

UpdateReferencesPropertyName(String, String, String, String)

Update the property names for the references

Declaration
public abstract void UpdateReferencesPropertyName(string storeName, string tableName, string oldPropertyName, string newPropertyName)
Parameters
Type Name Description
System.String storeName

Name of the store.

System.String tableName

Name of the CustomBigtable

System.String oldPropertyName

The old Name of the Property

System.String newPropertyName

The new Name of the Property

Extension Methods