void HandleCondition(string text) { if (stateMachine.Current != KV1TextReaderState.InObjectAfterValue) { throw new InvalidDataException($"Found conditional while in state {stateMachine.Current}."); } if (!conditionEvaluator.Evalute(text)) { stateMachine.SetDiscardCurrent(); } }
void HandleCondition(string text) { if (stateMachine.Current != KV1TextReaderState.InObjectAfterValue) { throw new InvalidDataException( string.Format( CultureInfo.InvariantCulture, "Found conditional while in state {0}.", stateMachine.Current)); } if (!conditionEvaluator.Evalute(text)) { stateMachine.SetDiscardCurrent(); } }