BACnet.Tagging.TagWriterSink.EnterChoice C# (CSharp) Method

EnterChoice() public method

Enters a choice value
public EnterChoice ( byte choiceIndex ) : void
choiceIndex byte The active choice
return void
        public void EnterChoice(byte choiceIndex)
        {
            _require(StreamOp.EnterChoice);
            _writer.WriteOpenTag(_state.Tag);

            var choice = ((ChoiceSchema)_state.Schema);
            var field = choice.Fields[choiceIndex];
            _stack.Push(new SchemaState(choice, _state.Tag, choiceIndex));
            _state = new SchemaState(field.Type, field.Tag, -1);
        }