LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.view
Class LyChartConverter

java.lang.Object
  extended by leon.view.LyChartConverter
Direct Known Subclasses:
LyCommonFreeChartConverter

public abstract class LyChartConverter
extends java.lang.Object

This class implements the Chart object (as described in the dtd) for the viewer.

See Also:
LyChart

Field Summary
static java.lang.String __VERSION
           
static int DEFAULT_HEIGHT
          Height of the window.
static int DEFAULT_WIDTH
          Width of the window.
 
Constructor Summary
LyChartConverter()
          Constructor.
LyChartConverter(LyChart chart)
          Constructor.
 
Method Summary
 java.lang.String[] buildXLabels(java.util.Vector<java.lang.String> xSerie, LyChartBase.XVal xVal, LyChartBase.Type xType, java.lang.String xDateType)
          Build the labels corresponding to X.
 java.lang.String[] buildXLabels(java.util.Vector<java.lang.String> xSerie, LyChartBase.XVal xVal, LyChartBase.Type xType, java.lang.String xDateType, boolean addBlankForLabel)
          Build the labels corresponding to X.
 boolean generateSensitiveAreas()
          Returns the generateSensitiveAreas parameter.
 void generateSensitiveAreas(boolean generate)
          Sets the generateSensitiveAreas parameter.
abstract  java.lang.String getMultiLineBegin()
          Retrieve the beginning of the label when it has more than one line.
abstract  java.lang.String getMultiLineEnd()
          Retrieve the end of the label when it has more than one line.
abstract  java.lang.String getMultiLineSep()
          Retrieve the line separator of the label when it has more than one line.
 void initialize()
          Initialization method.
abstract  void reset()
          Reset the display from the underlying XML data Main method to construct the chart.
abstract  void saveImg(java.lang.String tmpDir, java.lang.String imageFile, java.lang.StringBuffer buffer, boolean deleteOnExit)
          Save the image of the chart.
 void setChart(LyChart chart)
          Affect a chart to this view.
 void setContent()
          Sets the content of this view.
 void setIntervals()
          If needed : replace all x values by the beginning of x intervals, replace all y values by the middle of y intervals.
 void setLegendRightPosition(boolean rightPosition)
          Sets the legendRightPosition parameter.
 void setSpecificLegendValue(java.util.Hashtable<java.lang.String,java.lang.String> values)
          Set the specific legend values.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

__VERSION

public static final java.lang.String __VERSION
See Also:
Constant Field Values

DEFAULT_WIDTH

public static int DEFAULT_WIDTH
Width of the window.


DEFAULT_HEIGHT

public static int DEFAULT_HEIGHT
Height of the window.

Constructor Detail

LyChartConverter

public LyChartConverter()
Constructor.


LyChartConverter

public LyChartConverter(LyChart chart)
Constructor.

Parameters:
chart - the chart created by LyChartController
See Also:
LyChartController
Method Detail

initialize

public void initialize()
Initialization method.


setChart

public void setChart(LyChart chart)
Affect a chart to this view.

Parameters:
chart - the chart created by LyChartController
See Also:
LyChartController

setContent

public void setContent()
Sets the content of this view.


reset

public abstract void reset()
Reset the display from the underlying XML data Main method to construct the chart.


setSpecificLegendValue

public void setSpecificLegendValue(java.util.Hashtable<java.lang.String,java.lang.String> values)
Set the specific legend values.

Parameters:
values -

setLegendRightPosition

public void setLegendRightPosition(boolean rightPosition)
Sets the legendRightPosition parameter.

Parameters:
rightPosition - the new legendRightPosition value

generateSensitiveAreas

public void generateSensitiveAreas(boolean generate)
Sets the generateSensitiveAreas parameter.

Parameters:
generate - the new generateSensitiveAreas value

generateSensitiveAreas

public boolean generateSensitiveAreas()
Returns the generateSensitiveAreas parameter.


buildXLabels

public java.lang.String[] buildXLabels(java.util.Vector<java.lang.String> xSerie,
                                       LyChartBase.XVal xVal,
                                       LyChartBase.Type xType,
                                       java.lang.String xDateType)
Build the labels corresponding to X.

Parameters:
xSerie - Vector of the real values of the series.
xVal - type of study for X : real values or intervals
xType - type X values : text, numeric or date
xDateType - type X dates (if needed): date, time, etc.
Returns:
the X graduation labels

buildXLabels

public java.lang.String[] buildXLabels(java.util.Vector<java.lang.String> xSerie,
                                       LyChartBase.XVal xVal,
                                       LyChartBase.Type xType,
                                       java.lang.String xDateType,
                                       boolean addBlankForLabel)
Build the labels corresponding to X.

Parameters:
xSerie - Vector of the real values of the series.
xVal - type of study for X : real values or intervals
xType - type X values : text, numeric or date
xDateType - type X dates (if needed): date, time, etc.
addBlankForLabel - indicates if blank must be added before ending line.
Returns:
the X graduation labels

setIntervals

public void setIntervals()
If needed : replace all x values by the beginning of x intervals, replace all y values by the middle of y intervals.


saveImg

public abstract void saveImg(java.lang.String tmpDir,
                             java.lang.String imageFile,
                             java.lang.StringBuffer buffer,
                             boolean deleteOnExit)
Save the image of the chart.

Parameters:
tmpDir - temporary directory
imageFile - the PNG File
buffer - the buffer where imagemap must be generated
deleteOnExit - indicates whether the file must be deleted on exiting the application

getMultiLineBegin

public abstract java.lang.String getMultiLineBegin()
Retrieve the beginning of the label when it has more than one line.

Returns:
for example : null for String, and ... for HTML

getMultiLineEnd

public abstract java.lang.String getMultiLineEnd()
Retrieve the end of the label when it has more than one line.

Returns:
for example : null for String, and ... for HTML

getMultiLineSep

public abstract java.lang.String getMultiLineSep()
Retrieve the line separator of the label when it has more than one line.

Returns:
for example : \n for String, and /p>


(c) January 2013 - W4 S.A.

Website: W4 S.A., contact us: support@w4global.com