EchoPoint
2.1.0rc4

echopointng
Class ListSection

java.lang.Object
  extended bynextapp.echo2.app.Component
      extended byechopointng.ComponentEx
          extended byechopointng.AbleComponent
              extended byechopointng.ListSection
All Implemented Interfaces:
AccessKeyable, Attributeable, Borderable, Delegateable, Heightable, Insetable, MouseCursorable, nextapp.echo2.app.RenderIdSupport, java.io.Serializable, Sizeable, ToolTipable, Widthable

public class ListSection
extends AbleComponent

The ListSection class provides a Component that can contain other Components, XhtmlFragments or Objects in a list.

The list can be ordered or unordered. The default is unordered.
The class uses the ListModel interface to provide its contents.

If a ListSection is added as a child of another ListSection, then a new level of list is rendered.

Author:
Brad Baker
See Also:
Serialized Form

Field Summary
static int BULLETS_CIRCLE
           
static int BULLETS_DECIMAL
           
static int BULLETS_DECIMAL_LEADING_ZERO
           
static int BULLETS_DEFAULT
          default bullets
static int BULLETS_DISC
           
static int BULLETS_LOWER_ALPHA
           
static int BULLETS_LOWER_GREEK
           
static int BULLETS_LOWER_LATIN
           
static int BULLETS_LOWER_ROMAN
           
static int BULLETS_NONE
          Determines what type of bullet points are used
static int BULLETS_SQUARE
           
static int BULLETS_UPPER_ALPHA
           
static int BULLETS_UPPER_LATIN
           
static int BULLETS_UPPER_ROMAN
           
static int ORDERED
          Determines whether the list is ordered or not
static java.lang.String PROPERTY_BULLETS
           
static java.lang.String PROPERTY_BULLETS_IMAGE
           
static java.lang.String PROPERTY_MODEL
           
static java.lang.String PROPERTY_ORDERING
           
static int UNORDERED
           
 
Fields inherited from class echopointng.ComponentEx
PROPERTY_HIDDEN
 
Fields inherited from class nextapp.echo2.app.Component
CHILDREN_CHANGED_PROPERTY, ENABLED_CHANGED_PROPERTY, FOCUS_TRAVERSAL_INDEX_CHANGED_PROPERTY, FOCUS_TRAVERSAL_PARTICIPANT_CHANGED_PROPERTY, LAYOUT_DIRECTION_CHANGED_PROPERTY, LOCALE_CHANGED_PROPERTY, PROPERTY_BACKGROUND, PROPERTY_FONT, PROPERTY_FOREGROUND, PROPERTY_LAYOUT_DATA, STYLE_CHANGED_PROPERTY, STYLE_NAME_CHANGED_PROPERTY, VISIBLE_CHANGED_PROPERTY
 
Fields inherited from interface echopointng.able.AccessKeyable
PROPERTY_ACCESS_KEY
 
Fields inherited from interface echopointng.able.Borderable
PROPERTY_BORDER
 
Fields inherited from interface echopointng.able.MouseCursorable
CURSOR_AUTO, CURSOR_CROSSHAIR, CURSOR_CUSTOM_URI, CURSOR_DEFAULT, CURSOR_E_RESIZE, CURSOR_HELP, CURSOR_MOVE, CURSOR_N_RESIZE, CURSOR_NE_RESIZE, CURSOR_NW_RESIZE, CURSOR_POINTER, CURSOR_S_RESIZE, CURSOR_SE_RESIZE, CURSOR_SW_RESIZE, CURSOR_TEXT, CURSOR_W_RESIZE, CURSOR_WAIT, PROPERTY_MOUSE_CURSOR, PROPERTY_MOUSE_CURSOR_URI
 
Fields inherited from interface echopointng.able.Insetable
DEFAULT_INSETS, DEFAULT_OUTSETS, PROPERTY_INSETS, PROPERTY_OUTSETS
 
Fields inherited from interface echopointng.able.Widthable
PROPERTY_WIDTH
 
Fields inherited from interface echopointng.able.Heightable
PROPERTY_HEIGHT
 
Fields inherited from interface echopointng.able.ToolTipable
PROPERTY_TOOL_TIP_TEXT
 
Constructor Summary
ListSection()
          Constructs a ListSection with nothing in it
ListSection(int ordering)
          Constructs a ListSection Ordering can be one of the following values.
ListSection(int ordering, java.util.List newList)
          Constructs a ListSection with the objects supplied in the provided list.
ListSection(int ordering, java.lang.Object[] arrList)
          Constructs a ListSection with the objects supplied in the provided array.
ListSection(java.lang.Object[] arrList)
          Constructs a ListSection with the list contents as arrList.
 
