This map and its views have a predictable iteration order, namely the
order that keys were inserted into the map, as with LinkedHashMap
.
Manifest
Modifier and Type | Class and Description |
---|---|
public static class | Attributes.
The Attributes.Name class represents an attribute name stored in this Map. |
Modifier and Type | Field and Description |
---|---|
protected Map | map
The attribute name-value mappings. |
Access | Constructor and Description |
---|---|
public | |
public | Attributes(int
the initial number of attributes size)Constructs a new, empty Attributes object with the specified initial size. |
public | Attributes(Attributes
the specified Attributes attr)Constructs a new Attributes object with the same attribute name-value mappings as in the specified Attributes. |
Modifier and Type | Method and Description |
---|---|
public void | |
public Object | clone()
Overrides java. Returns a copy of the Attributes, implemented as follows: public Object clone() { return new Attributes(this); } |
public boolean | Returns: true if this Map contains the specified attribute namethe attribute name name)Implements java. Returns true if this Map contains the specified attribute name (key). |
public boolean | Returns: true if this Map maps one or more attribute names to the specified valuethe attribute value value)Implements java. Returns true if this Map maps one or more attribute names (keys) to the specified value. |
public Set | entrySet()
Implements java. Returns a Collection view of the attribute name-value mappings contained in this Map. |
public boolean | Returns: true if the specified Object is equal to this Mapthe Object to be compared o)Overrides java. Implements java. Compares the specified object to the underlying map for equality. |
public Object | Returns: the value of the specified attribute name, or null if not found.the attribute name name)Implements java. Returns the value of the specified attribute name, or null if the attribute name was not found. |
public String | |
public String | Returns: the String value of the specified Attribute.Name, or null if not found.the Attributes.Name object nameReturns the value of the specified Attributes.Name, or null if the attribute was not found. |
public int | hashCode()
Overrides java. Implements java. Returns the hash code value for this Map. |
public boolean | |
public Set | keySet()
Implements java. Returns a Set view of the attribute names (keys) contained in this Map. |
public Object | Returns: the previous value of the attribute, or null if nonethe attribute name name, Object the attribute value value)Implements java. Associates the specified value with the specified attribute name (key) in this Map. |
public void | putAll(Map<?, ?>
the Attributes to be stored in this map attr)Implements java. Copies all of the attribute name-value mappings from the specified Attributes to this Map. |
public String | |
pack-priv void | |
pack-priv int | |
public Object | Returns: the previous value of the attribute, or null if noneattribute name name)Implements java. Removes the attribute with the specified name (key) from this Map. |
public int | |
public Collection | values()
Implements java. Returns a Collection view of the attribute values contained in this Map. |
pack-priv void | |
pack-priv void |
map | back to summary |
---|---|
protected Map<Object, Object> map The attribute name-value mappings. |
Attributes | back to summary |
---|---|
public Attributes() Constructs a new, empty Attributes object with default size. |
Attributes | back to summary |
---|---|
public Attributes(int size) Constructs a new, empty Attributes object with the specified initial size.
|
Attributes | back to summary |
---|---|
public Attributes(Attributes attr) Constructs a new Attributes object with the same attribute name-value mappings as in the specified Attributes.
|
clear | back to summary |
---|---|
public void clear() Implements java. Removes all attributes from this Map. |
clone | back to summary |
---|---|
public Object clone() Overrides java. Returns a copy of the Attributes, implemented as follows: public Object clone() { return new Attributes(this); }Since the attribute names and values are themselves immutable, the Attributes returned can be safely modified without affecting the original.
|
containsKey | back to summary |
---|---|
public boolean containsKey(Object name) Implements java. Returns true if this Map contains the specified attribute name (key).
|
containsValue | back to summary |
---|---|
public boolean containsValue(Object value) Implements java. Returns true if this Map maps one or more attribute names (keys) to the specified value.
|
entrySet | back to summary |
---|---|
public Set Implements java. Returns a Collection view of the attribute name-value mappings contained in this Map. |
equals | back to summary |
---|---|
public boolean equals(Object o) Overrides java. Implements java. Compares the specified object to the underlying map for equality. Returns true if the given object is also a Map and the two maps represent the same mappings.
|
get | back to summary |
---|---|
public Object get(Object name) Implements java. Returns the value of the specified attribute name, or null if the attribute name was not found. |
getValue | back to summary |
---|---|
public String getValue(String name) Returns the value of the specified attribute name, specified as a string, or null if the attribute was not found. The attribute name is case-insensitive. This method is defined as: return (String)get(new Attributes.Name((String)name));
|
getValue | back to summary |
---|---|
public String getValue(Attributes. Returns the value of the specified Attributes.Name, or null if the attribute was not found. This method is defined as: return (String)get(name);
|
hashCode | back to summary |
---|---|
public int hashCode() Overrides java. Implements java. Returns the hash code value for this Map.
|
isEmpty | back to summary |
---|---|
public boolean isEmpty() Implements java. Returns true if this Map contains no attributes.
|
keySet | back to summary |
---|---|
public Set Implements java. Returns a Set view of the attribute names (keys) contained in this Map.
|
put | back to summary |
---|---|
public Object put(Object name, Object value) Implements java. Associates the specified value with the specified attribute name (key) in this Map. If the Map previously contained a mapping for the attribute name, the old value is replaced.
|
putAll | back to summary |
---|---|
public void putAll(Map<?, ?> attr) Implements java. Copies all of the attribute name-value mappings from the specified Attributes to this Map. Duplicate mappings will be replaced.
|
putValue | back to summary |
---|---|
public String putValue(String name, String value) Associates the specified value with the specified attribute name, specified as a String. The attributes name is case-insensitive. If the Map previously contained a mapping for the attribute name, the old value is replaced. This method is defined as: return (String)put(new Attributes.Name(name), value);
|
read | back to summary |
---|---|
pack-priv void read(Manifest. |
read | back to summary |
---|---|
pack-priv int read(Manifest. |
remove | back to summary |
---|---|
public Object remove(Object name) Implements java. Removes the attribute with the specified name (key) from this Map. Returns the previous attribute value, or null if none. |
size | back to summary |
---|---|
public int size() Implements java. Returns the number of attributes in this Map.
|
values | back to summary |
---|---|
public Collection Implements java. Returns a Collection view of the attribute values contained in this Map.
|
write | back to summary |
---|---|
pack-priv void write(DataOutputStream out) throws IOException |
writeMain | back to summary |
---|---|
pack-priv void writeMain(DataOutputStream out) throws IOException |
Modifier and Type | Field and Description |
---|---|
public static final Attributes. | CLASS_PATH
|
public static final Attributes. | CONTENT_TYPE
|
public static final Attributes. | EXTENSION_INSTALLATION
Deprecated
Extension mechanism is no longer supported.
Name object for Extension-Installation manifest attribute.
|
public static final Attributes. | EXTENSION_LIST
|
public static final Attributes. | EXTENSION_NAME
|
private final int | |
public static final Attributes. | IMPLEMENTATION_TITLE
|
public static final Attributes. | IMPLEMENTATION_URL
Deprecated
Extension mechanism is no longer supported.
Name object for Implementation-URL
manifest attribute.
|
public static final Attributes. | IMPLEMENTATION_VENDOR
|
public static final Attributes. | IMPLEMENTATION_VENDOR_ID
Deprecated
Extension mechanism is no longer supported.
Name object for Implementation-Vendor-Id
manifest attribute.
|
public static final Attributes. | IMPLEMENTATION_VERSION
|
private static Map | KNOWN_NAMES
Avoid allocation for common Names |
public static final Attributes. | MAIN_CLASS
|
public static final Attributes. | MANIFEST_VERSION
|
public static final Attributes. | MULTI_RELEASE
|
private final String | |
public static final Attributes. | SEALED
|
public static final Attributes. | SIGNATURE_VERSION
|
public static final Attributes. | SPECIFICATION_TITLE
|
public static final Attributes. | SPECIFICATION_VENDOR
|
public static final Attributes. | SPECIFICATION_VERSION
|
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
private static void | |
public boolean | Returns: true if this attribute name is equal to the specified attribute objectthe object to compare o)Overrides java. Compares this attribute name to another for equality. |
private final int | |
public int | |
pack-priv static final Attributes. | |
public String |
CLASS_PATH | back to summary |
---|---|
public static final Attributes.
|
CONTENT_TYPE | back to summary |
---|---|
public static final Attributes.
|
EXTENSION_INSTALLATION | back to summary |
---|---|
public static final Attributes. Deprecated Extension mechanism is no longer supported.
|
EXTENSION_LIST | back to summary |
---|---|
public static final Attributes.
|
EXTENSION_NAME | back to summary |
---|---|
public static final Attributes.
|
hashCode | back to summary |
---|---|
private final int hashCode |
IMPLEMENTATION_TITLE | back to summary |
---|---|
public static final Attributes.
|
IMPLEMENTATION_URL | back to summary |
---|---|
public static final Attributes. Deprecated Extension mechanism is no longer supported.
|
IMPLEMENTATION_VENDOR | back to summary |
---|---|
public static final Attributes.
|
IMPLEMENTATION_VENDOR_ID | back to summary |
---|---|
public static final Attributes. Deprecated Extension mechanism is no longer supported.
|
IMPLEMENTATION_VERSION | back to summary |
---|---|
public static final Attributes.
|
KNOWN_NAMES | back to summary |
---|---|
private static Map<String, Attributes. Avoid allocation for common Names |
MAIN_CLASS | back to summary |
---|---|
public static final Attributes.
|
MANIFEST_VERSION | back to summary |
---|---|
public static final Attributes.
|
MULTI_RELEASE | back to summary |
---|---|
public static final Attributes.
|
name | back to summary |
---|---|
private final String name |
SEALED | back to summary |
---|---|
public static final Attributes.
|
SIGNATURE_VERSION | back to summary |
---|---|
public static final Attributes.
|
SPECIFICATION_TITLE | back to summary |
---|---|
public static final Attributes.
|
SPECIFICATION_VENDOR | back to summary |
---|---|
public static final Attributes.
|
SPECIFICATION_VERSION | back to summary |
---|---|
public static final Attributes.
|
Name | back to summary |
---|---|
public Name(String name) Constructs a new attribute name using the given string name.
|
addName | back to summary |
---|---|
private static void addName(Map<String, Attributes. |
equals | back to summary |
---|---|
public boolean equals(Object o) Overrides java. Compares this attribute name to another for equality.
|
hash | back to summary |
---|---|
private final int hash(String name) |
hashCode | back to summary |
---|---|
public int hashCode() Overrides java. Computes the hash value for this attribute name.
|
of | back to summary |
---|---|
pack-priv static final Attributes. |
toString | back to summary |
---|---|
public String toString() Overrides java. Returns the attribute name as a String.
|