Editar

Partilhar via


OutputCacheProvider.Add(String, Object, DateTime) Method

Definition

Inserts the specified entry into the output cache.

public:
 abstract System::Object ^ Add(System::String ^ key, System::Object ^ entry, DateTime utcExpiry);
public abstract object Add (string key, object entry, DateTime utcExpiry);
abstract member Add : string * obj * DateTime -> obj
Public MustOverride Function Add (key As String, entry As Object, utcExpiry As DateTime) As Object

Parameters

key
String

A unique identifier for entry.

entry
Object

The content to add to the output cache.

utcExpiry
DateTime

The time and date on which the cached entry expires.

Returns

A reference to the specified provider.

Remarks

If there is already a value in the cache for the specified key, the provider must return that value. The provider must not store the data passed by using the Add method parameters. The Add method stores the data if it is not already in the cache. If the data is in the cache, the Add method returns it.

Applies to