org.itracker.model
Class NameValuePair

java.lang.Object
  extended by org.itracker.model.AbstractEntity
      extended by org.itracker.model.NameValuePair
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Entity>, Entity

public class NameValuePair
extends AbstractEntity

Class provides basic storage for name values pairs. The name is usually a key of some type, like a status number, and the value is a localized name for that key.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.itracker.model.AbstractEntity
AbstractEntity.CreateDateComparator, AbstractEntity.IdComparator, AbstractEntity.LastModifiedDateComparator
 
Field Summary
static Comparator<NameValuePair> KEY_COMPARATOR
           
static Comparator<NameValuePair> VALUE_COMPARATOR
           
 
Fields inherited from class org.itracker.model.AbstractEntity
CREATE_DATE_COMPARATOR, ID_COMPARATOR, LAST_MODIFIED_DATE_COMPARATOR
 
Constructor Summary
NameValuePair(String name, String value)
           
 
Method Summary
 int compareKeyTo(NameValuePair other)
           
 int compareValueTo(NameValuePair other)
           
 String getName()
          Returns the name of the name/value pair.
 String getValue()
          Returns the value of the name/value pair.
 void setName(String name)
          Sets the name of the name/value pair.
 void setValue(String value)
          Sets the value of the name/value pair.
 String toString()
           
 
Methods inherited from class org.itracker.model.AbstractEntity
clone, compareTo, equals, getCreateDate, getId, getLastModifiedDate, hashCode, isNew, setCreateDate, setId, setLastModifiedDate
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

KEY_COMPARATOR

public static final Comparator<NameValuePair> KEY_COMPARATOR

VALUE_COMPARATOR

public static final Comparator<NameValuePair> VALUE_COMPARATOR
Constructor Detail

NameValuePair

public NameValuePair(String name,
                     String value)
Method Detail

getName

public String getName()
Returns the name of the name/value pair.


setName

public void setName(String name)
Sets the name of the name/value pair.


getValue

public String getValue()
Returns the value of the name/value pair.


setValue

public void setValue(String value)
Sets the value of the name/value pair.


compareKeyTo

public int compareKeyTo(NameValuePair other)

compareValueTo

public int compareValueTo(NameValuePair other)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2002-2012 itracker. All Rights Reserved.