public class RichTextBusinessObject
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable
valueKey
is used in toString()
to represent the
object as a string. This object supports values of type
JGraphpadRichTextValue
.RichTextGraphModel
,
Serialized FormModifier and Type | Field and Description |
---|---|
protected java.util.Map |
properties
Holds the properties as (key, value) pairs.
|
static java.lang.String |
valueKey
Key to use for converting this object to a string.
|
Constructor and Description |
---|
RichTextBusinessObject()
Constructs a business object with an empty string as its value.
|
RichTextBusinessObject(java.lang.Object value)
Constructs a business object with the specified value.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
chopString(java.lang.String s,
int max)
A helper method that crops string to the specified length, adding 3 dots
if there were more characters.
|
java.lang.Object |
clone()
Returns a clone of the object.
|
java.util.Map |
getProperties()
Returns the properties.
|
java.lang.Object |
getProperty(java.lang.Object key)
Returns the property under the specified key.
|
java.lang.String |
getTooltip()
Hook for subclassers to create a custom tooltip for this user object.
|
java.lang.Object |
getValue()
Returns the value for
valueKey . |
boolean |
isComponent()
Returns true if the value is a component.
|
boolean |
isRichText()
Returns true if the value is a rich text value.
|
java.lang.Object |
putProperty(java.lang.Object key,
java.lang.Object value)
Sets the property under the specified key.
|
void |
setProperties(java.util.Map properties)
Sets the properties.
|
void |
setValue(java.lang.Object value)
Sets the value for
valueKey . |
java.lang.String |
toString()
Returns the string representation of the value or an empty string if no
value exists.
|
public static java.lang.String valueKey
protected java.util.Map properties
public RichTextBusinessObject()
public RichTextBusinessObject(java.lang.Object value)
value
- The value of the new object.public java.util.Map getProperties()
public void setProperties(java.util.Map properties)
properties
- The properties to set.public void setValue(java.lang.Object value)
valueKey
.value
- The value to set.public java.lang.Object getValue()
valueKey
.public boolean isRichText()
public boolean isComponent()
public java.lang.Object putProperty(java.lang.Object key, java.lang.Object value)
key
- They key of the property.value
- The value of the property.public java.lang.Object getProperty(java.lang.Object key)
key
- The key of the property.public java.lang.String getTooltip()
JGraphpadGraph#getToolTipForCell(Object)
.protected java.lang.String chopString(java.lang.String s, int max)
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.Object clone()
clone
in class java.lang.Object
Copyright (C) 2001-2009 JGraph Ltd. All rights reserved.