Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.togethersoft.openapi.sci.visitor
Interface SciStatementVisitor

All Known Implementing Classes:
  SciStatementVisitorAdapter

public interface SciStatementVisitor

Visitor design pattern implementation for `SciStatement`s.

It defines defferent methods for visiting different kinds of statements (declaration statement, return statement etc.). These methods are called up from `SciStatement.accept` method which determines the kind of the statement and runs this visitor's corresponding method, passing the statement as a parameter.

For example, this command ``

     someSciDeclarationStatement.accept(mySciStatementVisitor); //mySciStatementVisitor implements SciStatementVisitor

will call `mySciStatementVisitor.visitDeclarationStatement(SciDeclarationStatement)` method, passing `someSciDeclarationStatement` to it.

The methods of this interface can be also called from SciScope.visitStatements methods.

Every method returns a result of its actions. It can be `null` if it is not required from this visitor to return any information.

Author:
  TogetherSoft
See Also: com.togethersoft.openapi.sci.SciStatement.accept(com.togethersoft.openapi.sci.visitor.SciStatementVisitor), SciStatementVisitorAdapter, com.togethersoft.openapi.sci.visitor

Method Summary
`Object` | `visitCaseStatement(SciCaseStatement sciCaseStatement)` Performs an action upon `SciCaseStatement`.
`Object` | `visitCatchBlockStatement(SciCatchBlockStatement sciCatchBlockStatement)` Performs an action upon `SciCatchBlockStatement`.
`Object` | `visitCompoundStatement(SciCompoundStatement sciCompoundStatement)` Performs an action upon `SciCompoundStatement`.
`Object` | `visitDeclarationStatement(SciDeclarationStatement sciDeclarationStatement)` Performs an action upon `SciDeclarationStatement`.
`Object` | `visitExpressionStatement(SciExpressionStatement sciExpressionStatement)` Performs an action upon `SciExpressionStatement`.
`Object` | `visitIfStatement(SciIfStatement sciIfStatement)` Performs an action upon `SciIfStatement`.
`Object` | `visitLoopStatement(SciLoopStatement sciLoopStatement)` Performs an action upon `SciLoopStatement`.
`Object` | `visitReturnStatement(SciReturnStatement sciReturnStatement)` Performs an action upon `SciReturnStatement`.
`Object` | `visitStatement(SciStatement sciStatement)` Performs an action upon `SciStatement`.
`Object` | `visitSwitchStatement(SciSwitchStatement sciSwitchStatement)` Performs an action upon `SciSwitchStatement`.
`Object` | `visitThrowStatement(SciThrowStatement sciThrowStatement)` Performs an action upon `SciThrowStatement`.
`Object` | `visitTryStatement(SciTryStatement sciTryStatement)` Performs an action upon `SciTryStatement`.

Method Detail

### visitCaseStatement

    public Object visitCaseStatement(SciCaseStatement sciCaseStatement)

  Performs an action upon `SciCaseStatement`.
  Parameters:
    sciReturnStatement - the `SciReturnStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitCatchBlockStatement

    public Object visitCatchBlockStatement(SciCatchBlockStatement sciCatchBlockStatement)

  Performs an action upon `SciCatchBlockStatement`.
  Parameters:
    sciCatchBlockStatement - the `SciCatchBlockStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitCompoundStatement

    public Object visitCompoundStatement(SciCompoundStatement sciCompoundStatement)

  Performs an action upon `SciCompoundStatement`.
  Parameters:
    sciCompoundStatement - the `SciCompoundStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitDeclarationStatement

    public Object visitDeclarationStatement(SciDeclarationStatement sciDeclarationStatement)

  Performs an action upon `SciDeclarationStatement`.
  Parameters:
    sciDeclarationStatement - the `SciDeclarationStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitExpressionStatement

    public Object visitExpressionStatement(SciExpressionStatement sciExpressionStatement)

  Performs an action upon `SciExpressionStatement`.
  Parameters:
    sciExpressionStatement - the `SciExpressionStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitIfStatement

    public Object visitIfStatement(SciIfStatement sciIfStatement)

  Performs an action upon `SciIfStatement`.
  Parameters:
    sciIfStatement - the `SciIfStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitLoopStatement

    public Object visitLoopStatement(SciLoopStatement sciLoopStatement)

  Performs an action upon `SciLoopStatement`.
  Parameters:
    sciLoopStatement - the `SciLoopStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitReturnStatement

    public Object visitReturnStatement(SciReturnStatement sciReturnStatement)

  Performs an action upon `SciReturnStatement`.
  Parameters:
    sciReturnStatement - the `SciReturnStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitStatement

    public Object visitStatement(SciStatement sciStatement)

  Performs an action upon `SciStatement`.
  Parameters:
    sciStatement - the `SciStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitSwitchStatement

    public Object visitSwitchStatement(SciSwitchStatement sciSwitchStatement)

  Performs an action upon `SciSwitchStatement`.
  Parameters:
    sciSwitchStatement - the `SciSwitchStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitThrowStatement

    public Object visitThrowStatement(SciThrowStatement sciThrowStatement)

  Performs an action upon `SciThrowStatement`.
  Parameters:
    sciReturnStatement - the `SciThrowStatement` which is the subject for the action
  Returns: a visitor-specific result

### visitTryStatement

    public Object visitTryStatement(SciTryStatement sciTryStatement)

  Performs an action upon `SciTryStatement`.
  Parameters:
    sciTryStatement - the `SciTryStatement` which is the subject for the action
  Returns: a visitor-specific result

Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD