jet.report.xls
Class LegendInfo

java.lang.Object
  extended by jet.report.xls.LegendInfo

public class LegendInfo
extends java.lang.Object

Contains the information of chart legend in the file.


Field Summary
static short AUTOPOSITION
          The legend is auto positioned.
static byte BOTTOM
          Displays the legend to the bottom of the chart's plot area.
static byte CORNER
          Displays the legend to the corner of the chart's plot area.
static byte LEFT
          Displays the legend to the left of the chart's plot area.
static byte NODOCK
          Represents that the legend is not docked.
static byte RIGHT
          Displays the legend to the right of the chart's plot area.
static byte TOP
          Displays the legend to the top of the chart's plot area.
 
Constructor Summary
LegendInfo()
          Constructs a LegendInfo class.
LegendInfo(int x, int y, int width, int height, byte type, short grbit)
          Constructs a LegendInfo class and sets its fields appropriately.
 
Method Summary
 FontInfo getFontInfo()
          Gets the information of legend text font.
 int getHeight()
          Gets the height of the chart legend.
 ChartAreaInfo getLegendArea()
          Gets the information of the legend area.
 byte getType()
          Gets the type of the location of the legend relative to the plot rectangle of the chart.
 int getWidth()
          Gets the width of the chart legend.
 int getX()
          Gets the x position of the chart legend.
 int getY()
          Gets the y position of the chart legend.
 boolean isAutoPosition()
          Gets whether to use automatic position.
 boolean isAutoPosX()
          Gets whether to use automatic X position.
 boolean isAutoPosY()
          Gets whether to use automatic Y position.
 boolean isAutoSeries()
          Gets whether to use automatic series.
 boolean isVert()
          Gets whether to use vertical legend (a single column of entries).
 void setAutoPosition(boolean b)
          Sets whether to use automatic position.
 void setAutoPosX(boolean b)
          Sets whether to use automatic X position.
 void setAutoPosY(boolean b)
          Sets whether to use automatic Y position.
 void setAutoSeries(boolean b)
          Sets whether to use automatic series.
 void setFontInfo(FontInfo fontInfo)
          Sets the information of legend text font.
 void setHeight(int height)
          Sets the height of the chart legend.
 void setLegendArea(ChartAreaInfo legendAreaInfo)
          Sets the information of the legend area.
 void setType(byte type)
          Sets the type of the location of the legend relative to the plot rectangle of the chart.
 void setVert(boolean b)
          Sets whether to use vertical legend.
 void setWidth(int width)
          Sets the width of the chart legend.
 void setX(int x)
          Sets the x position of the chart legend.
 void setY(int y)
          Sets the y position of the chart legend.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BOTTOM

public static final byte BOTTOM
Displays the legend to the bottom of the chart's plot area.

See Also:
Constant Field Values

CORNER

public static final byte CORNER
Displays the legend to the corner of the chart's plot area.

See Also:
Constant Field Values

TOP

public static final byte TOP
Displays the legend to the top of the chart's plot area.

See Also:
Constant Field Values

RIGHT

public static final byte RIGHT
Displays the legend to the right of the chart's plot area.

See Also:
Constant Field Values

LEFT

public static final byte LEFT
Displays the legend to the left of the chart's plot area.

See Also:
Constant Field Values

NODOCK

public static final byte NODOCK
Represents that the legend is not docked.

See Also:
Constant Field Values

AUTOPOSITION

public static final short AUTOPOSITION
The legend is auto positioned.

See Also:
Constant Field Values
Constructor Detail

LegendInfo

public LegendInfo()
Constructs a LegendInfo class.


LegendInfo

public LegendInfo(int x,
                  int y,
                  int width,
                  int height,
                  byte type,
                  short grbit)
Constructs a LegendInfo class and sets its fields appropriately.

Parameters:
x - x-position of the upper-left corner
y - y-position of the upper-left corner
width - width of the Legend
height - height of the Legend
type - defines the location of the legend relative to the plot rectangle of the chart
grbit - option flags AUTOPOSITION
Method Detail

setX

public void setX(int x)
Sets the x position of the chart legend.

Parameters:
x - the x position of the chart legend

getX

public int getX()
Gets the x position of the chart legend.

Returns:
the x position of the chart legend

setY

public void setY(int y)
Sets the y position of the chart legend.

Parameters:
y - the y position of the chart legend

getY

public int getY()
Gets the y position of the chart legend.

Returns:
the y position of the chart legend

setWidth

public void setWidth(int width)
Sets the width of the chart legend.

Parameters:
width - the width of the chart legend

getWidth

public int getWidth()
Gets the width of the chart legend.

Returns:
the width of the chart legend

setHeight

public void setHeight(int height)
Sets the height of the chart legend.

Parameters:
height - the height of the chart legend

getHeight

public int getHeight()
Gets the height of the chart legend.

Returns:
the height of the chart legend

setType

public void setType(byte type)
Sets the type of the location of the legend relative to the plot rectangle of the chart.

Parameters:
type - the type of the location of the legend relative to the plot rectangle of the chart
See Also:
BOTTOM, CORNER, TOP, RIGHT, LEFT, NODOCK

getType

public byte getType()
Gets the type of the location of the legend relative to the plot rectangle of the chart.


setLegendArea

public void setLegendArea(ChartAreaInfo legendAreaInfo)
Sets the information of the legend area.

Parameters:
legendAreaInfo - the information of the legend area

getLegendArea

public ChartAreaInfo getLegendArea()
Gets the information of the legend area.

Returns:
the information of the legend area

isAutoPosition

public boolean isAutoPosition()
Gets whether to use automatic position.

Returns:
whether to use automatic position or not

setAutoPosition

public void setAutoPosition(boolean b)
Sets whether to use automatic position.

Parameters:
b - - whether to use automatic position or not

isAutoSeries

public boolean isAutoSeries()
Gets whether to use automatic series.

Returns:
whether to use automatic series or not

setAutoSeries

public void setAutoSeries(boolean b)
Sets whether to use automatic series.

Parameters:
b - - whether to use automatic series or not

isAutoPosX

public boolean isAutoPosX()
Gets whether to use automatic X position.

Returns:
whether to use automatic X position or not

setAutoPosX

public void setAutoPosX(boolean b)
Sets whether to use automatic X position.

Parameters:
b - - whether to use automatic X position or not

isAutoPosY

public boolean isAutoPosY()
Gets whether to use automatic Y position.

Returns:
whether to use automatic Y position or not

setAutoPosY

public void setAutoPosY(boolean b)
Sets whether to use automatic Y position.

Parameters:
b - - whether to use automatic Y position or not

isVert

public boolean isVert()
Gets whether to use vertical legend (a single column of entries).

Returns:
whether to use vertical legend or not

setVert

public void setVert(boolean b)
Sets whether to use vertical legend.

Parameters:
b - - whether to use vertical legend or not

setFontInfo

public void setFontInfo(FontInfo fontInfo)
Sets the information of legend text font.

Parameters:
fontInfo - the information of legend text font

getFontInfo

public FontInfo getFontInfo()
Gets the information of legend text font.

Returns:
the information of legend text font