com.cc.framework.ui.painter.def.frame
Class TableFrame

java.lang.Object
  extended bycom.cc.framework.ui.painter.def.frame.TableFrame
All Implemented Interfaces:
Frame, java.io.Serializable

public class TableFrame
extends java.lang.Object
implements Frame, java.io.Serializable

A Frame based on a HTML table element

Version:
$Revision$
Author:
Harald Schulz
See Also:
Serialized Form

Field Summary
private  CompositeElement body
          The body element of the Frame.
private  TableCE container
          The table element for this frame
private  CompositeElement sections
          A frame can have multiple sections.
private static long serialVersionUID
          Serial Version UID
 
Constructor Summary
TableFrame()
          Constructor
 
Method Summary
 Frame addBodyElement(org.apache.ecs.Element element)
          Adds an element to the frames body region.
 TableFrame addElement(org.apache.ecs.Element element)
          Adds an element to the table
 Frame addSection(org.apache.ecs.Element element)
          Adds a new section to the frame.
 org.apache.ecs.ConcreteElement createElement()
          Creates a ECS Element from this Frame
protected  TableCE getContainer()
           
 Frame setBodyContainer(CompositeElement body)
          Sets the frames body container.
 TableFrame setBorder(int border)
          Sets the BORDER="" attribute.
 TableFrame setCellPadding(int cellpadding)
          Sets the CELLPADING="" attribute.
 TableFrame setCellSpacing(int cellspacing)
          Sets the CELLSPACING="" attribute.
 Frame setClass(java.lang.String styleClass)
          Set the CLASS attribute.
 Frame setHeight(java.lang.String height)
          Set the HEIGHT attribute.
 Frame setID(java.lang.String id)
          Set the ID attribute.
 Frame setSectionContainer(CompositeElement container)
          Sets the frames section container.
 Frame setStyle(java.lang.String style)
          Set the STYLE attribute.
 Frame setSummary(java.lang.String summary)
          Set the SUMMARY attribute.
 Frame setWidth(java.lang.String width)
          Set the WIDTH attribute.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Serial Version UID

See Also:
Constant Field Values

container

private TableCE container
The table element for this frame


sections

private CompositeElement sections
A frame can have multiple sections. A frame has at least one section and a section can have its own title.


body

private CompositeElement body
The body element of the Frame. The body element belongs to the current section.

Constructor Detail

TableFrame

public TableFrame()
Constructor

Method Detail

setSectionContainer

public Frame setSectionContainer(CompositeElement container)
Description copied from interface: Frame
Sets the frames section container. That is the element where all sections will be added

Specified by:
setSectionContainer in interface Frame
Parameters:
container - Section container
Returns:
Frame
See Also:
Frame.setSectionContainer(com.cc.framework.ui.painter.CompositeElement)

setBodyContainer

public Frame setBodyContainer(CompositeElement body)
Description copied from interface: Frame
Sets the frames body container. Thats where all body content will be added

Specified by:
setBodyContainer in interface Frame
Parameters:
body - sets the frames body element
Returns:
Frame
See Also:
Frame.setBodyContainer(com.cc.framework.ui.painter.CompositeElement)

addSection

public Frame addSection(org.apache.ecs.Element element)
Description copied from interface: Frame
Adds a new section to the frame.

Specified by:
addSection in interface Frame
Parameters:
element - The section title element, or null if this section has no title
Returns:
The Frame
See Also:
Frame.addSection(org.apache.ecs.Element)

addBodyElement

public Frame addBodyElement(org.apache.ecs.Element element)
Description copied from interface: Frame
Adds an element to the frames body region. It is up to the Frame how multiple elements are arranged in the frames body

Specified by:
addBodyElement in interface Frame
Parameters:
element - The element to add
Returns:
The Frame
See Also:
Frame.addBodyElement(org.apache.ecs.Element)

getContainer

protected TableCE getContainer()
Returns:
Returns the internal used <table> element

setCellPadding

public TableFrame setCellPadding(int cellpadding)
Sets the CELLPADING="" attribute.

Parameters:
cellpadding - sets the CELLPADING="" attribute.
Returns:
The Frame

setCellSpacing

public TableFrame setCellSpacing(int cellspacing)
Sets the CELLSPACING="" attribute.

Parameters:
cellspacing - sets the CELLSPACING="" attribute.
Returns:
The Frame

setBorder

public TableFrame setBorder(int border)
Sets the BORDER="" attribute.

Parameters:
border - sets the BORDER="" attribute.
Returns:
The Frame

addElement

public TableFrame addElement(org.apache.ecs.Element element)
Adds an element to the table

Parameters:
element - the element to add
Returns:
The Frame

setClass

public Frame setClass(java.lang.String styleClass)
Description copied from interface: Frame
Set the CLASS attribute.

Specified by:
setClass in interface Frame
Parameters:
styleClass - sets the CLASS attribute.
Returns:
The Frame
See Also:
Frame.setClass(java.lang.String)

setHeight

public Frame setHeight(java.lang.String height)
Description copied from interface: Frame
Set the HEIGHT attribute.

Specified by:
setHeight in interface Frame
Parameters:
height - sets the HEIGHT attribute.
Returns:
The Frame
See Also:
Frame.setHeight(java.lang.String)

setID

public Frame setID(java.lang.String id)
Description copied from interface: Frame
Set the ID attribute.

Specified by:
setID in interface Frame
Parameters:
id - sets the ID attribute.
Returns:
The Frame
See Also:
Frame.setID(java.lang.String)

setStyle

public Frame setStyle(java.lang.String style)
Description copied from interface: Frame
Set the STYLE attribute.

Specified by:
setStyle in interface Frame
Parameters:
style - sets the STYLE attribute.
Returns:
The Frame
See Also:
Frame.setStyle(java.lang.String)

setWidth

public Frame setWidth(java.lang.String width)
Description copied from interface: Frame
Set the WIDTH attribute.

Specified by:
setWidth in interface Frame
Parameters:
width - sets the WIDTH attribute.
Returns:
The Frame
See Also:
Frame.setWidth(java.lang.String)

setSummary

public Frame setSummary(java.lang.String summary)
Description copied from interface: Frame
Set the SUMMARY attribute.

Specified by:
setSummary in interface Frame
Parameters:
summary - sets the SUMMARY attribute.
Returns:
The Frame
See Also:
Frame.setSummary(java.lang.String)

createElement

public org.apache.ecs.ConcreteElement createElement()
Description copied from interface: Frame
Creates a ECS Element from this Frame

Specified by:
createElement in interface Frame
Returns:
Element
See Also:
Frame.createElement()

toString

public java.lang.String toString()
See Also:
Object.toString()


Copyright © 2000-2005 SCC Informationssysteme GmbH. All Rights Reserved.