org.apache.felix.gogo.runtime

## Class Parser

- java.lang.Object
- - org.apache.felix.gogo.runtime.Parser

    public class Parser
    extends Object

### Nested Class Summary

Nested Classes
`static class` `Parser.Array` [ a b ...] [ k1=v1 k2=v2 ...]
`static class` `Parser.Closure` { program }
`static class` `Parser.Executable`
`static class` `Parser.Operator`
`static class` `Parser.Pipeline` token1 | token2 | ...
`static class` `Parser.Program` pipe1 ; pipe2 ; ...
`static class` `Parser.Sequence` ( program )
`static class` `Parser.Statement`

### Field Summary

Fields
`protected LinkedList<String>` `stack`
`protected List<Parser.Statement>` `statements`
`protected List<Token>` `tokens`
`protected Tokenizer` `tz`

### Constructor Summary

Constructors
Constructor and Description
`Parser(CharSequence line)`

### Method Summary

All Methods Instance Methods Concrete Methods
`Parser.Array` `array()`
`Parser.Closure` `closure()`
`protected Token` `end(String str)`
`protected Token` `expect(String str)`
`protected void` `expectNotNull()`
`protected Token` `next()`
`Parser.Program` `program()`
`protected void` `push(Token t)`
`Parser.Sequence` `sequence()`
`protected Token` `start(String str, String missing)`
`Parser.Statement` `statement()`
`List<Parser.Statement>` `statements()`
`List<Token>` `tokens()`
`protected Token` `whole(List<? extends Token> tokens, int index)`
`protected Token` `whole(Token b, Token e)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### tz

    protected final Tokenizer tz

#### stack

    protected final LinkedList<String> stack

#### tokens

    protected final List<Token> tokens

#### statements

    protected final List<Parser.Statement> statements

### Constructor Detail

#### Parser

    public Parser(CharSequence line)

### Method Detail

#### tokens

    public List<Token> tokens()

#### statements

    public List<Parser.Statement> statements()

#### program

    public Parser.Program program()

#### push

    protected void push(Token t)

#### next

    protected Token next()

#### sequence

    public Parser.Sequence sequence()

#### closure

    public Parser.Closure closure()

#### statement

    public Parser.Statement statement()

#### array

    public Parser.Array array()

#### expectNotNull

    protected void expectNotNull()

#### start

    protected Token start(String str,
                          String missing)

#### end

    protected Token end(String str)

#### expect

    protected Token expect(String str)

#### whole

    protected Token whole(List<? extends Token> tokens,
                          int index)

#### whole

    protected Token whole(Token b,
                          Token e)