com.rednels.ofcgwt.client.model.axis
Class Label

java.lang.Object
  extended by com.rednels.ofcgwt.client.model.axis.Label
All Implemented Interfaces:
JSONizable
Direct Known Subclasses:
XAxis.Labels

public class Label
extends java.lang.Object
implements JSONizable

Base class for an OFC label


Constructor Summary
Label()
          Creates a new label.
Label(java.lang.String text)
          Creates a new label.
Label(java.lang.String text, java.lang.Integer angle)
          Creates a new label.
 
Method Summary
 com.google.gwt.json.client.JSONValue buildJSON()
          Build (and return) a JSONObject that contains all the items of this object.
 java.lang.String getColour()
          Gets the colour.
 java.lang.Integer getRotationAngle()
          Gets the rotation.
 java.lang.Integer getSize()
          Gets the size.
 java.lang.String getText()
          Gets the text.
 java.lang.Boolean getVisible()
          Gets the visible.
 void setColour(java.lang.String colour)
          Sets the colour in HTML hex format (#ffffff)
 void setRotationAngle(java.lang.Integer angle)
          Sets the rotation in degrees (ie 45 = diagonal, 90 = vertical).
 void setSize(java.lang.Integer size)
          Sets the size.
 void setText(java.lang.String text)
          Sets the text.
 void setVisible(java.lang.Boolean visible)
          Sets the visible.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Label

public Label()
Creates a new label.


Label

public Label(java.lang.String text)
Creates a new label.

Parameters:
text - the text

Label

public Label(java.lang.String text,
             java.lang.Integer angle)
Creates a new label.

Parameters:
text - the text
angle - the rotation angle
Method Detail

buildJSON

public com.google.gwt.json.client.JSONValue buildJSON()
Description copied from interface: JSONizable
Build (and return) a JSONObject that contains all the items of this object. If required, will call.buildJSON() on any contained JSONizable objects, thus producing an entire JSON tree.

Specified by:
buildJSON in interface JSONizable
Returns:
the JSONObject

getColour

public java.lang.String getColour()
Gets the colour.

Returns:
the colour

getRotationAngle

public java.lang.Integer getRotationAngle()
Gets the rotation.

Returns:
the rotation

getSize

public java.lang.Integer getSize()
Gets the size.

Returns:
the size

getText

public java.lang.String getText()
Gets the text.

Returns:
the text

getVisible

public java.lang.Boolean getVisible()
Gets the visible.

Returns:
the visible

setColour

public void setColour(java.lang.String colour)
Sets the colour in HTML hex format (#ffffff)

Parameters:
colour - the colour

setRotationAngle

public void setRotationAngle(java.lang.Integer angle)
Sets the rotation in degrees (ie 45 = diagonal, 90 = vertical).

Parameters:
angle - the rotate angle

setSize

public void setSize(java.lang.Integer size)
Sets the size.

Parameters:
size - the size

setText

public void setText(java.lang.String text)
Sets the text.

Parameters:
text - the text

setVisible

public void setVisible(java.lang.Boolean visible)
Sets the visible.

Parameters:
visible - the visible