import eclipse 3.1 M4 compiler
[org.ibex.tool.git] / src / org / eclipse / jdt / internal / compiler / ast / ImportReference.java
index 4623b2d..fca4408 100644 (file)
@@ -23,6 +23,7 @@ public class ImportReference extends ASTNode {
        public int declarationSourceEnd;
        public boolean used;
        public int modifiers; // 1.5 addition for static imports
+       public Annotation[] annotations;
 
        public ImportReference(
                        char[][] tokens,
@@ -37,6 +38,10 @@ public class ImportReference extends ASTNode {
                this.sourceStart = (int) (sourcePositions[0] >>> 32);
                this.modifiers = modifiers;
        }
+       
+       public boolean isStatic() {
+               return (this.modifiers & AccStatic) != 0;
+       }
 
        /**
         * @return char[][]
@@ -67,6 +72,11 @@ public class ImportReference extends ASTNode {
        public void traverse(ASTVisitor visitor, CompilationUnitScope scope) {
 
                visitor.visit(this, scope);
+               if (this.annotations != null) {
+                       int annotationsLength = this.annotations.length;
+                       for (int i = 0; i < annotationsLength; i++)
+                               this.annotations[i].traverse(visitor, scope);
+               }
                visitor.endVisit(this, scope);
        }
 }