public ConditionVariableValue(ConditionVariableValue other) { type = other.type; intValue = other.intValue; boolValue = other.boolValue; floatValue = other.floatValue; }
public bool IsTrueFor(ConditionVariableValue val) { switch (val.type) { case ConditionVariableValue.Type.Integer: return(IsTrueFor(val.intValue)); case ConditionVariableValue.Type.Boolean: return(IsTrueFor(val.boolValue)); case ConditionVariableValue.Type.Float: return(IsTrueFor(val.floatValue)); default: throw new InvalidOperationException(); } }