Class ElementInitSlim
Lightweight representation of an element initializer.
Inheritance
System.Object
ElementInitSlim
Implements
Namespace: System.Linq.Expressions
Assembly: Nuqleon.Linq.Expressions.Bonsai.dll
Syntax
public sealed class ElementInitSlim : Object, IArgumentProviderSlim
Properties
AddMethod
Gets the add method used by the element initializer.
Declaration
public MethodInfoSlim AddMethod { get; }
Property Value
Type | Description |
---|---|
MethodInfoSlim |
ArgumentCount
Gets the number of arguments.
Declaration
public int ArgumentCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Arguments
Gets the expressions representing the arguments passed to the add method.
Declaration
public ReadOnlyCollection<ExpressionSlim> Arguments { get; }
Property Value
Type | Description |
---|---|
System.Collections.ObjectModel.ReadOnlyCollection<ExpressionSlim> |
Methods
GetArgument(Int32)
Gets the argument at the specified index.
Declaration
public ExpressionSlim GetArgument(int index)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | The index of the argument to retrieve. |
Returns
Type | Description |
---|---|
ExpressionSlim | The argument at the specified index. |
ToString()
Gets a friendly string representation of the node.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | String representation of the node. |
Update(ReadOnlyCollection<ExpressionSlim>)
Creates a new element initializer that is like this one, but using the supplied children. If all of the children are the same, it will return this element initializer.
Declaration
public ElementInitSlim Update(ReadOnlyCollection<ExpressionSlim> arguments)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.ObjectModel.ReadOnlyCollection<ExpressionSlim> | arguments | The Arguments child node of the result. |
Returns
Type | Description |
---|---|
ElementInitSlim | This element initializer if no children are changed or an element initializer with the updated children. |