DynamicJava Javadoc: Class SwitchStatement

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## koala.dynamicjava.tree
Class SwitchStatement

    java.lang.Object
      |
      +--koala.dynamicjava.tree.Node
            |
            +--koala.dynamicjava.tree.Statement
                  |
                  +--koala.dynamicjava.tree.SwitchStatement

public class SwitchStatement
extends Statement

This class represents the switch statement nodes of the syntax tree

Field Summary
`static java.lang.String` | `BINDINGS` The bindings property name
`static java.lang.String` | `SELECTOR` The selector property name

Fields inherited from class koala.dynamicjava.tree.Node
`BEGIN_COLUMN, BEGIN_LINE, END_COLUMN, END_LINE, FILENAME`

Constructor Summary
`SwitchStatement(Expression sel, java.util.List cases, java.lang.String fn, int bl, int bc, int el, int ec)` Creates a new switch statement

Method Summary
`java.lang.Object` | `acceptVisitor(Visitor visitor)` Allows a visitor to traverse the tree
`java.util.List` | `getBindings()` Returns the 'case' bindings
`Expression` | `getSelector()` Gets the selector
`void` | `setBindings(java.util.List l)` Sets the bindings
`void` | `setSelector(Expression e)` Sets the selector

Methods inherited from class koala.dynamicjava.tree.Node
`addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getFilename, getProperties, getProperty, hasProperty, removePropertyChangeListener, removePropertyChangeListener, setBeginColumn, setBeginLine, setEndColumn, setEndLine, setFilename, setProperty`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### SELECTOR

    public static final java.lang.String SELECTOR

  The selector property name

### BINDINGS

    public static final java.lang.String BINDINGS

  The bindings property name

Constructor Detail

### SwitchStatement

    public SwitchStatement(Expression sel,
                           java.util.List cases,
                           java.lang.String fn,
                           int bl,
                           int bc,
                           int el,
                           int ec)

  Creates a new switch statement
  Parameters:
    `sel` - the selector
    `cases` - the case bindings (SwitchBlocks)
    `fn` - the filename
    `bl` - the begin line
    `bc` - the begin column
    `el` - the end line
    `ec` - the end column
  Throws:
    `java.lang.IllegalArgumentException` - if sel is null or cases is null

Method Detail

### getSelector

    public Expression getSelector()

  Gets the selector

### setSelector

    public void setSelector(Expression e)

  Sets the selector
  Throws:
    `java.lang.IllegalArgumentException` - if e is null

### getBindings

    public java.util.List getBindings()

  Returns the 'case' bindings

### setBindings

    public void setBindings(java.util.List l)

  Sets the bindings
  Throws:
    `java.lang.IllegalArgumentException` - if e is null

### acceptVisitor

    public java.lang.Object acceptVisitor(Visitor visitor)

  Allows a visitor to traverse the tree
  Overrides:
    `acceptVisitor` in class `Node`
  Parameters:
    `visitor` - the visitor to accept

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001 Stephane Hillion. All Rights Reserved.