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

## net.sourceforge.pmd.symboltable
Class LocalScope

    java.lang.Object
      net.sourceforge.pmd.symboltable.AbstractScope
          net.sourceforge.pmd.symboltable.LocalScope

All Implemented Interfaces:
  Scope

    public class LocalScope

extends AbstractScope

Field Summary
`protected java.util.Map<VariableNameDeclaration,java.util.List<NameOccurrence>>` | `variableNames`

Constructor Summary
`LocalScope()`

Method Summary
`void` | `addDeclaration(VariableNameDeclaration nameDecl)` Add a variable declaration to this scope
`NameDeclaration` | `addVariableNameOccurrence(NameOccurrence occurrence)` Adds a NameOccurrence to this scope - only call this after getting a true back from contains()
`NameDeclaration` | `findVariableHere(NameOccurrence occurrence)`
`java.util.Map<VariableNameDeclaration,java.util.List<NameOccurrence>>` | `getVariableDeclarations()` Returns a Map (VariableNameDeclaration->List(NameOccurrence,NameOccurrence)) of declarations that exist at this scope
`java.lang.String` | `toString()`

Methods inherited from class net.sourceforge.pmd.symboltable.AbstractScope
`addDeclaration, addDeclaration, contains, getClassDeclarations, getEnclosingClassScope, getEnclosingMethodScope, getEnclosingSourceFileScope, getParent, glomNames, setParent`

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

Field Detail

### variableNames

    protected java.util.Map<VariableNameDeclaration,java.util.List<NameOccurrence>> variableNames

Constructor Detail

### LocalScope

    public LocalScope()

Method Detail

### addVariableNameOccurrence

    public NameDeclaration addVariableNameOccurrence(NameOccurrence occurrence)

  Description copied from interface: `Scope`
  Adds a NameOccurrence to this scope - only call this after getting a true back from contains()

### getVariableDeclarations

    public java.util.Map<VariableNameDeclaration,java.util.List<NameOccurrence>> getVariableDeclarations()

  Description copied from interface: `Scope`
  Returns a Map (VariableNameDeclaration->List(NameOccurrence,NameOccurrence)) of declarations that exist at this scope

### addDeclaration

    public void addDeclaration(VariableNameDeclaration nameDecl)

  Description copied from interface: `Scope`
  Add a variable declaration to this scope

### findVariableHere

    public NameDeclaration findVariableHere(NameOccurrence occurrence)

  Specified by:
    `findVariableHere` in class `AbstractScope`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

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

Copyright © 2002-2009 InfoEther. All Rights Reserved.