public Rule_Recode(Rule_Context pContext, NonterminalToken pToken) : base(pContext) { /* * <Recode_Statement> ::= RECODE Identifier TO Identifier <RecodeList> END * <RecodeList> ::= <Recode> | <RecodeList> <Recode> * <RecodeValue> ::= <Literal> | Boolean | Identifier | LOVALUE | HIVALUE * <Recoded_Value> ::= <Literal> | Boolean | Identifier * <Recode> ::= <RecodeValue> '-' <RecodeValue> '=' <Recoded_Value> | <RecodeValue> '=' <RecodeValue> | ELSE '=' <Recoded_Value> */ // RECODE Identifier TO Identifier <RecodeList> END this.Identifier1 = this.GetCommandElement(pToken.Tokens, 1).Trim(new char[] { '[', ']' }); this.Identifier2 = this.GetCommandElement(pToken.Tokens, 3).Trim(new char[] { '[', ']' }); this._recodeList = new RecodeList(this.Identifier2, this.Identifier1); this.SetRecodeList((NonterminalToken)pToken.Tokens[4]); //RecodeRules = this.GetCommandElement(pToken.Tokens, 5).Split(new char[] {'\r','\n' }, StringSplitOptions.RemoveEmptyEntries); //this.RecodeList = new Rule_RecodeList(pContext, (NonterminalToken)pToken.Tokens[4]); }
public Rule_Recode(Rule_Context pContext, NonterminalToken pToken) : base(pContext) { /* <Recode_Statement> ::= RECODE Identifier TO Identifier <RecodeList> END <RecodeList> ::= <Recode> | <RecodeList> <Recode> <RecodeValue> ::= <Literal> | Boolean | Identifier | LOVALUE | HIVALUE <Recoded_Value> ::= <Literal> | Boolean | Identifier <Recode> ::= <RecodeValue> '-' <RecodeValue> '=' <Recoded_Value> | <RecodeValue> '=' <RecodeValue> | ELSE '=' <Recoded_Value> */ // RECODE Identifier TO Identifier <RecodeList> END this.Identifier1 = this.GetCommandElement(pToken.Tokens, 1).Trim(new char[] { '[',']' }); this.Identifier2 = this.GetCommandElement(pToken.Tokens, 3).Trim(new char[] { '[', ']' }); this._recodeList = new RecodeList(this.Identifier2, this.Identifier1); this.SetRecodeList((NonterminalToken) pToken.Tokens[4]); //RecodeRules = this.GetCommandElement(pToken.Tokens, 5).Split(new char[] {'\r','\n' }, StringSplitOptions.RemoveEmptyEntries); //this.RecodeList = new Rule_RecodeList(pContext, (NonterminalToken)pToken.Tokens[4]); }