|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface PropertyList
Listing of Property instances.
| Method Summary | |
|---|---|
Property |
addProperty(String name)
Appends a Property to this PropertyList. |
Property |
addProperty(String name,
String label)
Appends a Property to this PropertyList. |
void |
clear()
Clears the PropertyList. |
Property |
getOrAddProperty(String name)
Convenience method that attempts to get the Property and if not
found adds the Property. |
Properties |
getProperties()
Obtains the Properties populated with the Property
values. |
Property |
getProperty(String name)
Obtains the first Property by the input name. |
String[] |
getPropertyNames()
Obtains the names of the Property instances in the order they
were added. |
String |
getPropertyValue(String name,
String defaultValue)
Convenience method to obtain the Property value. |
void |
normalise()
Normalises the Property instances. |
void |
removeProperty(Property property)
Removes the Property from this PropertyList. |
void |
sort(Comparator<? super Property> comparator)
Enable sorting the Property instances within this
PropertyList. |
| Methods inherited from interface java.lang.Iterable |
|---|
iterator |
| Method Detail |
|---|
Property addProperty(String name,
String label)
Property to this PropertyList.
name - Name of the Property.label - Label of the Property. Should this be blank it will be
defaulted to the name.
Property added.Property addProperty(String name)
Property to this PropertyList.
name - Name of the Property which is also used as the label.
Property added.void removeProperty(Property property)
Property from this PropertyList.
property - Property to be removed.String[] getPropertyNames()
Property instances in the order they
were added.
Property instances.Property getProperty(String name)
Property by the input name.
name - Name of the Property to return.
Property by the input name, or null if
no Property by the name.Property getOrAddProperty(String name)
Property and if not
found adds the Property.
name - Name of the Property to return.
Property by the input name or a newly added
Property if no Property found by the name.
String getPropertyValue(String name,
String defaultValue)
Property value.
name - Name of the Property to obtain its value.defaultValue - Default value should the Property not exist or have
blank value.
Property (or defaultValue if
not available).Properties getProperties()
Properties populated with the Property
values.
Properties.void clear()
PropertyList.
void sort(Comparator<? super Property> comparator)
Property instances within this
PropertyList.
comparator - Comparator to provide comparisons for sorting.void normalise()
Normalises the Property instances.
This will remove:
Property with a blank nameProperty with a blank valueProperty instances by the same name (keeps the
first Property)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||