public interface AVList
| Modifier and Type | Method and Description |
|---|---|
void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Adds the specified all-property property change listener that will be called for all list changes.
|
void |
addPropertyChangeListener(java.lang.String propertyName,
java.beans.PropertyChangeListener listener)
Adds a property change listener for the specified key.
|
AVList |
clearList() |
AVList |
copy()
Returns a shallow copy of this
AVList instance: the keys and values themselves are not cloned. |
void |
firePropertyChange(java.beans.PropertyChangeEvent propertyChangeEvent)
Calls all registered property change listeners with the specified property change event.
|
void |
firePropertyChange(java.lang.String propertyName,
java.lang.Object oldValue,
java.lang.Object newValue)
Calls all property change listeners associated with the specified key.
|
java.util.Set<java.util.Map.Entry<java.lang.String,java.lang.Object>> |
getEntries() |
java.lang.String |
getStringValue(java.lang.String key)
Returns the value for a specified key.
|
java.lang.Object |
getValue(java.lang.String key)
Returns the value for a specified key.
|
java.util.Collection<java.lang.Object> |
getValues() |
boolean |
hasKey(java.lang.String key)
Indicates whether a key is in the collection.
|
java.lang.Object |
removeKey(java.lang.String key)
Removes a specified key from the collection if the key exists, otherwise returns without affecting the
collection.
|
void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes the specified all-property property change listener.
|
void |
removePropertyChangeListener(java.lang.String propertyName,
java.beans.PropertyChangeListener listener)
Removes a property change listener associated with the specified key.
|
java.lang.Object |
setValue(java.lang.String key,
java.lang.Object value)
Adds a key/value pair to the list.
|
AVList |
setValues(AVList avList)
Adds the contents of another attribute-value list to the list.
|
void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
listener - the listener to call.java.lang.IllegalArgumentException - if listener is nullPropertyChangeSupportvoid addPropertyChangeListener(java.lang.String propertyName,
java.beans.PropertyChangeListener listener)
propertyName - the key to associate the listener with.listener - the listener to associate with the key.java.lang.IllegalArgumentException - if either propertyName or listener is nullPropertyChangeSupportAVList clearList()
AVList copy()
AVList instance: the keys and values themselves are not cloned.AVList.void firePropertyChange(java.beans.PropertyChangeEvent propertyChangeEvent)
propertyChangeEvent - the eventjava.lang.IllegalArgumentException - if propertyChangeEvent is nullPropertyChangeSupportvoid firePropertyChange(java.lang.String propertyName,
java.lang.Object oldValue,
java.lang.Object newValue)
odValue and newValue are equal and non-null.propertyName - the keyoldValue - the value associated with the key before the even causing the firing.newValue - the new value associated with the key.java.lang.IllegalArgumentException - if propertyName is nullPropertyChangeSupportjava.util.Set<java.util.Map.Entry<java.lang.String,java.lang.Object>> getEntries()
java.lang.String getStringValue(java.lang.String key)
String.key - the attribute name. May not be null.null.java.lang.NullPointerException - if key is null.WWRuntimeException - if the value in the collection is not a String type.java.lang.Object getValue(java.lang.String key)
key - the attribute name. May not be null.null.java.lang.NullPointerException - if key is null.java.util.Collection<java.lang.Object> getValues()
boolean hasKey(java.lang.String key)
key - the attribute name. May not be null.true if the key exists in the collection, otherwise false.java.lang.NullPointerException - if key is null.java.lang.Object removeKey(java.lang.String key)
key - the attribute name. May not be null.java.lang.NullPointerException - if key is null.void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
listener - the listener to remove.java.lang.IllegalArgumentException - if listener is nullPropertyChangeSupportvoid removePropertyChangeListener(java.lang.String propertyName,
java.beans.PropertyChangeListener listener)
propertyName - the key associated with the change listener.listener - the listener to remove.java.lang.IllegalArgumentException - if either propertyName or listener is nullPropertyChangeSupportjava.lang.Object setValue(java.lang.String key,
java.lang.Object value)
key - the attribute name. May not be null.value - the attribute value. May be null, in which case any existing value for the key is
removed from the collection.java.lang.NullPointerException - if key is null.AVList setValues(AVList avList)
avList - the list to copy. May not be null.this, a self reference.java.lang.NullPointerException - if avList is null.