|
Style Intelligence v12.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectinetsoft.graph.Graphable
inetsoft.graph.element.GraphElement
public abstract class GraphElement
A graph element is an object that can be added to a graph to create a visual perception of data. For example, a PointElement can be added to a graph to draw points for data tuples.
A graph element can plot a graph for each variable. An element shares a a set of dimensions, and plot a graph for each var(iable).
| Field Summary | |
|---|---|
static int |
DODGE_SYMMETRIC
Dodge and center objects. |
static String |
HINT_ALPHA
Transparency value for color, a double value from 0 to 1. |
static String |
HINT_CLIP
Hint to clip the plot area for drawing this element, a string of true or false. |
static String |
HINT_EXPLODED
Hint to explode a slice of a pie, string of true or false. |
static String |
HINT_MAX_COUNT
Hint for the geometry max count limit, an integer value. |
static String |
HINT_MAX_HEIGHT
The maximum plot (single sub-graph) height, a number. |
static String |
HINT_MAX_WIDTH
The maximum plot (single sub-graph) width, a number. |
static String |
HINT_SHINE
Hint to add a shining effect to paint, string of true or false. |
static int |
MOVE_CENTER
Center the objects at tick position. |
static int |
MOVE_DODGE
Move objects side ways to avoid overlapping. |
static int |
MOVE_JITTER
Randomly shift points to reduce overlapping. |
static int |
MOVE_NONE
No collision resolution. |
static int |
MOVE_STACK
Stack objects. |
static int |
STACK_SYMMETRIC
Stack, dodge, and center objects. |
| Constructor Summary | |
|---|---|
protected |
GraphElement()
Create an empty graph element. |
protected |
GraphElement(String field)
Create a graph element for a single column (1d). |
protected |
GraphElement(String field1,
String field2)
Create a graph element for two columns (2d). |
protected |
GraphElement(String field1,
String field2,
String field3)
Create a graph element for three columns (3d). |
| Method Summary | |
|---|---|
void |
addDim(String col)
Add a dimension to be plotted using this element. |
void |
addVar(String col)
Add a variable to be plotted using this element. |
void |
clearDims()
Remove all dimensions. |
void |
clearVars()
Remove all variables. |
Object |
clone()
Clone this object. |
protected VisualModel |
createVisualModel(DataSet data)
Create a visual model for the graph element. |
boolean |
equalsContent(Object obj)
Check if equals another objects in structure. |
int |
getCollisionModifier()
Get the collision handling option. |
ColorFrame |
getColorFrame()
Get the color frame for getting the color aesthetic for each element. |
Comparator |
getComparator()
Get the comparator. |
String |
getDim(int idx)
Get the dimension at the specified index. |
int |
getDimCount()
Get the number of dimensions specified for this element. |
String[] |
getDims()
Get all the dimensions. |
int |
getEndRow()
Get the ending row of the dataset to use for this element. |
int |
getLabelPlacement()
Get the text placement. |
LineFrame |
getLineFrame()
Get the line frame for getting the line aesthetic for each element. |
protected int |
getRootColIndex(DataSet data,
String column)
Get the col index on the root dataset. |
protected int |
getRootRowIndex(DataSet data,
int row)
Get the row index on the root dataset. |
protected int[] |
getRootRowIndexes(DataSet data,
int[] rows)
Get the row indexes on the root dataset. |
ShapeFrame |
getShapeFrame()
Get the shape frame for getting the shape aesthetic for each element. |
SizeFrame |
getSizeFrame()
Get the size frame for getting the size aesthetic for each element. |
int |
getStartRow()
Get the starting row of the dataset to use for this element. |
TextFrame |
getTextFrame()
Get the text frame for getting the label aesthetic for each element. |
TextSpec |
getTextSpec()
Get the text label attributes. |
TextureFrame |
getTextureFrame()
Get the texture frame for getting the texture aesthetic for each element. |
String |
getVar(int idx)
Get the variable at the specified index. |
int |
getVarCount()
Get the number of variables specified for this element. |
String[] |
getVars()
Get all the variables. |
DataSet |
getVisualDataSet()
Get the data set for the visual frame if it needs to be different. |
VisualFrame[] |
getVisualFrames()
Get all the legend frames. |
boolean |
isInPlot()
Check if the element should be kept inside the plot area. |
void |
removeDim(int idx)
Remove the dimension at the specified index. |
void |
removeVar(int idx)
Remove the variable at the specified index. |
void |
setCollisionModifier(int option)
Set the option to handle collisions. |
void |
setColorFrame(ColorFrame colors)
Set the color frame for getting the color aesthetic for each element. |
void |
setComparator(Comparator comp)
Set a comparator to control the drawing order of the visual objects generated for this element. |
void |
setEndRow(int end)
Set the ending row of the dataset to use for this element. |
void |
setInPlot(boolean inside)
Set whether this element should be kept inside the plot area. |
void |
setLabelPlacement(int pos)
Set the text placement. |
void |
setLineFrame(LineFrame lines)
Set the line frame for getting the line aesthetic for each element. |
void |
setShapeFrame(ShapeFrame shapes)
Set the shape frame for getting the shape aesthetic for each element. |
void |
setSizeFrame(SizeFrame sizes)
Set the size frame for getting the size aesthetic for each element. |
void |
setStartRow(int start)
Set the starting row of the dataset to use for this element. |
void |
setTextFrame(TextFrame labels)
Set the text frame for getting the label aesthetic for each element. |
void |
setTextSpec(TextSpec textSpec)
Set the text label attributes. |
void |
setTextureFrame(TextureFrame textures)
Set the texture frame for getting the texture aesthetic for each element. |
void |
setVisualDataSet(DataSet data)
Set the data set for the visual frame if it needs to be different. |
SortedDataSet |
sortData(DataSet data,
GGraph graph)
Sort dataset to prepare for generating visual objects. |
boolean |
supportsFrame(VisualFrame frame)
Check if the aesthetic frame is supported. |
String |
toString()
Get the string representation. |
| Methods inherited from class inetsoft.graph.Graphable |
|---|
getHint, getHints, setHint, setHints |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int MOVE_NONE
public static final int MOVE_CENTER
public static final int MOVE_DODGE
public static final int MOVE_STACK
public static final int MOVE_JITTER
public static final int DODGE_SYMMETRIC
public static final int STACK_SYMMETRIC
public static final String HINT_EXPLODED
public static final String HINT_SHINE
public static final String HINT_ALPHA
public static final String HINT_MAX_COUNT
public static final String HINT_CLIP
public static final String HINT_MAX_WIDTH
public static final String HINT_MAX_HEIGHT
| Constructor Detail |
|---|
protected GraphElement()
protected GraphElement(String field)
protected GraphElement(String field1,
String field2)
protected GraphElement(String field1,
String field2,
String field3)
| Method Detail |
|---|
protected VisualModel createVisualModel(DataSet data)
public void addDim(String col)
col - the dimension identifier.public String getDim(int idx)
idx - the dim index.public int getDimCount()
public void removeDim(int idx)
idx - the dim index.public void clearDims()
public String[] getDims()
public void addVar(String col)
col - the variable identifier.public String getVar(int idx)
idx - the var index.public int getVarCount()
public void removeVar(int idx)
idx - the var index.public void clearVars()
public String[] getVars()
public void setCollisionModifier(int option)
option - an option defined in this class, e.g. DODGE_SYMMETRIC.public int getCollisionModifier()
public void setInPlot(boolean inside)
setInPlot in class Graphablepublic boolean isInPlot()
isInPlot in class Graphablepublic void setColorFrame(ColorFrame colors)
public ColorFrame getColorFrame()
public void setSizeFrame(SizeFrame sizes)
public SizeFrame getSizeFrame()
public void setShapeFrame(ShapeFrame shapes)
public ShapeFrame getShapeFrame()
public void setTextureFrame(TextureFrame textures)
public TextureFrame getTextureFrame()
public void setTextFrame(TextFrame labels)
public TextFrame getTextFrame()
public void setLineFrame(LineFrame lines)
public LineFrame getLineFrame()
public boolean supportsFrame(VisualFrame frame)
public TextSpec getTextSpec()
public void setTextSpec(TextSpec textSpec)
public int getLabelPlacement()
public void setLabelPlacement(int pos)
pos - one of GraphConstants.TOP, LEFT, BOTTOM, RIGHT, CENTER, AUTO.public void setComparator(Comparator comp)
public Comparator getComparator()
protected int getRootColIndex(DataSet data,
String column)
data - the chartLens to plot using this element.column - the specified column name.
protected int getRootRowIndex(DataSet data,
int row)
data - the chartLens to plot using this element.row - the row index for the dataset.
protected int[] getRootRowIndexes(DataSet data,
int[] rows)
data - the chartLens to plot using this element.rows - the row indexes for the dataset.public VisualFrame[] getVisualFrames()
public SortedDataSet sortData(DataSet data,
GGraph graph)
public void setStartRow(int start)
public int getStartRow()
public void setEndRow(int end)
end - the ending row (non-inclusive). Use -1 to use all rows.public int getEndRow()
public void setVisualDataSet(DataSet data)
public DataSet getVisualDataSet()
public String toString()
toString in class Graphablepublic boolean equalsContent(Object obj)
public Object clone()
clone in class Object
|
Copyright © 1996-2014 InetSoft Technology Corp. All Rights Reserved. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||