Class VariableNode
- Namespace
- LogicalOptimizer
- Assembly
- LogicalOptimizer.Core.dll
Named boolean variable. Immutable; hash code is computed once in the constructor.
public sealed class VariableNode : AstNode
- Inheritance
-
VariableNode
- Inherited Members
Constructors
VariableNode(string)
Creates a variable with the given name.
public VariableNode(string name)
Parameters
namestring
Properties
Name
Variable name.
public string Name { get; }
Property Value
Methods
Clone()
Nodes are fully immutable, so cloning returns the same instance.
public override AstNode Clone()
Returns
Equals(object?)
Determines whether the specified object is equal to the current object.
public override bool Equals(object? obj)
Parameters
objobjectThe object to compare with the current object.
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
GetVariables()
public override HashSet<string> GetVariables()
Returns
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.