Class DataCacheStorageProvider
Represents a base data cache storage provider.
Namespace: Mediachase.BusinessFoundation
Assembly: Mediachase.BusinessFoundation.dll
Version: 12.17.2Syntax
public abstract class DataCacheStorageProvider : ProviderBase
Constructors
DataCacheStorageProvider()
Initializes a new instance of the DataCacheStorageProvider class.
Declaration
protected DataCacheStorageProvider()
Fields
SlidingExpirationKeyName
Declaration
public const string SlidingExpirationKeyName = "slidingExpiration"
Field Value
Type | Description |
---|---|
System.String |
Properties
SlidingExpiration
Gets or sets the sliding expiration.
Declaration
public TimeSpan SlidingExpiration { get; set; }
Property Value
Type | Description |
---|---|
System.TimeSpan | The sliding expiration. |
Methods
Add(String, IEnumerable<FileDescriptor>, String, String, Object)
Adds the specified value to cache.
Declaration
public abstract void Add(string category, IEnumerable<FileDescriptor> fileDiscriptors, string userId, string key, object value)
Parameters
Type | Name | Description |
---|---|---|
System.String | category | The category. |
System.Collections.Generic.IEnumerable<FileDescriptor> | fileDiscriptors | The file descriptors. |
System.String | userId | The user id. |
System.String | key | The key. |
System.Object | value | The value. |
GetValue(String, String, String)
Declaration
public abstract object GetValue(string category, string userId, string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | category | |
System.String | userId | |
System.String | key |
Returns
Type | Description |
---|---|
System.Object |
Initialize(String, NameValueCollection)
Initializes the provider.
Declaration
public override 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. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The name of the provider is null. |
System.InvalidOperationException | An attempt is made to call System.Configuration.Provider.ProviderBase.Initialize(System.String,System.Collections.Specialized.NameValueCollection) on a provider after the provider has already been initialized. |
System.ArgumentException | The name of the provider has a length of zero. |
Remove(String, String, String)
Removes the specified category.
Declaration
public abstract void Remove(string category, string userId, string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | category | The category. |
System.String | userId | The user id. |
System.String | key | The key. |
RemoveAll()
Removes all.
Declaration
public abstract void RemoveAll()
RemoveByCategory(String)
Removes the specified category.
Declaration
public abstract void RemoveByCategory(string category)
Parameters
Type | Name | Description |
---|---|---|
System.String | category | The category. |
RemoveByUser(String)
Removes the specified user id.
Declaration
public abstract void RemoveByUser(string userId)
Parameters
Type | Name | Description |
---|---|---|
System.String | userId | The user id. |