Attributes


Attributes java.util.jar

Java 1.2 cloneable collection

This class is a java.util.Map that maps the attribute names of a JAR file manifest to arbitrary string values. The JAR manifest format specifies that attribute names can contain only the ASCII characters A to Z (uppercase and lowercase), the digits 0 through 9, and the hyphen and underscore characters. Thus, this class uses Attributes. Name as the type of attribute names, in addition to the more general String class. Although you can create your own Attributes objects, you more commonly obtain Attributes objects from a Manifest .

Figure 16-107. java.util.jar.Attributes

 public class  Attributes  implements java.util.Map<Object,Object>, Cloneable {  // Public Constructors  public  Attributes  ( );        public  Attributes  (java.util.jar.Attributes  attr  );        public  Attributes  (int  size  );  // Nested Types  public static class  Name  ;  // Public Instance Methods  public String  getValue  (String  name  );        public String  getValue  (Attributes.Name  name  );        public String  putValue  (String  name  , String  value  );  // Methods Implementing Map  public void  clear  ( );        public boolean  containsKey  (Object  name  );        public boolean  containsValue  (Object  value  );        public java.util.Set<java.util.Map.Entry<Object,Object>>  entrySet  ( );        public boolean  equals  (Object  o  );        public Object  get  (Object  name  );        public int  hashCode  ( );        public boolean  isEmpty  ( );  default:true  public java.util.Set<Object>  keySet  ( );        public Object  put  (Object  name  , Object  value  );        public void  putAll  (java.util.Map<?,?>  attr  );        public Object  remove  (Object  name  );        public int  size  ( );        public java.util.Collection<Object>  values  ( );  // Public Methods Overriding Object  public Object  clone  ( );  // Protected Instance Fields  protected java.util.Map<Object,Object>  map  ;   } 

Returned By

java.net.JarURLConnection.{getAttributes( ) , getMainAttributes( )} , JarEntry.getAttributes( ) , Manifest.{getAttributes( ) , getMainAttributes( )}



Java In A Nutshell
Java In A Nutshell, 5th Edition
ISBN: 0596007736
EAN: 2147483647
Year: 2004
Pages: 1220

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net