com.borland.primetime.properties
Class Property

java.lang.Object
  |
  +--com.borland.primetime.properties.Property
Direct Known Subclasses:
GlobalArrayProperty, GlobalProperty, MapArrayProperty, MapProperty, NodeArrayProperty, NodeProperty

public abstract class Property
extends java.lang.Object
implements java.lang.Comparable

A Property instance is a description of a single user setting. Each property combines a category and a property name with read / write semantics defined by an individual Property subclass.


Field Summary
protected  java.lang.String category
           
protected  java.lang.String name
           
 
Constructor Summary
protected Property(java.lang.String category, java.lang.String name)
           
 
Method Summary
 int compareTo(java.lang.Object other)
          The natural order for Property instances sorts by category name first, then by property name.
 boolean equals(java.lang.Object other)
          Two Property instances are considered equivelant if their name and category are identical.
 java.lang.String getPropertyCategory()
           
 java.lang.String getPropertyName()
           
 int hashCode()
          Retrieve the Property's hashCode.
 java.lang.String toString()
          Returns a description of the property.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

category

protected java.lang.String category

name

protected java.lang.String name
Constructor Detail

Property

protected Property(java.lang.String category,
                   java.lang.String name)
Method Detail

getPropertyCategory

public java.lang.String getPropertyCategory()

getPropertyName

public java.lang.String getPropertyName()

hashCode

public int hashCode()
Retrieve the Property's hashCode.
Overrides:
hashCode in class java.lang.Object
Returns:
A hash code for this Property.

equals

public boolean equals(java.lang.Object other)
Two Property instances are considered equivelant if their name and category are identical. Note that the implementation depends on both values being uniqued via intern.
Overrides:
equals in class java.lang.Object

compareTo

public int compareTo(java.lang.Object other)
The natural order for Property instances sorts by category name first, then by property name. Note that the implementation depends on both values being uniqued via intern.
Specified by:
compareTo in interface java.lang.Comparable
Parameters:
other - The Property to compare this property against.
Returns:
-1 if this property should appear earlier than other, 1 if it should appear later, and zero if the two properties are equivelant.

toString

public java.lang.String toString()
Returns a description of the property.
Overrides:
toString in class java.lang.Object
Returns:
A description of the form "PropertySubclass(Category.Name)"