Show / Hide Table of Contents

Class SemanticEquality

Compare Expression nodes for "computes the same value", i.e. ignore ColumnReference and parentheses.

Inheritance
Object
SemanticEquality
Implements
IEqualityComparer<Expression>
Inherited Members
Object.Equals(Object)
Object.Equals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Object.ReferenceEquals(Object, Object)
Object.ToString()
Namespace: Mangrove.MetricSetTransformers
Assembly: MetricSetTransformers.dll
Syntax
public class SemanticEquality : IEqualityComparer<Expression>

Constructors

View Source

SemanticEquality(Int32, Boolean)

Create an instance of this class which only checks equality (and only generates hash codes) for Expression objects following the syntax tree up to depth, ignoring ColumnReference nodes and parentheses.

Declaration
public SemanticEquality(int depth = 2147483647, bool unwrapTables = true)
Parameters
Type Name Description
Int32 depth

If this is 0, only expression properties will be compared.

Boolean unwrapTables

If this is true, ColumnReference nodes across tables will be treated as identical.

Methods

View Source

Equals(Expression, Expression)

Declaration
public bool Equals(Expression x, Expression y)
Parameters
Type Name Description
Expression x
Expression y
Returns
Type Description
Boolean
View Source

GetHashCode(Expression)

Declaration
public int GetHashCode(Expression obj)
Parameters
Type Name Description
Expression obj
Returns
Type Description
Int32

Implements

System.Collections.Generic.IEqualityComparer<T>

Extension Methods

ObjectExtensions.EventId(Object)
  • View Source
Back to top Generated by DocFX