com.arsdigita.bebop
Class SegmentedPanel.Segment

java.lang.Object
  extended bycom.arsdigita.bebop.Completable
      extended bycom.arsdigita.bebop.SimpleComponent
          extended bycom.arsdigita.bebop.TextStylable
              extended bycom.arsdigita.bebop.BlockStylable
                  extended bycom.arsdigita.bebop.SimpleContainer
                      extended bycom.arsdigita.bebop.SegmentedPanel.Segment
All Implemented Interfaces:
Cloneable, Component, Container, Lockable
Enclosing class:
SegmentedPanel

public static class SegmentedPanel.Segment
extends SimpleContainer

A single Segment within this container


Field Summary
 
Fields inherited from class com.arsdigita.bebop.SimpleContainer
versionId
 
Fields inherited from class com.arsdigita.bebop.BlockStylable
ABSBOTTOM, ABSMIDDLE, BASELINE, BOTTOM, CENTER, FULL_WIDTH, INSERT, LEFT, MIDDLE, RIGHT, TEXTTOP, TOP
 
Fields inherited from class com.arsdigita.bebop.SimpleComponent
m_attr
 
Fields inherited from interface com.arsdigita.bebop.Component
BEBOP_XML_NS, CLASS, ID, ON_CLICK, STYLE
 
Constructor Summary
SegmentedPanel.Segment()
          Construct an empty Segment
SegmentedPanel.Segment(Component body)
          Construct a new Segment with no header
SegmentedPanel.Segment(Component header, Component body)
          Construct a new Segment
 
Method Summary
 void add(Component c)
          Add a component to the body of this segment
 void add(Component c, int constraints)
          Add a component to the body of this segment
 void addHeader(Component c)
          Add a header component.
 void generateXML(PageState state, Element parent)
          Generate the XML for this segment
 
Methods inherited from class com.arsdigita.bebop.SimpleContainer
children, contains, generateChildrenXML, generateParent, get, getNamespace, getTag, indexOf, isEmpty, setNamespace, setTag, size
 
Methods inherited from class com.arsdigita.bebop.BlockStylable
setBorder, setBorder, setBorderColor, setHorizontalAlignment, setMargin, setMargin, setPadding, setPadding, setVerticalAlignment
 
Methods inherited from class com.arsdigita.bebop.TextStylable
setBackgroundColor, setColor
 
Methods inherited from class com.arsdigita.bebop.SimpleComponent
clone, exportAttributes, getAttribute, getClassAttr, getIdAttr, getKey, getMetaDataAttribute, getStyleAttr, hasAttributes, isLocked, isVisible, lock, register, register, respond, setAttribute, setClassAttr, setIdAttr, setKey, setMetaDataAttribute, setStyleAttr, setVisible
 
Methods inherited from class com.arsdigita.bebop.Completable
addCompletionListener, fireCompletionEvent
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.arsdigita.bebop.Component
getClassAttr, getIdAttr, getKey, getStyleAttr, isVisible, register, register, respond, setClassAttr, setIdAttr, setKey, setStyleAttr, setVisible
 
Methods inherited from interface com.arsdigita.util.Lockable
isLocked, lock
 

Constructor Detail

SegmentedPanel.Segment

public SegmentedPanel.Segment()
Construct an empty Segment


SegmentedPanel.Segment

public SegmentedPanel.Segment(Component header,
                              Component body)
Construct a new Segment

Parameters:
header - the component which will act as the header; the XSL class attribute for the component will be set to SegmentedPanel.HEADER_CLASS. Typically, this component will be a Label
body - the component which represents the body of the segment, Typically, this component will be a SimpleContainer or a panel of some sort

SegmentedPanel.Segment

public SegmentedPanel.Segment(Component body)
Construct a new Segment with no header

Parameters:
body - the component which represents the body of the segment, Typically, this component will be a SimpleContainer or a panel of some sort
Method Detail

addHeader

public void addHeader(Component c)
Add a header component.

Parameters:
c - an additional header component

add

public void add(Component c)
Add a component to the body of this segment

Specified by:
add in interface Container
Overrides:
add in class SimpleContainer
Parameters:
c - the component to be added

add

public void add(Component c,
                int constraints)
Add a component to the body of this segment

Specified by:
add in interface Container
Overrides:
add in class SimpleContainer
Parameters:
constraints - this parameter is ignored. Child classes should override the add method if they wish to provide special handling of constraints.

generateXML

public void generateXML(PageState state,
                        Element parent)
Generate the XML for this segment

Specified by:
generateXML in interface Component
Overrides:
generateXML in class SimpleContainer
Parameters:
state - the current page state
parent - the parent XML element
See Also:
SimpleContainer.setTag(String), SimpleContainer.setNamespace(String)


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2337 UTC