// $ANTLR 3.3 Nov 30, 2010 12:45:30 /prg/code/xreate/antlr/SimpleDeclarative.g 2011-06-28 19:34:29

import org.antlr.runtime.*;
import java.util.Stack;
import java.util.List;
import java.util.ArrayList;

public class SimpleDeclarativeLexer extends Lexer {
    public static final int EOF=-1;
    public static final int BRACESTART=4;
    public static final int BRACEEND=5;
    public static final int COMMA=6;
    public static final int COLON=7;
    public static final int OR=8;
    public static final int LET=9;
    public static final int WHERE=10;
    public static final int EQUAL=11;
    public static final int WORD=12;
    public static final int NUMBER=13;
    public static final int SEMICOLON=14;
    public static final int DIGIT=15;
    public static final int LETTER=16;
    public static final int WHITESPACE=17;

    // delegates
    // delegators

    public SimpleDeclarativeLexer() {;} 
    public SimpleDeclarativeLexer(CharStream input) {
        this(input, new RecognizerSharedState());
    }
    public SimpleDeclarativeLexer(CharStream input, RecognizerSharedState state) {
        super(input,state);

    }
    public String getGrammarFileName() { return "/prg/code/xreate/antlr/SimpleDeclarative.g"; }

    // $ANTLR start "WHERE"
    public final void mWHERE() throws RecognitionException {
        try {
            int _type = WHERE;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:15:7: ( 'where' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:15:9: 'where'
            {
            match("where"); 


            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "WHERE"

    // $ANTLR start "LET"
    public final void mLET() throws RecognitionException {
        try {
            int _type = LET;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:16:5: ( 'let' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:16:7: 'let'
            {
            match("let"); 


            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "LET"

    // $ANTLR start "EQUAL"
    public final void mEQUAL() throws RecognitionException {
        try {
            int _type = EQUAL;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:17:7: ( '=' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:17:9: '='
            {
            match('='); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "EQUAL"

    // $ANTLR start "SEMICOLON"
    public final void mSEMICOLON() throws RecognitionException {
        try {
            int _type = SEMICOLON;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:18:10: ( ';' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:18:12: ';'
            {
            match(';'); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "SEMICOLON"

    // $ANTLR start "OR"
    public final void mOR() throws RecognitionException {
        try {
            int _type = OR;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:19:4: ( '|' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:19:6: '|'
            {
            match('|'); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "OR"

    // $ANTLR start "COLON"
    public final void mCOLON() throws RecognitionException {
        try {
            int _type = COLON;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:20:7: ( ':' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:20:9: ':'
            {
            match(':'); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "COLON"

    // $ANTLR start "BRACESTART"
    public final void mBRACESTART() throws RecognitionException {
        try {
            int _type = BRACESTART;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:21:12: ( '{' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:21:14: '{'
            {
            match('{'); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "BRACESTART"

    // $ANTLR start "BRACEEND"
    public final void mBRACEEND() throws RecognitionException {
        try {
            int _type = BRACEEND;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:22:10: ( '}' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:22:12: '}'
            {
            match('}'); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "BRACEEND"

    // $ANTLR start "COMMA"
    public final void mCOMMA() throws RecognitionException {
        try {
            int _type = COMMA;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:23:7: ( ',' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:23:9: ','
            {
            match(','); 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "COMMA"

    // $ANTLR start "NUMBER"
    public final void mNUMBER() throws RecognitionException {
        try {
            int _type = NUMBER;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:24:8: ( ( DIGIT )+ )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:24:10: ( DIGIT )+
            {
            // /prg/code/xreate/antlr/SimpleDeclarative.g:24:10: ( DIGIT )+
            int cnt1=0;
            loop1:
            do {
                int alt1=2;
                int LA1_0 = input.LA(1);

                if ( ((LA1_0>='0' && LA1_0<='9')) ) {
                    alt1=1;
                }


                switch (alt1) {
            	case 1 :
            	    // /prg/code/xreate/antlr/SimpleDeclarative.g:24:11: DIGIT
            	    {
            	    mDIGIT(); 

            	    }
            	    break;

            	default :
            	    if ( cnt1 >= 1 ) break loop1;
                        EarlyExitException eee =
                            new EarlyExitException(1, input);
                        throw eee;
                }
                cnt1++;
            } while (true);


            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "NUMBER"

    // $ANTLR start "WORD"
    public final void mWORD() throws RecognitionException {
        try {
            int _type = WORD;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:25:6: ( ( LETTER )+ )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:25:8: ( LETTER )+
            {
            // /prg/code/xreate/antlr/SimpleDeclarative.g:25:8: ( LETTER )+
            int cnt2=0;
            loop2:
            do {
                int alt2=2;
                int LA2_0 = input.LA(1);

                if ( ((LA2_0>='a' && LA2_0<='z')) ) {
                    alt2=1;
                }


                switch (alt2) {
            	case 1 :
            	    // /prg/code/xreate/antlr/SimpleDeclarative.g:25:9: LETTER
            	    {
            	    mLETTER(); 

            	    }
            	    break;

            	default :
            	    if ( cnt2 >= 1 ) break loop2;
                        EarlyExitException eee =
                            new EarlyExitException(2, input);
                        throw eee;
                }
                cnt2++;
            } while (true);


            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "WORD"

    // $ANTLR start "DIGIT"
    public final void mDIGIT() throws RecognitionException {
        try {
            // /prg/code/xreate/antlr/SimpleDeclarative.g:28:7: ( '0' .. '9' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:28:9: '0' .. '9'
            {
            matchRange('0','9'); 

            }

        }
        finally {
        }
    }
    // $ANTLR end "DIGIT"

    // $ANTLR start "LETTER"
    public final void mLETTER() throws RecognitionException {
        try {
            // /prg/code/xreate/antlr/SimpleDeclarative.g:31:8: ( 'a' .. 'z' )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:31:10: 'a' .. 'z'
            {
            matchRange('a','z'); 

            }

        }
        finally {
        }
    }
    // $ANTLR end "LETTER"

    // $ANTLR start "WHITESPACE"
    public final void mWHITESPACE() throws RecognitionException {
        try {
            int _type = WHITESPACE;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // /prg/code/xreate/antlr/SimpleDeclarative.g:33:12: ( ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ )
            // /prg/code/xreate/antlr/SimpleDeclarative.g:33:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+
            {
            // /prg/code/xreate/antlr/SimpleDeclarative.g:33:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+
            int cnt3=0;
            loop3:
            do {
                int alt3=2;
                int LA3_0 = input.LA(1);

                if ( ((LA3_0>='\t' && LA3_0<='\n')||(LA3_0>='\f' && LA3_0<='\r')||LA3_0==' ') ) {
                    alt3=1;
                }


                switch (alt3) {
            	case 1 :
            	    // /prg/code/xreate/antlr/SimpleDeclarative.g:
            	    {
            	    if ( (input.LA(1)>='\t' && input.LA(1)<='\n')||(input.LA(1)>='\f' && input.LA(1)<='\r')||input.LA(1)==' ' ) {
            	        input.consume();

            	    }
            	    else {
            	        MismatchedSetException mse = new MismatchedSetException(null,input);
            	        recover(mse);
            	        throw mse;}


            	    }
            	    break;

            	default :
            	    if ( cnt3 >= 1 ) break loop3;
                        EarlyExitException eee =
                            new EarlyExitException(3, input);
                        throw eee;
                }
                cnt3++;
            } while (true);

             _channel = HIDDEN; 

            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
    // $ANTLR end "WHITESPACE"

    public void mTokens() throws RecognitionException {
        // /prg/code/xreate/antlr/SimpleDeclarative.g:1:8: ( WHERE | LET | EQUAL | SEMICOLON | OR | COLON | BRACESTART | BRACEEND | COMMA | NUMBER | WORD | WHITESPACE )
        int alt4=12;
        alt4 = dfa4.predict(input);
        switch (alt4) {
            case 1 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:10: WHERE
                {
                mWHERE(); 

                }
                break;
            case 2 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:16: LET
                {
                mLET(); 

                }
                break;
            case 3 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:20: EQUAL
                {
                mEQUAL(); 

                }
                break;
            case 4 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:26: SEMICOLON
                {
                mSEMICOLON(); 

                }
                break;
            case 5 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:36: OR
                {
                mOR(); 

                }
                break;
            case 6 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:39: COLON
                {
                mCOLON(); 

                }
                break;
            case 7 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:45: BRACESTART
                {
                mBRACESTART(); 

                }
                break;
            case 8 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:56: BRACEEND
                {
                mBRACEEND(); 

                }
                break;
            case 9 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:65: COMMA
                {
                mCOMMA(); 

                }
                break;
            case 10 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:71: NUMBER
                {
                mNUMBER(); 

                }
                break;
            case 11 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:78: WORD
                {
                mWORD(); 

                }
                break;
            case 12 :
                // /prg/code/xreate/antlr/SimpleDeclarative.g:1:83: WHITESPACE
                {
                mWHITESPACE(); 

                }
                break;

        }

    }


    protected DFA4 dfa4 = new DFA4(this);
    static final String DFA4_eotS =
        "\1\uffff\2\13\12\uffff\3\13\1\22\1\13\1\uffff\1\24\1\uffff";
    static final String DFA4_eofS =
        "\25\uffff";
    static final String DFA4_minS =
        "\1\11\1\150\1\145\12\uffff\1\145\1\164\1\162\1\141\1\145\1\uffff"+
        "\1\141\1\uffff";
    static final String DFA4_maxS =
        "\1\175\1\150\1\145\12\uffff\1\145\1\164\1\162\1\172\1\145\1\uffff"+
        "\1\172\1\uffff";
    static final String DFA4_acceptS =
        "\3\uffff\1\3\1\4\1\5\1\6\1\7\1\10\1\11\1\12\1\13\1\14\5\uffff\1"+
        "\2\1\uffff\1\1";
    static final String DFA4_specialS =
        "\25\uffff}>";
    static final String[] DFA4_transitionS = {
            "\2\14\1\uffff\2\14\22\uffff\1\14\13\uffff\1\11\3\uffff\12\12"+
            "\1\6\1\4\1\uffff\1\3\43\uffff\13\13\1\2\12\13\1\1\3\13\1\7\1"+
            "\5\1\10",
            "\1\15",
            "\1\16",
            "",
            "",
            "",
            "",
            "",
            "",
            "",
            "",
            "",
            "",
            "\1\17",
            "\1\20",
            "\1\21",
            "\32\13",
            "\1\23",
            "",
            "\32\13",
            ""
    };

    static final short[] DFA4_eot = DFA.unpackEncodedString(DFA4_eotS);
    static final short[] DFA4_eof = DFA.unpackEncodedString(DFA4_eofS);
    static final char[] DFA4_min = DFA.unpackEncodedStringToUnsignedChars(DFA4_minS);
    static final char[] DFA4_max = DFA.unpackEncodedStringToUnsignedChars(DFA4_maxS);
    static final short[] DFA4_accept = DFA.unpackEncodedString(DFA4_acceptS);
    static final short[] DFA4_special = DFA.unpackEncodedString(DFA4_specialS);
    static final short[][] DFA4_transition;

    static {
        int numStates = DFA4_transitionS.length;
        DFA4_transition = new short[numStates][];
        for (int i=0; i<numStates; i++) {
            DFA4_transition[i] = DFA.unpackEncodedString(DFA4_transitionS[i]);
        }
    }

    class DFA4 extends DFA {

        public DFA4(BaseRecognizer recognizer) {
            this.recognizer = recognizer;
            this.decisionNumber = 4;
            this.eot = DFA4_eot;
            this.eof = DFA4_eof;
            this.min = DFA4_min;
            this.max = DFA4_max;
            this.accept = DFA4_accept;
            this.special = DFA4_special;
            this.transition = DFA4_transition;
        }
        public String getDescription() {
            return "1:1: Tokens : ( WHERE | LET | EQUAL | SEMICOLON | OR | COLON | BRACESTART | BRACEEND | COMMA | NUMBER | WORD | WHITESPACE );";
        }
    }
 

}