Esempio n. 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public MethodInfoCall()
 {
     _instanceOne       = new MyClass();
     _instanceTwo       = new MyAnotherClass();
     _instanceOneCaller = new MethodInfoCaller <MyClass>();
     _instanceTwoCaller = new MethodInfoCaller <MyAnotherClass>();
 }
Esempio n. 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public DelegateCall()
 {
     _instanceOne       = new MyClass();
     _instanceTwo       = new MyAnotherClass();
     _instanceOneCaller = new DelegateCaller <MyClass>();
     _instanceTwoCaller = new DelegateCaller <MyAnotherClass>();
 }
Esempio n. 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public ExpressionCall()
 {
     _instanceOne       = new MyClass();
     _instanceTwo       = new MyAnotherClass();
     _instanceOneCaller = new ExpressionCaller <MyClass>();
     _instanceTwoCaller = new ExpressionCaller <MyAnotherClass>();
 }
Esempio n. 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public ClassCall()
 {
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
Esempio n. 5
0
		public static void Invoke(this MyAnotherClass c) { /* Do something */ } }
Esempio n. 6
0
 public int Visit(MyAnotherClass c)
 {
     return c.InvokeMethod();
 }
Esempio n. 7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public VisitorCall()
 {
     _visitor = new Visitor();
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
Esempio n. 8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public DynamicMethodCall()
 {
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
 public static void PrintName(MyAnotherClass baseClass)
 {
     Console.WriteLine("MyAnotherClass");
 }
Esempio n. 10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public ClassCall()
 {
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public ExtensionMethodCall()
 {
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
Esempio n. 12
0
 public int Visit(MyAnotherClass c)
 {
     return(c.InvokeMethod());
 }
Esempio n. 13
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public VisitorCall()
 {
     _visitor     = new Visitor();
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }
Esempio n. 14
0
 public static int InvokeMethodEx(this MyAnotherClass c)
 {
     return(c.InvokeMethod());
 }
Esempio n. 15
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public ExtensionMethodCall()
 {
     _instanceOne = new MyClass();
     _instanceTwo = new MyAnotherClass();
 }