Package jahuwaldt.js.datareader
Class TextParam
- java.lang.Object
-
- jahuwaldt.js.datareader.DataParam
-
- jahuwaldt.js.datareader.TextParam
-
- All Implemented Interfaces:
DataElement
,java.lang.Comparable<DataElement>
public final class TextParam extends DataParam
A class that represents a text/note parameter.Modified by: Joseph A. Huwaldt
- Version:
- October 15, 2015
- Author:
- Joseph A. Huwaldt, Date: March 5, 2003
-
-
Field Summary
-
Fields inherited from interface jahuwaldt.js.datareader.DataElement
RESOURCES
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
Compares the specified object with this parameter for strict equality same text, same name, and same user data.javolution.text.Text
getText()
Return the text of this text parameter.int
hashCode()
Returns the hash code for thisUnitParameter
.static TextParam
newInstance(java.lang.CharSequence name)
Returns a new, preallocated or recycledTextParam
instance (on the stack when executing in aStackContext
) with the specified name and containing no text.static void
recycle(TextParam instance)
Recycles a parameter instance immediately (on the stack when executing in a StackContext).void
setText(java.lang.CharSequence text)
Change the text contained in this parameter.java.lang.String
toString()
Create a string representation of this parameter which consists of the parameter's name and text.javolution.text.Text
toText()
Create a Text representation of this parameter which consists of the parameter's name and text.static TextParam
valueOf(java.lang.CharSequence name, java.lang.CharSequence text)
Returns a text parameter with the specified name and text (which may be null).-
Methods inherited from class jahuwaldt.js.datareader.DataParam
compareTo, getName, getUserObject, setName, setUserObject
-
-
-
-
Method Detail
-
newInstance
public static TextParam newInstance(java.lang.CharSequence name)
Returns a new, preallocated or recycledTextParam
instance (on the stack when executing in aStackContext
) with the specified name and containing no text.- Parameters:
name
- The name to be assigned to this parameter (may not benull
).
-
recycle
public static void recycle(TextParam instance)
Recycles a parameter instance immediately (on the stack when executing in a StackContext).
-
valueOf
public static TextParam valueOf(java.lang.CharSequence name, java.lang.CharSequence text)
Returns a text parameter with the specified name and text (which may be null).
-
getText
public javolution.text.Text getText()
Return the text of this text parameter. Could return an empty string if there is no text.
-
setText
public void setText(java.lang.CharSequence text)
Change the text contained in this parameter. The text can not be null.
-
equals
public boolean equals(java.lang.Object obj)
Compares the specified object with this parameter for strict equality same text, same name, and same user data.
-
hashCode
public int hashCode()
Returns the hash code for thisUnitParameter
.
-
toText
public javolution.text.Text toText()
Create a Text representation of this parameter which consists of the parameter's name and text.
-
-