koala.dynamicjava.tree
Class InterfaceDeclaration

java.lang.Object
  extended by koala.dynamicjava.tree.Node
      extended by koala.dynamicjava.tree.Declaration
          extended by koala.dynamicjava.tree.TypeDeclaration
              extended by koala.dynamicjava.tree.InterfaceDeclaration
All Implemented Interfaces:
SourceInfo.Wrapper

public class InterfaceDeclaration
extends TypeDeclaration

This class represents an interface declaration

Version:
1.0 - 1999/05/27
Author:
Stephane Hillion

Constructor Summary
InterfaceDeclaration(ModifierSet mods, boolean ann, java.lang.String name, java.util.List<? extends ReferenceTypeName> impl, java.util.List<Node> body)
          Creates a new interface declaration
InterfaceDeclaration(ModifierSet mods, boolean ann, java.lang.String name, java.util.List<? extends ReferenceTypeName> impl, java.util.List<Node> body, SourceInfo si)
          Creates a new interface declaration
InterfaceDeclaration(ModifierSet mods, boolean ann, java.lang.String name, Option<java.util.List<TypeParameter>> tparams, java.util.List<? extends ReferenceTypeName> impl, java.util.List<Node> body)
          Creates a new interface declaration
InterfaceDeclaration(ModifierSet mods, boolean ann, java.lang.String name, Option<java.util.List<TypeParameter>> tparams, java.util.List<? extends ReferenceTypeName> impl, java.util.List<Node> body, SourceInfo si)
          Creates a new interface declaration
 
Method Summary
<T> T
acceptVisitor(Visitor<T> visitor)
          Allows a visitor to traverse the tree
 boolean isAnnotation()
          Whether this is an annotation declaration.
 void setIsAnnotation(boolean ann)
          Sets whether this is an annotation declaration.
 java.lang.String toString()
          Implementation of toString for use in unit testing
protected  java.lang.String toStringHelper()
           
 
Methods inherited from class koala.dynamicjava.tree.TypeDeclaration
getInterfaces, getMembers, getName, getTypeParams, setInterfaces, setMembers, setName, setTypeArgs, setTypeArgs
 
Methods inherited from class koala.dynamicjava.tree.Declaration
getModifiers, setModifiers
 
Methods inherited from class koala.dynamicjava.tree.Node
archiveProperties, getProperties, getProperty, getSourceInfo, hasProperty, setProperty, setSourceInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InterfaceDeclaration

public InterfaceDeclaration(ModifierSet mods,
                            boolean ann,
                            java.lang.String name,
                            Option<java.util.List<TypeParameter>> tparams,
                            java.util.List<? extends ReferenceTypeName> impl,
                            java.util.List<Node> body)
Creates a new interface declaration

Parameters:
mods - the modifiers
ann - whether this is an annotation
name - the name of the interface to declare
tparams - type parameters
impl - the list of implemented interfaces. Can be null.
body - the list of fields declarations

InterfaceDeclaration

public InterfaceDeclaration(ModifierSet mods,
                            boolean ann,
                            java.lang.String name,
                            java.util.List<? extends ReferenceTypeName> impl,
                            java.util.List<Node> body)
Creates a new interface declaration

Parameters:
mods - the modifiers
ann - whether this is an annotation
name - the name of the interface to declare
impl - the list of implemented interfaces. Can be null.
body - the list of fields declarations

InterfaceDeclaration

public InterfaceDeclaration(ModifierSet mods,
                            boolean ann,
                            java.lang.String name,
                            Option<java.util.List<TypeParameter>> tparams,
                            java.util.List<? extends ReferenceTypeName> impl,
                            java.util.List<Node> body,
                            SourceInfo si)
Creates a new interface declaration

Parameters:
mods - the modifiers
ann - whether this is an annotation
name - the name of the interface to declare
tparams - type parameters
impl - the list of implemented interfaces. Can be null.
body - the list of fields declarations

InterfaceDeclaration

public InterfaceDeclaration(ModifierSet mods,
                            boolean ann,
                            java.lang.String name,
                            java.util.List<? extends ReferenceTypeName> impl,
                            java.util.List<Node> body,
                            SourceInfo si)
Creates a new interface declaration

Parameters:
mods - the modifiers
ann - whether this is an annotation
name - the name of the interface to declare
impl - the list of implemented interfaces. Can be null.
body - the list of fields declarations
Method Detail

isAnnotation

public boolean isAnnotation()
Whether this is an annotation declaration.


setIsAnnotation

public void setIsAnnotation(boolean ann)
Sets whether this is an annotation declaration.

Throws:
java.lang.IllegalArgumentException - if s is null

acceptVisitor

public <T> T acceptVisitor(Visitor<T> visitor)
Allows a visitor to traverse the tree

Specified by:
acceptVisitor in class Node
Parameters:
visitor - the visitor to accept

toString

public java.lang.String toString()
Implementation of toString for use in unit testing

Overrides:
toString in class java.lang.Object

toStringHelper

protected java.lang.String toStringHelper()