Class MetadataSemanticProvider
Semantic information provider for expressions and reflection objects with support for metadata-based lookups.
Implements
Inherited Members
Namespace: System.Linq.Expressions
Assembly: Nuqleon.Linq.Expressions.Optimizers.dll
Syntax
public class MetadataSemanticProvider : DefaultSemanticProvider, ISemanticProviderConstructors
MetadataSemanticProvider()
Declaration
public MetadataSemanticProvider()Properties
ConstParameters
Gets a table of parameters that are used in a const way, i.e. the callee doesn't mutate the values
passed to these parameters.
Declaration
public ParameterTable ConstParameters { get; set; }Property Value
| Type | Description | 
|---|---|
| ParameterTable | 
ImmutableTypes
Gets a table of types whose instances are immutable.
Declaration
public TypeTable ImmutableTypes { get; set; }Property Value
| Type | Description | 
|---|---|
| TypeTable | 
PureMembers
Gets a table of members that are deemed to be pure.
Declaration
public MemberTable PureMembers { get; set; }Property Value
| Type | Description | 
|---|---|
| MemberTable | 
Methods
IsConst(ParameterInfo)
Checks if the specified parameter uses the argument in a const (readonly)
fashion, i.e. it doesn't cause any mutation to the argument passed to it.
Declaration
public override bool IsConst(ParameterInfo parameter)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Reflection.ParameterInfo | parameter | The parameter to check. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
Overrides
IsImmutable(Type)
Checks if instances of the specified type are immutable.
Declaration
public override bool IsImmutable(Type type)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Type | type | The type to check. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
Overrides
IsPure(MemberInfo)
Checks if the specified member is pure and doesn't have any side-effects for
evaluation. Members can be retrieved from the PureMembers table.
Declaration
public override bool IsPure(MemberInfo member)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Reflection.MemberInfo | member | The member to check. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 |