com.zphinx.spine.vo.dto
Class StringAttributeBean

java.lang.Object
  extended by com.zphinx.spine.vo.dto.StringAttributeBean
All Implemented Interfaces:
DataTransferObject, Serializable
Direct Known Subclasses:
UserListBean

public class StringAttributeBean
extends Object
implements DataTransferObject

StringAttributeBean defines a bean whose name and value can only be a String by associating its name with its value.

Version:
$1.0

Copyright ©Zphinx Software Solutions

Author:
David Ladapo
See Also:
Serialized Form

Constructor Summary
StringAttributeBean(String name, String value)
          Constructor which sets the name and the value of this object
StringAttributeBean(String name, String value, Locale locale)
           
StringAttributeBean(String name, String value, Locale locale, String sessionId)
           
 
Method Summary
 boolean equals(Object object)
          Compares the current StringAttributeBean Object with another StringAttributeBean.
 Locale getLocale()
          Gets the Locale where the creator of this DTO is using the system
 String getName()
          Gets the name of this object
 String getSessionId()
          Gets a unique ID for this transaction which is used to identify this object across multiple tiers
 String getValue()
          Gets the name of this object
 int hashCode()
           
 void setLocale(Locale locale)
          Sets the Locale of this object
 void setName(String name)
          Sets the name of this object
 void setSessionId(String sessionId)
          Sets this beans sessionId
 void setValue(String value)
          Sets the value of this object
 String toString()
          Returns a description for this StringAttributeBean
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StringAttributeBean

public StringAttributeBean(String name,
                           String value)
Constructor which sets the name and the value of this object

Parameters:
name - The name of the value to be used by this object
value - The string which represents the value of this object

StringAttributeBean

public StringAttributeBean(String name,
                           String value,
                           Locale locale)
Parameters:
name - The name of the value to be used by this object
value - The string which represents the value of this object
locale - The Locale of this object

StringAttributeBean

public StringAttributeBean(String name,
                           String value,
                           Locale locale,
                           String sessionId)
Parameters:
name - The name of the value to be used by this object
value - The string which represents the value of this object
locale - The Locale of this object
sessionId - The sessionId to set for this object
Method Detail

setValue

public void setValue(String value)
Sets the value of this object

Parameters:
value - The string which represents the value of this object

setName

public void setName(String name)
Sets the name of this object

Parameters:
name - The name of the value to be used by this object

getName

public String getName()
Gets the name of this object

Returns:
the name

getValue

public String getValue()
Gets the name of this object

Returns:
the value

equals

public boolean equals(Object object)
Compares the current StringAttributeBean Object with another StringAttributeBean.

Overrides:
equals in class Object
Parameters:
object - The object that the current StringAttributeBean is to be compared with.
Returns:
True if the two StringAttributeBean objects are equal, otherwise false.

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Returns a description for this StringAttributeBean

Overrides:
toString in class Object

getSessionId

public String getSessionId()
Description copied from interface: DataTransferObject
Gets a unique ID for this transaction which is used to identify this object across multiple tiers

Specified by:
getSessionId in interface DataTransferObject
Returns:
A unique ID useful for identifying this object

setSessionId

public void setSessionId(String sessionId)
Sets this beans sessionId

Parameters:
sessionId - the sessionId to set

getLocale

public Locale getLocale()
Description copied from interface: DataTransferObject
Gets the Locale where the creator of this DTO is using the system

Specified by:
getLocale in interface DataTransferObject
Returns:
The Locale of the user of this DTO

setLocale

public void setLocale(Locale locale)
Sets the Locale of this object

Parameters:
locale - the locale to set