C# Class Cedar.Framework.Caching.Interception.CachingCallHandler

Inheritance: ICallHandler
Show file Open project: Chinaccn/surfboard

Public Properties

Property Type Description
DefaultExpirationTime TimeSpan

Public Methods

Method Description
CachingCallHandler ( ) : System

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the default expiration time of 5 minutes.

CachingCallHandler ( System.TimeSpan expirationTime ) : System

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the given expiration time.

CachingCallHandler ( System.TimeSpan expirationTime, int order ) : System

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the given expiration time.

Invoke ( IMethodInvocation input, GetNextHandlerDelegate getNext ) : IMethodReturn

Implements the caching behavior of this handler.

Private Methods

Method Description
AddToCache ( string key, object value, System.TimeSpan expirationTime ) : void
TargetMethodReturnsVoid ( IMethodInvocation input ) : bool

Method Details

CachingCallHandler() public method

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the default expiration time of 5 minutes.
public CachingCallHandler ( ) : System
return System

CachingCallHandler() public method

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the given expiration time.
public CachingCallHandler ( System.TimeSpan expirationTime ) : System
expirationTime System.TimeSpan /// Length of time the cached data goes unused before it is eligible for /// reclamation. ///
return System

CachingCallHandler() public method

Creates a T:Cedar.Framework.Caching.Interception.CachingCallHandler that uses the given expiration time.
public CachingCallHandler ( System.TimeSpan expirationTime, int order ) : System
expirationTime System.TimeSpan /// Length of time the cached data goes unused before it is eligible for /// reclamation. ///
order int Order in which handler will be executed.
return System

Invoke() public method

Implements the caching behavior of this handler.
public Invoke ( IMethodInvocation input, GetNextHandlerDelegate getNext ) : IMethodReturn
input IMethodInvocation /// object /// describing the current call. ///
getNext GetNextHandlerDelegate delegate used to get the next handler in the current pipeline.
return IMethodReturn

Property Details

DefaultExpirationTime public static property

The default expiration time for the cached entries: 5 minutes
public static TimeSpan DefaultExpirationTime
return TimeSpan