|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.AbstractMap java.util.HashMap com.adobe.flashaccess.sdk.util.ApplicationProperties
public class ApplicationProperties
This class contains application-defined properties. Each key can be mapped to a list of byte[]
values; however,
the order of the values may not be preserved.
This class also contains convenience methods for putting/getting String objects (uses String.getBytes("UTF-8")
to convert from String
to byte[]
). Keys cannot be null
.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.util.AbstractMap |
---|
AbstractMap.SimpleEntry, AbstractMap.SimpleImmutableEntry |
Method Summary | |
---|---|
void |
add(String key,
byte[] val)
Adds the specified value to the list of values associated with the key. |
void |
addUTF8String(String key,
String val)
Converts the value to a byte[] , then performs the same operation as
ApplicationProperties.add(String, byte[]) . |
Collection |
get(String key)
See HashMap.get . |
Collection |
getAsUTF8Strings(String key)
This method performs the same operation as ApplicationProperties.getSingleValueAsUTF8String(String) , but converts the result to a list of String objects. |
byte[] |
getSingleValue(String key)
Retrieves the value of a key with only one value. |
String |
getSingleValueAsUTF8String(String key)
This method performs the same operation as ApplicationProperties.getSingleValue(String) , but converts the result to a String . |
Collection |
put(String key,
Collection value)
This method performs the same operation as HashMap.put , except that it does not allow null keys. |
Methods inherited from class java.util.HashMap |
---|
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, putAll, remove, size, values |
Methods inherited from class java.util.AbstractMap |
---|
equals, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Map |
---|
equals, hashCode |
Method Detail |
---|
public Collection get(String key)
HashMap.get
.
key
- The key.
public Collection put(String key, Collection value)
HashMap.put
, except that it does not allow null
keys. The
order of the values may not be preserved.
put
in interface Map
put
in class HashMap
key
- The key.value
- The value assigned to the key as Collection<byte[]>. Null values in the list will be ignored.
public void add(String key, byte[] val)
ApplicationProperties.put(String, Collection)
.
key
- The key to which to assign the value.val
- The value to assign to the specified key.public void addUTF8String(String key, String val)
byte[]
, then performs the same operation as
ApplicationProperties.add(String, byte[])
.
key
- The key to which to assign the value.val
- The value to assign to the specified key.public byte[] getSingleValue(String key)
key
- The key for which to retrieve values.
null
if the
key is not present.public String getSingleValueAsUTF8String(String key)
ApplicationProperties.getSingleValue(String)
, but converts the result to a String
.
key
- The key for which to retrieve values.
null
if the
key is not present.public Collection getAsUTF8Strings(String key)
ApplicationProperties.getSingleValueAsUTF8String(String)
, but converts the result to a list of String
objects.
key
- The key for which to retrieve values.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |