Exemplo n.º 1
0
 public ApiInvokedArgs(ApiInvokingArgs invokingArgs, IdentityInfo identity, object result)
 {
     this.invokingArgs = invokingArgs;
     InvokedAt         = DateTime.Now.GetUnixLongTime();
     Identity          = identity;
     Result            = result;
 }
Exemplo n.º 2
0
 public ApiExceptionArgs(ApiInvokingArgs invokingArgs, IdentityInfo identity, Exception exception)
 {
     this.invokingArgs = invokingArgs;
     InvokedAt         = DateTime.Now.GetUnixLongTime();
     Identity          = identity;
     Exception         = exception;
 }
Exemplo n.º 3
0
 public static void OnInvoking(ApiInvokingArgs args)
 {
     try
     {
         Invoking?.Invoke(null, args);
     }
     catch (Exception ex)
     {
         throw new ApiInvocationException("Handling Api Invoking event failed.", ex);
     }
 }