/// <exception cref="Edu.Stanford.Nlp.Semgraph.Semgrex.ParseException"/>
        public SemgrexPattern SubNode(GraphRelation r)
        {
            SemgrexPattern result = null;
            SemgrexPattern child  = null;

            switch ((jj_ntk == -1) ? Jj_ntk() : jj_ntk)
            {
            case 13:
            {
                Jj_consume_token(13);
                result = SubNode(r);
                Jj_consume_token(14);
                switch ((jj_ntk == -1) ? Jj_ntk() : jj_ntk)
                {
                case SemgrexParserConstantsConstants.Relation:
                case SemgrexParserConstantsConstants.Alignreln:
                case SemgrexParserConstantsConstants.Identifier:
                case 17:
                case 18:
                case 19:
                {
                    child = RelationDisj();
                    break;
                }

                default:
                {
                    jj_la1[2] = jj_gen;
                    break;
                }
                }
                if (child != null)
                {
                    IList <SemgrexPattern> newChildren = new List <SemgrexPattern>();
                    Sharpen.Collections.AddAll(newChildren, result.GetChildren());
                    newChildren.Add(child);
                    result.SetChild(new CoordinationPattern(false, newChildren, true));
                }
                if (true)
                {
                    return(result);
                }
                break;
            }

            case 17:
            case 19:
            case 23:
            {
                result = ModNode(r);
                switch ((jj_ntk == -1) ? Jj_ntk() : jj_ntk)
                {
                case SemgrexParserConstantsConstants.Relation:
                case SemgrexParserConstantsConstants.Alignreln:
                case SemgrexParserConstantsConstants.Identifier:
                case 17:
                case 18:
                case 19:
                {
                    child = RelationDisj();
                    break;
                }

                default:
                {
                    jj_la1[3] = jj_gen;
                    break;
                }
                }
                if (child != null)
                {
                    result.SetChild(child);
                }
                if (true)
                {
                    return(result);
                }
                break;
            }

            default:
            {
                jj_la1[4] = jj_gen;
                Jj_consume_token(-1);
                throw new ParseException();
            }
            }
            throw new Exception("Missing return statement in function");
        }