ca.sqlpower.architect.swingui.olap
Class OLAPPaneSection<C>

java.lang.Object
  extended by ca.sqlpower.architect.swingui.olap.OLAPPaneSection<C>
All Implemented Interfaces:
PaneSection<C>

public abstract class OLAPPaneSection<C>
extends java.lang.Object
implements PaneSection<C>

Generic implementation of a pane section. Should suffice for most uses.


Constructor Summary
OLAPPaneSection(java.lang.Class<C> type, java.util.List<C> items, java.lang.String title)
           
 
Method Summary
 void addItem(C item)
          Calls addItem(getItems().size(), item).
 java.util.List<C> getItems()
          This is the same list that was passed to the constructor.
 java.lang.Class<C> getItemType()
          Returns the type of items that appear in this section.
 java.lang.String getTitle()
          Returns this section's title.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface ca.sqlpower.architect.swingui.olap.PaneSection
addItem
 

Constructor Detail

OLAPPaneSection

public OLAPPaneSection(java.lang.Class<C> type,
                       java.util.List<C> items,
                       java.lang.String title)
Method Detail

getItems

public java.util.List<C> getItems()
This is the same list that was passed to the constructor. It may or may not be modifiable (depending on what you provided to the constructor) and its contents may or may not mirror the contents of the business model (again, it depends on what you passed to the constructor).

No matter what, you won't get events from the PaneSection when the item list changes. Consult the model for change notifications.

Specified by:
getItems in interface PaneSection<C>

getTitle

public java.lang.String getTitle()
Description copied from interface: PaneSection
Returns this section's title. If the section should not have a rendered title, returns null.

Specified by:
getTitle in interface PaneSection<C>

getItemType

public java.lang.Class<C> getItemType()
Description copied from interface: PaneSection
Returns the type of items that appear in this section.

Specified by:
getItemType in interface PaneSection<C>

addItem

public void addItem(C item)
Calls addItem(getItems().size(), item).

Specified by:
addItem in interface PaneSection<C>
Parameters:
item - The item to add.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2003-2007 SQL Power Group Inc. www.sqlpower.ca