Source/NFX.Wave/MVC/Controller.cs
/// <summary>
/// Override to add logic/filtering right before the invocation of action method.
/// Return TRUE to indicate that request has already been handled and no need to call method body and AfterActionInvocation in which case
///  return result via 'out result' paremeter.
///  The default implementation calls ActionFilters
/// </summary>
Override to add logic/filtering right before the invocation of action method.
Return TRUE to indicate that request has already been handled and no need to call method body and AfterActionInvocation in which case
return result via 'out result' paremeter.
The default implementation calls ActionFilters
Override to add logic / filtering right before the invocation of action method . Return TRUE to indicate that request has already been handled and no need to call method body and AfterActionInvocation in which case return result via ' out result ' paremeter . The default implementation calls ActionFilters
protected internal virtual bool BeforeActionInvocation(WorkContext work, string action, MethodInfo method, object[] args, ref object result)
      {
          var filters = GetActionFilters(GetType());
          if (filters!=null)
           for(var i=0; i<filters.Length; i++)
            if (filters[i].BeforeActionInvocation(this, work, action, method, args, ref result)) return true;
          filters = GetActionFilters(method);
          if (filters!=null)
           for(var i=0; i<filters.Length; i++)
            if (filters[i].BeforeActionInvocation(this, work, action, method, args, ref result)) return true;
          result = null;
          return false;
      }
protected internal virtual bool BeforeActionInvocation ( WorkContext work , string action , MethodInfo method , object [ ] args , ref object result ) { var filters = GetActionFilters ( GetType ( ) ) ; if ( filters != null ) for ( var i = 0 ; i < filters . Length ; i ++ ) if ( filters [ i ] . BeforeActionInvocation ( this , work , action , method , args , ref result ) ) return true ; filters = GetActionFilters ( method ) ; if ( filters != null ) for ( var i = 0 ; i < filters . Length ; i ++ ) if ( filters [ i ] . BeforeActionInvocation ( this , work , action , method , args , ref result ) ) return true ; result = null ; return false ; }
Override to add logic/filtering right before the invocation of action method.
Override to add logic / filtering right before the invocation of action method .
//1 Class-level //2 Method Level
work
WorkContext
action
string
method
MethodInfo
args
object[]
object
ref