mscorlib(4.0.0.0) API with additions
GetIndexBinder.cs
1 using System.Dynamic.Utils;
2 
3 namespace System.Dynamic
4 {
6  [global::__DynamicallyInvokable]
7  public abstract class GetIndexBinder : DynamicMetaObjectBinder
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 GetIndexBinder(CallInfo callInfo)
41  {
42  ContractUtils.RequiresNotNull(callInfo, "callInfo");
43  _callInfo = callInfo;
44  }
45 
50  [global::__DynamicallyInvokable]
51  public sealed override DynamicMetaObject Bind(DynamicMetaObject target, DynamicMetaObject[] args)
52  {
53  ContractUtils.RequiresNotNull(target, "target");
54  ContractUtils.RequiresNotNullItems(args, "args");
55  return target.BindGetIndex(this, args);
56  }
57 
62  [global::__DynamicallyInvokable]
64  {
65  return FallbackGetIndex(target, indexes, null);
66  }
67 
73  [global::__DynamicallyInvokable]
74  public abstract DynamicMetaObject FallbackGetIndex(DynamicMetaObject target, DynamicMetaObject[] indexes, DynamicMetaObject errorSuggestion);
75  }
76 }
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.
GetIndexBinder(CallInfo callInfo)
Initializes a new instance of the T:System.Dynamic.GetIndexBinder.
virtual DynamicMetaObject BindGetIndex(GetIndexBinder binder, DynamicMetaObject[] indexes)
Performs the binding of the dynamic get index 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 FallbackGetIndex(DynamicMetaObject target, DynamicMetaObject[] indexes)
Performs the binding of the dynamic get index operation if the target dynamic object cannot bind.
Represents the dynamic get index operation at the call site, providing the binding semantic and the d...
sealed override DynamicMetaObject Bind(DynamicMetaObject target, DynamicMetaObject[] args)
Performs the binding of the dynamic get index operation.
Describes arguments in the dynamic binding process.
Definition: CallInfo.cs:10