mscorlib(4.0.0.0) API with additions
CreateInstanceBinder.cs
1 using System.Dynamic.Utils;
2 
3 namespace System.Dynamic
4 {
6  [global::__DynamicallyInvokable]
8  {
9  private readonly CallInfo _callInfo;
10 
13  [global::__DynamicallyInvokable]
14  public sealed override Type ReturnType
15  {
16  [global::__DynamicallyInvokable]
17  get
18  {
19  return typeof(object);
20  }
21  }
22 
25  [global::__DynamicallyInvokable]
26  public CallInfo CallInfo
27  {
28  [global::__DynamicallyInvokable]
29  get
30  {
31  return _callInfo;
32  }
33  }
34 
35  internal sealed override bool IsStandardBinder => true;
36 
39  [global::__DynamicallyInvokable]
40  protected CreateInstanceBinder(CallInfo callInfo)
41  {
42  ContractUtils.RequiresNotNull(callInfo, "callInfo");
43  _callInfo = callInfo;
44  }
45 
50  [global::__DynamicallyInvokable]
52  {
53  return FallbackCreateInstance(target, args, null);
54  }
55 
61  [global::__DynamicallyInvokable]
62  public abstract DynamicMetaObject FallbackCreateInstance(DynamicMetaObject target, DynamicMetaObject[] args, DynamicMetaObject errorSuggestion);
63 
68  [global::__DynamicallyInvokable]
69  public sealed override DynamicMetaObject Bind(DynamicMetaObject target, DynamicMetaObject[] args)
70  {
71  ContractUtils.RequiresNotNull(target, "target");
72  ContractUtils.RequiresNotNullItems(args, "args");
73  return target.BindCreateInstance(this, args);
74  }
75  }
76 }
Represents the dynamic create operation at the call site, providing the binding semantic and the deta...
sealed override DynamicMetaObject Bind(DynamicMetaObject target, DynamicMetaObject[] args)
Performs the binding of the dynamic create operation.
Represents the dynamic binding and a binding logic of an object participating in the dynamic binding.
Definition: __Canon.cs:3
sealed override Type ReturnType
The result type of the operation.
CreateInstanceBinder(CallInfo callInfo)
Initializes a new intsance of the T:System.Dynamic.CreateInstanceBinder.
virtual DynamicMetaObject BindCreateInstance(CreateInstanceBinder binder, DynamicMetaObject[] args)
Performs the binding of the dynamic create instance operation.
Represents type declarations: class types, interface types, array types, value types,...
Definition: Type.cs:18
The dynamic call site binder that participates in the T:System.Dynamic.DynamicMetaObject binding prot...
DynamicMetaObject FallbackCreateInstance(DynamicMetaObject target, DynamicMetaObject[] args)
Performs the binding of the dynamic create operation if the target dynamic object cannot bind.
Describes arguments in the dynamic binding process.
Definition: CallInfo.cs:10