This class represents the cache options applied to a certain item/result set, before inserting it into the cache. These caching options include adding a QueryIdentifier against the query result set, creating a DB dependency, setting item expiration time, etc.
public class CachingOptions : ICloneable
Creates an instance of the CachingOptions with default values.
Gets the absolute time when the item will expire.
Specifies whether to create a Db dependency with the result set or not.
Returns the configured expiration type.
Returns whether the CacheSyncOption is enabled or disabled.
Sets the relative priority of the item as compared to other cached items. Higher priority items are less likely to be deleted from cache on eviction.
Identifier for a query which is added as a Tag against the result set of the query in the cache. This must be unique for each unique query. The QueryIdentifier is used to regenerate the result set from the cache upon execution of the same query. The user must maintain a mapping of the query against the query identifier to be used in the future. If not specified, NCache adds the query string itself as the tag (making it unique for each unique query). For example, a query which returns a Customer is not tagged by the user. The next time the same query is executed, the query string is searched as a tag within the cache and if it exists, the result set against it will be returned.
Returns the ReadThru Provider name configured for cache synchronization.
Returns the sliding expiration time span of the item that will be cached.
Specifies whether the result set should be stored as seperate entities or as a collection.
Creates a shallow copy of the CachingOptions instance.
Sets the absolute expiration time of the cache item. Only one type of expiration, either absolute or sliding expiration can be configured at one time.
This method sets the ResyncProviderName.
Sets the sliding expiration time of the cache item. Only one type of expiration, either absolute or sliding expiration can be configured at one time.