public IEnumerable <IAdvice> Advise(MethodBase method) { yield return(Advice.Basic.Before(() => { Interception.Sequence(); Interception.Done = true; })); }
public IEnumerable <IAdvice> Advise(MethodBase method) { yield return(Advice.Basic.Before((_Instance, _Arguments) => { Interception.Sequence(); Interception.Done = true; Interception.Instance = _Instance; Interception.Arguments = _Arguments; })); }
virtual public int Method(int x, ref int y) { y = -y; return(Interception.Sequence()); }
public int Method(int x, T y) { return(Interception <TTag> .Sequence()); }
static public int Static(int a0, int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8, int a9) { Interception.MethodArguments = new object[] { a0, a1, a2, a3, a4, a5, a6, a7, a8, a9 }; return(Interception.Sequence()); }
public int Method<T>(int x, T y) { return Interception.Sequence(); }
/// <summary> /// Number of generic parameters for method1 should be same as type but differ from that of method2 to catch more error. /// </summary> public int Method1 <T2>(int x, T1 y) { return(Interception.Sequence()); }
/// <summary> /// Number of generic parameters for type should diff from that of method1 and type to catch more error /// also we use the type parameter instead. /// </summary> public int Method2 <T2, T3>(int x, T3 y) { return(Interception.Sequence()); }