LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.view.win.swing
Class LySwingGauge

java.lang.Object
  extended by leon.view.graphic.LyGraphicalObject
      extended by leon.view.win.swing.LySwingObject
          extended by leon.view.win.swing.LySwingGauge
All Implemented Interfaces:
LyGraphicalComponent, LyGraphicalFieldItem, LyGraphicalGauge, LyViewComponent, LyFreeInterface, LySetLabelInterface, LySwingComponent

public class LySwingGauge
extends LySwingObject
implements LySwingComponent, LyGraphicalGauge

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

A gauge is defined with minimum and maximum values as well as a current value.

See Also:
LyColor

Field Summary
static java.lang.String __VERSION
           
 
Constructor Summary
LySwingGauge(LyGauge gauge)
          Class constructor of a Gauge object for the Swing target.
 
Method Summary
 java.awt.Component createGauge(LyEnvironment environment)
          Creates the gauge swing component with the default properties.
 java.awt.Component getComponent()
          (non-Javadoc).
 void initialize()
          Initializes this progress bar.
 void setContent()
          Sets the initial values.
 void setInitialValues()
          Initializes this gauge: sets the minimum, maximum and current values, then sets the gauge label, if any.
 void setLabel(java.lang.String label)
          Sets the current component label.
 void setNValue(int nValue)
          Sets the current component value.
 
Methods inherited from class leon.view.win.swing.LySwingObject
getBounds, getChildrenBounds, getDefaultFrame
 
Methods inherited from class leon.view.graphic.LyGraphicalObject
expand, free, getController, getEnv, getEnvironment, getIdCode, getIntResource, getMessage, getMessage, getResource, getString, getString, getString, getViewComponent, getViewManager, isFreed, isFreeing, isImageAnimated, processDemand, processDemand, testResource, translate
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface leon.view.graphic.LyGraphicalComponent
free, getViewComponent
 

Field Detail

__VERSION

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

LySwingGauge

public LySwingGauge(LyGauge gauge)
Class constructor of a Gauge object for the Swing target.

Parameters:
gauge - a GAUGE component defined for every type of view targets. This gauge is initialized specificaly for the Swing view.
Method Detail

initialize

public void initialize()
Initializes this progress bar. Builds the graphic component that display this object.


setContent

public void setContent()
Sets the initial values.


createGauge

public java.awt.Component createGauge(LyEnvironment environment)
Creates the gauge swing component with the default properties.

Parameters:
environment - the current context. This is not used in this implementation.
Returns:
the new progress bar

setInitialValues

public void setInitialValues()
Initializes this gauge: sets the minimum, maximum and current values, then sets the gauge label, if any.


setNValue

public void setNValue(int nValue)
Sets the current component value.

Specified by:
setNValue in interface LyGraphicalGauge
Parameters:
nValue - New value of nValue.
See Also:
LyGraphicalGauge.setNValue(int)

setLabel

public void setLabel(java.lang.String label)
Sets the current component label.

Specified by:
setLabel in interface LyGraphicalGauge
Specified by:
setLabel in interface LySetLabelInterface
Parameters:
label - New value of label.
See Also:
LySetLabelInterface.setLabel(String)

getComponent

public java.awt.Component getComponent()
(non-Javadoc).

Specified by:
getComponent in interface LySwingComponent
Overrides:
getComponent in class LySwingObject
Returns:
this Swing view component
See Also:
LySwingComponent.getComponent()

(c) January 2013 - W4 S.A.

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