Method Summary
 void add(nextapp.echo2.app.Component c)
          Adds a Component to the ListSection Note that this will only be performed if the underlying model is derived from DefaultListModel.
 void add(nextapp.echo2.app.Component c, int index)
          Adds a Component to the ListSectionat the specified index. -1 indicates to add to the end of the list Note that this will only be performed if the underlying model is derived from DefaultListModel.
 void add(java.lang.Object object)
          Adds an Object to the ListSection Note that this will only be performed if the underlying model is derived from DefaultListModel.
 void add(java.lang.Object object, int index)
          Adds an Object to the ListSectionat the specified index.
 void addListDataListener(nextapp.echo2.app.event.ListDataListener l)
          Adds a ListDataListener to the section
 int getBullets()
           
 nextapp.echo2.app.ImageReference getBulletsImage()
           
 java.lang.Object[] getList()
           
 nextapp.echo2.app.list.ListModel getModel()
           
 int getOrdering()
           
 void remove(nextapp.echo2.app.Component c)
          Removes a Component from the ListSection Note that this will only be performed if the underlying model is derived from DefaultListModel.
 void remove(java.lang.Object object)
          Removes a String from the ListSection Note that this will only be performed if the underlying model is derived from DefaultListModel.
 void removeListDataListener(nextapp.echo2.app.event.ListDataListener l)
          Removes a ListDataListener from this component.
 void setBullets(int newBullets)
          Sets the bullets in use for the ListSection.
 void setBulletsImage(nextapp.echo2.app.ImageReference newBulletsImage)
          Sets the ImageReference of the ListSection's bullets.
 void setList(java.util.List newList)
          Sets the contents of the ListModel of the ListSection.
 void setList(java.lang.Object[] newList)
          Sets the contents of the ListModel of the ListSection.
 void setModel(nextapp.echo2.app.list.ListModel newModel)
          Sets the ListModel of the ListSection.
 void setOrdering(int newOrdering)
          Sets the ordering in use for the ListSection.
 
Methods inherited from class echopointng.AbleComponent
getAccessKey, getBorder, getHeight, getInsets, getMouseCursor, getMouseCursorUri, getOutsets, getToolTipText, getWidth, setAccessKey, setBorder, setHeight, setInsets, setMouseCursor, setMouseCursorUri, setOutsets, setToolTipText, setWidth
 
Methods inherited from class echopointng.ComponentEx
getAttribute, getAttributeNames, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, getRenderProperty, isHidden, setAttribute, setHidden, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty
 
Methods inherited from class nextapp.echo2.app.Component
addPropertyChangeListener, dispose, firePropertyChange, getApplicationInstance, getBackground, getComponent, getComponent, getComponentCount, getComponents, getEventListenerList, getFocusTraversalIndex, getFont, getForeground, getId, getIndexedProperty, getLayoutData, getLayoutDirection, getLocale, getParent, getProperty, getRenderId, getRenderIndexedProperty, getRenderIndexedProperty, getRenderLayoutDirection, getRenderLocale, getRenderProperty, getRenderProperty, getStyle, getStyleName, getVisibleComponent, getVisibleComponentCount, getVisibleComponents, hasEventListenerList, indexOf, init, isAncestorOf, isEnabled, isFocusTraversalParticipant, isRegistered, isRenderEnabled, isRenderVisible, isValidChild, isValidParent, isVisible, processInput, remove, removeAll, removePropertyChangeListener, setBackground, setEnabled, setFocusTraversalIndex, setFocusTraversalParticipant, setFont, setForeground, setId, setIndexedProperty, setLayoutData, setLayoutDirection, setLocale, setProperty, setRenderId, setStyle, setStyleName, setVisible, validate, verifyInput, visibleIndexOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface echopointng.able.Delegateable
getRenderProperty, getRenderProperty
 

Field Detail

PROPERTY_ORDERING

public static final java.lang.String PROPERTY_ORDERING
See Also:
Constant Field Values

PROPERTY_BULLETS

public static final java.lang.String PROPERTY_BULLETS
See Also:
Constant Field Values

PROPERTY_BULLETS_IMAGE

public static final java.lang.String PROPERTY_BULLETS_IMAGE
See Also:
Constant Field Values

PROPERTY_MODEL

public static final java.lang.String PROPERTY_MODEL
See Also:
Constant Field Values

BULLETS_NONE

public static final int BULLETS_NONE
Determines what type of bullet points are used

See Also:
Constant Field Values

BULLETS_DISC

public static final int BULLETS_DISC
See Also:
Constant Field Values

BULLETS_CIRCLE

public static final int BULLETS_CIRCLE
See Also:
Constant Field Values

BULLETS_SQUARE

public static final int BULLETS_SQUARE
See Also:
Constant Field Values

BULLETS_DECIMAL

public static final int BULLETS_DECIMAL
See Also:
Constant Field Values

BULLETS_DECIMAL_LEADING_ZERO

public static final int BULLETS_DECIMAL_LEADING_ZERO
See Also:
Constant Field Values

BULLETS_LOWER_ROMAN

public static final int BULLETS_LOWER_ROMAN
See Also:
Constant Field Values

BULLETS_UPPER_ROMAN

public static final int BULLETS_UPPER_ROMAN
See Also:
Constant Field Values

BULLETS_LOWER_ALPHA

