|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.Dictionary
org.eclipse.osgi.framework.util.Headers
public class Headers
Headers classes. This class implements a Dictionary that has the following behaviour:
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry |
Constructor Summary | |
---|---|
Headers(java.util.Dictionary values)
Create a Headers dictionary from a Dictionary. |
|
Headers(int initialCapacity)
Create an empty Headers dictionary. |
Method Summary | |
---|---|
void |
clear()
|
boolean |
containsKey(java.lang.Object key)
|
boolean |
containsValue(java.lang.Object var0)
|
java.util.Enumeration |
elements()
Values. |
java.util.Set |
entrySet()
|
java.lang.Object |
get(java.lang.Object key)
Support case-insensitivity for keys. |
boolean |
isEmpty()
Tests if this dictionary maps no keys to value. |
java.util.Enumeration |
keys()
Case-preserved keys. |
java.util.Set |
keySet()
|
static Headers |
parseManifest(java.io.InputStream in)
|
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value)
Always throws UnsupportedOperationException. |
void |
putAll(java.util.Map var0)
|
java.lang.Object |
remove(java.lang.Object key)
Always throws UnsupportedOperationException. |
java.lang.Object |
set(java.lang.Object key,
java.lang.Object value)
Set a header value. |
java.lang.Object |
set(java.lang.Object key,
java.lang.Object value,
boolean replace)
Set a header value or optionally replace it if it already exists. |
void |
setReadOnly()
|
int |
size()
Returns the number of entries (distinct keys) in this dictionary. |
java.lang.String |
toString()
|
java.util.Collection |
values()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Map |
---|
equals, hashCode |
Constructor Detail |
---|
public Headers(int initialCapacity)
initialCapacity
- The initial capacity of this Headers object.public Headers(java.util.Dictionary values)
values
- The initial dictionary for this Headers object.
java.lang.IllegalArgumentException
- If a case-variant of the key is
in the dictionary parameter.Method Detail |
---|
public java.util.Enumeration keys()
keys
in class java.util.Dictionary
public java.util.Enumeration elements()
elements
in class java.util.Dictionary
public java.lang.Object get(java.lang.Object key)
get
in interface java.util.Map
get
in class java.util.Dictionary
key
- name.public java.lang.Object set(java.lang.Object key, java.lang.Object value, boolean replace)
key
- Key name.value
- Value of the key or null to remove key.replace
- A value of true will allow a previous
value of the key to be replaced. A value of false
will cause an IllegalArgumentException to be thrown
if a previous value of the key exists.
java.lang.IllegalArgumentException
- If a case-variant of the key is
already present.public java.lang.Object set(java.lang.Object key, java.lang.Object value)
key
- Key name.value
- Value of the key or null to remove key.
java.lang.IllegalArgumentException
- If a case-variant of the key is
already present.public void setReadOnly()
public int size()
size
in interface java.util.Map
size
in class java.util.Dictionary
public boolean isEmpty()
isEmpty
in interface java.util.Map
isEmpty
in class java.util.Dictionary
true
if this dictionary maps no keys to values;
false
otherwise.public java.lang.Object put(java.lang.Object key, java.lang.Object value)
put
in interface java.util.Map
put
in class java.util.Dictionary
key
- header name.value
- header value.
java.lang.UnsupportedOperationException
public java.lang.Object remove(java.lang.Object key)
remove
in interface java.util.Map
remove
in class java.util.Dictionary
key
- header name.
java.lang.UnsupportedOperationException
public java.lang.String toString()
toString
in class java.lang.Object
public static Headers parseManifest(java.io.InputStream in) throws BundleException
BundleException
public void clear()
clear
in interface java.util.Map
public boolean containsKey(java.lang.Object key)
containsKey
in interface java.util.Map
public boolean containsValue(java.lang.Object var0)
containsValue
in interface java.util.Map
public java.util.Set entrySet()
entrySet
in interface java.util.Map
public java.util.Set keySet()
keySet
in interface java.util.Map
public void putAll(java.util.Map var0)
putAll
in interface java.util.Map
public java.util.Collection values()
values
in interface java.util.Map
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |