Click or drag to resize

ControllerBaseDoUnlessPostponedDueToPreviousDefaultResultT Method

The method can postpone a method invocation if the previous call returned a default number, eg. 0.

Namespace:  Omada.OE.AppLogic
Assembly:  Omada.OE.AppLogic (in Omada.OE.AppLogic.dll) Version: 15.0.0.0
Syntax
C#
protected virtual void DoUnlessPostponedDueToPreviousDefaultResult<T>(
	ControllerBaseActionWithResult<T> action,
	TimeSpan postponeDuration = null,
	string actionCacheKey = null
)
where T : Object, IEquatable<T>

Parameters

action
Type: Omada.OE.AppLogicControllerBaseActionWithResultT
If the action returns a default result (e.g. 0 if T is int) then it will not be called again for the specified duration.
postponeDuration (Optional)
Type: SystemTimeSpan
actionCacheKey (Optional)
Type: SystemString
If the caller is a multi purpose method then provide the value of GetActionCacheKey() to prevent key collision

Type Parameters

T
Should normally be int.
See Also