LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.view.web.struts
Class LyStrutsHeader

java.lang.Object
  extended by leon.view.graphic.LyGraphicalObject
      extended by leon.view.web.LyWebObject
          extended by leon.view.web.struts.LyStrutsHeader
All Implemented Interfaces:
LyGraphicalComponent, LyGraphicalHeader, LyViewComponent, LyFreeInterface, LyWebComponent

public class LyStrutsHeader
extends LyWebObject
implements LyGraphicalHeader

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

HEADER: Header Cell
This represents the header of a cell.

See Also:
LyHeader

Field Summary
static java.lang.String __VERSION
           
 
Fields inherited from class leon.view.web.LyWebObject
WEB_COMPONENT_ID, WEB_CONTROLLER_ID, WEB_SESSION_ID
 
Constructor Summary
LyStrutsHeader(LyHeader header)
          Class constructor of a Header object for the Struts target.
 
Method Summary
 java.lang.String checkHeaderWidth(java.lang.String label, java.lang.String fontString, boolean isHeader)
          Checks a label is displayable in the header according to header width.
 int getHeaderIndex()
          Gets the header index from the headers list.
 void initialize()
          Initialization method.
 void refresh()
          Performs a refresh of the table.
 void setBorderColor(java.lang.String borderColor)
          Updates attribute borderColor to the given value.
 void setBorderWidth(int borderWidth)
          Updates attribute borderWidth to the given value.
 void setColumnWidth(double columnWidth)
          Sets attribute columnWidth to the given value.
 void setFixed(boolean fixed)
          Updates attribute fixed to the given value.
 void setIncreasing(boolean increasing)
          Updates attribute increasing to the given value.
 void setSort(int sort)
          Updates attribute sort to the given value.
 void writeHtml(LyWebPageWriter pw)
          Write HTML description corresponding to this component.
 
Methods inherited from class leon.view.web.LyWebObject
addFileScript, decodeUrl, displayUpPage, encodeUrl, encodeUrlXhtml, expandUrl, free, getDisabledImageUrl, getFontSize, getFontString, getFontString, getFontString, getHexColor, getHexColor, getHtmlEntitiesString, getHtmlString, getImageSize, getImageSize, getImageUrl, getJavascriptString, getLastFrameName, getLyFont, getMessage, getRootUrl, getRootURL, getScrollHeightForSplitter, getUrl, getWebViewManager, replaceUrl, replaceUrl, setUpdating, updateRefreshInfo, writeJson
 
Methods inherited from class leon.view.graphic.LyGraphicalObject
expand, getBounds, getChildrenBounds, getController, getEnv, getEnvironment, getIdCode, getIntResource, 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

LyStrutsHeader

public LyStrutsHeader(LyHeader header)
Class constructor of a Header object for the Struts target.

Parameters:
header - the generic Header defined for every type of view targets
Method Detail

refresh

public void refresh()
Performs a refresh of the table.

Overrides:
refresh in class LyWebObject

initialize

public void initialize()
Initialization method.
Sets the buttons images with values from resources files. Sets the sort tooltip with an HTML compatible representation of the label defined in the resource LY_MENU_SORT_BY.


writeHtml

public void writeHtml(LyWebPageWriter pw)
Description copied from interface: LyWebComponent
Write HTML description corresponding to this component.

Specified by:
writeHtml in interface LyWebComponent
Parameters:
pw - the page writer

checkHeaderWidth

public java.lang.String checkHeaderWidth(java.lang.String label,
                                         java.lang.String fontString,
                                         boolean isHeader)
Checks a label is displayable in the header according to header width.

Parameters:
label - the label
fontString - the font property used to display label
isHeader - indicates if label is displayed in an header
Returns:
the label adjusted to header width if it is necessary

setIncreasing

public void setIncreasing(boolean increasing)
Description copied from interface: LyGraphicalHeader
Updates attribute increasing to the given value.

Specified by:
setIncreasing in interface LyGraphicalHeader
Parameters:
increasing - Boolean indicating if attribute increasing is set or unset.

setFixed

public void setFixed(boolean fixed)
Description copied from interface: LyGraphicalHeader
Updates attribute fixed to the given value.

Specified by:
setFixed in interface LyGraphicalHeader
Parameters:
fixed - Boolean indicating if attribute fixed is set or unset.

setSort

public void setSort(int sort)
Description copied from interface: LyGraphicalHeader
Updates attribute sort to the given value.

Specified by:
setSort in interface LyGraphicalHeader
Parameters:
sort - New value of sort.

setBorderColor

public void setBorderColor(java.lang.String borderColor)
Description copied from interface: LyGraphicalHeader
Updates attribute borderColor to the given value.

Specified by:
setBorderColor in interface LyGraphicalHeader
Parameters:
borderColor - New value of borderColor.

setBorderWidth

public void setBorderWidth(int borderWidth)
Description copied from interface: LyGraphicalHeader
Updates attribute borderWidth to the given value.

Specified by:
setBorderWidth in interface LyGraphicalHeader
Parameters:
borderWidth - New value of borderWidth.

getHeaderIndex

public int getHeaderIndex()
Gets the header index from the headers list.

Returns:
the header index

setColumnWidth

public void setColumnWidth(double columnWidth)
Sets attribute columnWidth to the given value.

Specified by:
setColumnWidth in interface LyGraphicalHeader
Parameters:
columnWidth - New value of columnWidth.

(c) January 2013 - W4 S.A.

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