LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.view
Class LyIcon

java.lang.Object
  extended by leon.view.LyComponent
      extended by leon.view.LyFieldItem
          extended by leon.view.LyIcon
All Implemented Interfaces:
LyGetConstraintInterface, LyGetIdInterface, LyGetLabelInterface, LySetImageInterface, LyUpdateViewContentInterface

public class LyIcon
extends LyFieldItem
implements LyGetIdInterface, LyGetLabelInterface, LySetImageInterface, LyGetConstraintInterface

The LyIcon class is a generated Java implementation that corresponds to the element ICON of the descriptive grammar of the views (views.dtd). <ICON> : Icon An icon allows defining an image to which a text can be associated.

See Also:
See also tag ICON of grammar leon_views.dtd.

Nested Class Summary
static class LyIcon.Border
          Possible values for attribute 'border'.
 
Nested classes/interfaces inherited from class leon.view.LyComponent
LyComponent.EventType
 
Field Summary
static java.lang.String __VERSION
           
 
Fields inherited from class leon.view.LyComponent
_nbComponents, INIT_RESOURCE_ID, INTERNAL_ID_SEP, REWRITING_MODE, SEP_ID
 
Constructor Summary
LyIcon(java.lang.String label, java.lang.String image)
          Constructor with all required attributes.
 
Method Summary
 LyComponent cloneComponent()
          Method for cloning a component.
 java.lang.String getBean()
          Gets value of bean.
 LyIcon.Border getBorder()
          Gets value of border.
static LyIcon.Border getBorder(java.lang.String token)
          Utility method to get border value from a string.
 LyConstraint getConstraint()
          Get sub-component Constraint.
 int getHeight()
          Gets value of height.
 java.lang.String getId()
          Gets value of id.
 java.lang.String getImage()
          Gets value of image.
 java.lang.String getLabel()
          Gets value of label.
 LyIcon getTemplate()
          Gets value of template.
 int getWidth()
          Gets value of width.
 boolean isDefaultImage()
          Checks whether the image attribute is valuated to the default value.
 void setBean(java.lang.String bean)
          Initializes attribute bean to the given value.
 void setBorder(LyIcon.Border border)
          Initializes attribute border to the given value.
 void setConstraint(LyConstraint constraint)
          Sets sub-component constraint.
 void setHeight(int height)
          Initializes attribute height to the given value.
 void setId(java.lang.String id)
          Initializes attribute id to the given value.
 void setImage(java.lang.String image)
          Sets attribute image to the given value.
 void setLabel(java.lang.String label)
          Initializes attribute label to the given value.
 void setTemplate(LyIcon template)
          Initializes attribute template to the given value.
 void setWidth(int width)
          Initializes attribute width to the given value.
 void writeXml(java.io.PrintWriter pw, boolean debug)
          Method to rewrite XML corresponding to this component.
 
Methods inherited from class leon.view.LyFieldItem
addBeanData, buildBean, free, getBeanComponent, getBeanData, getBeanDatas, getChild, getChildCount, getErrorMessage, getFieldValue, getValue, setBeanComponent, setBeanDatas, setFieldValue, updateViewContent, validateInput
 
Methods inherited from class leon.view.LyComponent
addComponent, addData, addEventFunction, clearChildrenBounds, freeze, getBounds, getChildFromCache, getChildrenBounds, getComponent, getComponent, getComponent, getComponent, getComponent, getComponentAt, getComponentAt, getComponentByInternalId, getComponentByLabel, getComponents, getComponentWithModel, getData, getDatas, getEnvironment, getEventFunctions, getIdCode, getInternalId, getInternalView, getInternalView, getLock, getModel, getParent, getParentArea, getParentForm, getParentFormFieldId, getParentSplitter, getParentSplitter, getParentTab, getParentTab, getParentTabs, getParentTabs, getParentView, getRootController, getSetVisibleParent, getTag, getViewManager, isFreed, isFreeing, registerChildrenBounds, removeComponent, reset, resetChildrenCache, resetEventFunctions, setDatas, setInternalView, setVisible, useEventDefaultFunction, writeXml
 
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
Constructor Detail

LyIcon

public LyIcon(java.lang.String label,
              java.lang.String image)
Constructor with all required attributes.

Parameters:
label - Text to display with the image
image - Image
Method Detail

getBorder

public static final LyIcon.Border getBorder(java.lang.String token)
Utility method to get border value from a string.

Parameters:
token - Token string
Returns:
Border value corresponding to this token

cloneComponent

public LyComponent cloneComponent()
Method for cloning a component.

Specified by:
cloneComponent in class LyComponent

getId

public java.lang.String getId()
Gets value of id.

Specified by:
getId in interface LyGetIdInterface
Overrides:
getId in class LyComponent
Returns:
value of id.

getTemplate

public LyIcon getTemplate()
Gets value of template.

Returns:
value of template.

getLabel

public java.lang.String getLabel()
Gets value of label.

Specified by:
getLabel in interface LyGetLabelInterface
Returns:
value of label.

getImage

public java.lang.String getImage()
Gets value of image.

Returns:
value of image.

isDefaultImage

public boolean isDefaultImage()
Checks whether the image attribute is valuated to the default value.

Returns:
True if default, false otherwise.

getWidth

public int getWidth()
Gets value of width.

Returns:
value of width.

getHeight

public int getHeight()
Gets value of height.

Returns:
value of height.

getBorder

public LyIcon.Border getBorder()
Gets value of border.

Returns:
value of border.

getBean

public java.lang.String getBean()
Gets value of bean.

Overrides:
getBean in class LyFieldItem
Returns:
value of bean.

getConstraint

public LyConstraint getConstraint()
Get sub-component Constraint.

Specified by:
getConstraint in interface LyGetConstraintInterface
Returns:
sub-component Constraint.

setId

public void setId(java.lang.String id)
Initializes attribute id to the given value.

Parameters:
id - New value of id.

setTemplate

public void setTemplate(LyIcon template)
Initializes attribute template to the given value.

Parameters:
template - New value of template.

setLabel

public void setLabel(java.lang.String label)
Initializes attribute label to the given value.

Overrides:
setLabel in class LyFieldItem
Parameters:
label - New value of label.
Throws:
java.lang.IllegalArgumentException - if label is null.

setImage

public void setImage(java.lang.String image)
Sets attribute image to the given value.

Specified by:
setImage in interface LySetImageInterface
Parameters:
image - New value of image.
Throws:
java.lang.IllegalArgumentException - if image is null.

setWidth

public void setWidth(int width)
Initializes attribute width to the given value.

Parameters:
width - New value of width.

setHeight

public void setHeight(int height)
Initializes attribute height to the given value.

Parameters:
height - New value of height.

setBorder

public void setBorder(LyIcon.Border border)
Initializes attribute border to the given value.

Parameters:
border - New value of border.
Throws:
java.lang.IllegalArgumentException - if border parameter is null.

setBean

public void setBean(java.lang.String bean)
Initializes attribute bean to the given value.

Overrides:
setBean in class LyFieldItem
Parameters:
bean - New value of bean.

setConstraint

public void setConstraint(LyConstraint constraint)
Sets sub-component constraint.

Parameters:
constraint - New value of constraint

writeXml

public void writeXml(java.io.PrintWriter pw,
                     boolean debug)
Method to rewrite XML corresponding to this component.

Specified by:
writeXml in class LyComponent
Parameters:
pw - the printWriter on which the XML is written.
debug - true if debug mode (full dump).

(c) January 2013 - W4 S.A.

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