This commit is contained in:
niko
2026-06-04 11:42:34 +02:00
parent f39ba70a9f
commit e720b98cd1
7488 changed files with 2493818 additions and 0 deletions
@@ -0,0 +1,57 @@
using System;
using System.Collections.ObjectModel;
using System.Reflection.Emit;
namespace System.Linq.Expressions
{
/// <summary>Represents calling a constructor and initializing one or more members of the new object.</summary>
// Token: 0x02000028 RID: 40
public sealed class MemberInitExpression : Expression
{
// Token: 0x06000229 RID: 553 RVA: 0x0000BB60 File Offset: 0x00009D60
internal MemberInitExpression(NewExpression new_expression, ReadOnlyCollection<MemberBinding> bindings)
: base(ExpressionType.MemberInit, new_expression.Type)
{
this.new_expression = new_expression;
this.bindings = bindings;
}
/// <summary>Gets the expression that represents the constructor call.</summary>
/// <returns>A <see cref="T:System.Linq.Expressions.NewExpression" /> that represents the constructor call.</returns>
// Token: 0x17000028 RID: 40
// (get) Token: 0x0600022A RID: 554 RVA: 0x0000BB80 File Offset: 0x00009D80
public NewExpression NewExpression
{
get
{
return this.new_expression;
}
}
/// <summary>Gets the bindings that describe how to initialize the members of the newly created object.</summary>
/// <returns>A <see cref="T:System.Collections.ObjectModel.ReadOnlyCollection`1" /> of <see cref="T:System.Linq.Expressions.MemberBinding" /> objects which describe how to initialize the members.</returns>
// Token: 0x17000029 RID: 41
// (get) Token: 0x0600022B RID: 555 RVA: 0x0000BB88 File Offset: 0x00009D88
public ReadOnlyCollection<MemberBinding> Bindings
{
get
{
return this.bindings;
}
}
// Token: 0x0600022C RID: 556 RVA: 0x0000BB90 File Offset: 0x00009D90
internal override void Emit(EmitContext ec)
{
LocalBuilder localBuilder = ec.EmitStored(this.new_expression);
ec.EmitCollection(this.bindings, localBuilder);
ec.EmitLoad(localBuilder);
}
// Token: 0x040000B2 RID: 178
private NewExpression new_expression;
// Token: 0x040000B3 RID: 179
private ReadOnlyCollection<MemberBinding> bindings;
}
}