public static final int BULLETS_LOWER_ALPHA
See Also:
Constant Field Values

BULLETS_UPPER_ALPHA

public static final int BULLETS_UPPER_ALPHA
See Also:
Constant Field Values

BULLETS_LOWER_GREEK

public static final int BULLETS_LOWER_GREEK
See Also:
Constant Field Values

BULLETS_LOWER_LATIN

public static final int BULLETS_LOWER_LATIN
See Also:
Constant Field Values

BULLETS_UPPER_LATIN

public static final int BULLETS_UPPER_LATIN
See Also:
Constant Field Values

BULLETS_DEFAULT

public static final int BULLETS_DEFAULT
default bullets

See Also:
Constant Field Values

ORDERED

public static final int ORDERED
Determines whether the list is ordered or not

See Also:
Constant Field Values

UNORDERED

public static final int UNORDERED
See Also:
Constant Field Values
Constructor Detail

ListSection

public ListSection()
Constructs a ListSection with nothing in it


ListSection

public ListSection(java.lang.Object[] arrList)
Constructs a ListSection with the list contents as arrList.


ListSection

public ListSection(int ordering)
Constructs a ListSection Ordering can be one of the following values.


ListSection

public ListSection(int ordering,
                   java.lang.Object[] arrList)
Constructs a ListSection with the objects supplied in the provided array. Ordering can be one of the following values.


ListSection

public ListSection(int ordering,
                   java.util.List newList)
Constructs a ListSection with the objects supplied in the provided list. Ordering can be one of the following values.

Method Detail

add

public void add(java.lang.Object object)
Adds an Object to the ListSection

Note that this will only be performed if the underlying model is derived from DefaultListModel.


add

public void add(java.lang.Object object,
                int index)
Adds an Object to the ListSectionat the specified index.

Note that this will only be performed if the underlying model is derived from DefaultListModel.


add

public void add(nextapp.echo2.app.Component c)
Adds a Component to the ListSection

Note that this will only be performed if the underlying model is derived from DefaultListModel.


add

public void add(nextapp.echo2.app.Component c,
                int index)
Adds a Component to the ListSectionat the specified index. -1 indicates to add to the end of the list

Note that this will only be performed if the underlying model is derived from DefaultListModel.


addListDataListener

public void addListDataListener(nextapp.echo2.app.event.ListDataListener l)
Adds a ListDataListener to the section

Parameters:
l - The ListDataListener to be added.

getBullets

public int getBullets()
Returns:
The bullets in use by the ListSection Can be one of the following values.
  • ListSection.BULLETS_NONE
  • ListSection.BULLETS_DISC
  • ListSection.BULLETS_CIRCLE
  • ListSection.BULLETS_SQUARE
  • ListSection.BULLETS_DECIMAL
  • ListSection.BULLETS_DECIMAL_LEADING_ZERO
  • ListSection.BULLETS_LOWER_ROMAN
  • ListSection.BULLETS_UPPER_ROMAN
  • ListSection.BULLETS_LOWER_ALPHA
  • ListSection.BULLETS_UPPER_ALPHA
  • ListSection.BULLETS_LOWER_GREEK
  • ListSection.BULLETS_LOWER_LATIN
  • ListSection.BULLETS_UPPER_LATIN

getBulletsImage

public nextapp.echo2.app.ImageReference getBulletsImage()
Returns:
The ImageReference of the ListSection's bullets.

getList

public java.lang.Object[] getList()
Returns:
The contents of the ListModel of the ListSection as an array.

getModel

public nextapp.echo2.app.list.ListModel getModel()
Returns:
The ListModel of the ListSection.

getOrdering

public int getOrdering()
Returns:
The ordering in use by the ListSection Can be one of the following values.
  • ListSection.UNORDERED (the default)
  • ListSection.ORDERED

remove

public void remove(java.lang.Object object)
Removes a String from the ListSection

Note that this will only be performed if the underlying model is derived from DefaultListModel.


remove

public void remove(nextapp.echo2.app.Component c)
Removes a Component from the ListSection

Note that this will only be performed if the underlying model is derived from DefaultListModel.


removeListDataListener

public void removeListDataListener(nextapp.echo2.app.event.ListDataListener l)
Removes a ListDataListener from this component.

Parameters:
l - the ListDataListener to remove

setBullets

public void setBullets(int newBullets)
Sets the bullets in use for the ListSection.
Can be one of the following values.


setBulletsImage

public void setBulletsImage(nextapp.echo2.app.ImageReference newBulletsImage)
Sets the ImageReference of the ListSection's bullets.


setList

public void setList(java.lang.Object[] newList)
Sets the contents of the ListModel of the ListSection.


setList

public void setList(java.util.List newList)
Sets the contents of the ListModel of the ListSection.


setModel

public void setModel(nextapp.echo2.app.list.ListModel newModel)
Sets the ListModel of the ListSection.


setOrdering

public void setOrdering(int newOrdering)
Sets the ordering in use for the ListSection.
Can be one of the following values.


EchoPoint
2.1.0rc4