< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/classfile/Attributes.java

Print this page

        

@@ -67,10 +67,15 @@
                 // don't enter invalid names in map
             }
         }
     }
 
+    public Attributes(Map<String, Attribute> attributes) {
+        this.attrs = attributes.values().toArray(new Attribute[attributes.size()]);
+        map = attributes;
+    }
+
     public Iterator<Attribute> iterator() {
         return Arrays.asList(attrs).iterator();
     }
 
     public Attribute get(int index) {
< prev index next >