ICSharpHelper.Expression Method

Definition

Overloads

Expression(Expression, ISet<String>)

Translates a node representing an expression into source code that would produce it.

Expression(Expression, ISet<String>, ISet<String>, IReadOnlyDictionary<Object,String>, IReadOnlyDictionary<MemberInfo,QualifiedName>)

Translates a node representing an expression into source code that would produce it.

Expression(Expression, ISet<String>)

Source:
ICSharpHelper.cs

Translates a node representing an expression into source code that would produce it.

[Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkInternal]
public string Expression (System.Linq.Expressions.Expression node, System.Collections.Generic.ISet<string> collectedNamespaces);
[<Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkInternal>]
abstract member Expression : System.Linq.Expressions.Expression * System.Collections.Generic.ISet<string> -> string
Public Function Expression (node As Expression, collectedNamespaces As ISet(Of String)) As String

Parameters

node
Expression

The node to be translated.

collectedNamespaces
ISet<String>

Any namespaces required by the translated code will be added to this set.

Returns

Source code that would produce node.

Attributes

Remarks

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

Applies to

Expression(Expression, ISet<String>, ISet<String>, IReadOnlyDictionary<Object,String>, IReadOnlyDictionary<MemberInfo,QualifiedName>)

Source:
ICSharpHelper.cs

Translates a node representing an expression into source code that would produce it.

[Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkInternal]
public string Expression (System.Linq.Expressions.Expression node, System.Collections.Generic.ISet<string> collectedNamespaces, System.Collections.Generic.ISet<string> unsafeAccessors, System.Collections.Generic.IReadOnlyDictionary<object,string>? constantReplacements = default, System.Collections.Generic.IReadOnlyDictionary<System.Reflection.MemberInfo,Microsoft.EntityFrameworkCore.Design.Internal.QualifiedName>? memberAccessReplacements = default);
[<Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkInternal>]
abstract member Expression : System.Linq.Expressions.Expression * System.Collections.Generic.ISet<string> * System.Collections.Generic.ISet<string> * System.Collections.Generic.IReadOnlyDictionary<obj, string> * System.Collections.Generic.IReadOnlyDictionary<System.Reflection.MemberInfo, Microsoft.EntityFrameworkCore.Design.Internal.QualifiedName> -> string
Public Function Expression (node As Expression, collectedNamespaces As ISet(Of String), unsafeAccessors As ISet(Of String), Optional constantReplacements As IReadOnlyDictionary(Of Object, String) = Nothing, Optional memberAccessReplacements As IReadOnlyDictionary(Of MemberInfo, QualifiedName) = Nothing) As String

Parameters

node
Expression

The node to be translated.

collectedNamespaces
ISet<String>

Any namespaces required by the translated code will be added to this set.

unsafeAccessors
ISet<String>

Any unsafe accessors needed to access private members will be added to this dictionary.

constantReplacements
IReadOnlyDictionary<Object,String>

Collection of translations for statically known instances.

memberAccessReplacements
IReadOnlyDictionary<MemberInfo,Microsoft.EntityFrameworkCore.Design.Internal.QualifiedName>

Collection of translations for non-public member accesses.

Returns

Source code that would produce node.

Attributes

Remarks

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

Applies to