|
org.netbeans.swing.tabcontrol 1.8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.netbeans.swing.tabcontrol.DefaultTabDataModel
public class DefaultTabDataModel
Default implementation of TabDataModel.
Constructor Summary | |
---|---|
DefaultTabDataModel()
Creates a new instance of DefaultTabDataModel |
|
DefaultTabDataModel(TabData[] data)
Testing constructor |
Method Summary | |
---|---|
void |
addChangeListener(ChangeListener listener)
Registers ChangeListener to receive events. |
void |
addComplexListDataListener(ComplexListDataListener listener)
Add a data listener |
void |
addTab(int index,
TabData data)
Add a single tab at the specified location |
void |
addTabs(int[] indices,
TabData[] data)
Add the specified tabs at the specified indices |
void |
addTabs(int start,
TabData[] data)
Atomically add a set of tabs at the specified index |
TabData |
getTab(int index)
Retrieve data for a given tab |
List<TabData> |
getTabs()
Retrieve all the tab data contained in the model as a List |
int |
indexOf(TabData td)
Fetch the index of a tab matching the passed TabData object. |
void |
removeChangeListener(ChangeListener listener)
Removes ChangeListener from the list of listeners. |
void |
removeComplexListDataListener(ComplexListDataListener listener)
Remove a data listener |
void |
removeTab(int index)
Remove the tab at the specified index |
void |
removeTabs(int[] indices)
Remove the tabs at the specified indices |
void |
removeTabs(int start,
int end)
Remove a range of tabs from start up to and including
finish . |
void |
setIcon(int[] indices,
Icon[] icons)
Atomically set the icons for a set of indices. |
void |
setIcon(int index,
Icon i)
Set the icon for a given tab. |
void |
setIconsAndText(int[] indices,
String[] txt,
Icon[] icons)
Atomically set the icons and text simultaneously for more than one tab. |
void |
setTab(int index,
TabData data)
Set the tab data for a given tab to the passed value |
void |
setTabs(TabData[] data)
Replace the entire set of tabs represented by the model |
void |
setText(int[] indices,
String[] txt)
Atomically set the text for a number of tabs. |
void |
setText(int index,
String txt)
Set the text for a given tab. |
int |
size()
The number of tabs contained in the model. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DefaultTabDataModel()
public DefaultTabDataModel(TabData[] data)
Method Detail |
---|
public List<TabData> getTabs()
TabDataModel
getTabs
in interface TabDataModel
public TabData getTab(int index)
TabDataModel
getTab
in interface TabDataModel
index
- The index for which to retrieve tab data
public void setTabs(TabData[] data)
TabDataModel
setTabs
in interface TabDataModel
public void setIcon(int index, Icon i)
TabDataModel
setIcon
in interface TabDataModel
index
- The index to set the icon fori
- The icon to use for the tabpublic void setText(int index, String txt)
TabDataModel
setText
in interface TabDataModel
index
- The index of the tabtxt
- The replacement textpublic void setIconsAndText(int[] indices, String[] txt, Icon[] icons)
TabDataModel
setIconsAndText
in interface TabDataModel
indices
- The indices which should have their data changedtxt
- The replacement text values corresponding to the passed
indicesicons
- The replacement icons corresponding to the passed indicespublic void setIcon(int[] indices, Icon[] icons)
TabDataModel
setIcon
in interface TabDataModel
indices
- The indices for which the corresponding icons should be
changedicons
- The replacement icons. This array must be the same length
as the indices parameterpublic void setText(int[] indices, String[] txt)
TabDataModel
setText
in interface TabDataModel
indices
- The indices of the tabs to changetxt
- The text values for the tabspublic void setTab(int index, TabData data)
TabDataModel
setTab
in interface TabDataModel
index
- The index of the tab to be changeddata
- The new tab data for this indexpublic void addTab(int index, TabData data)
TabDataModel
addTab
in interface TabDataModel
public void addTabs(int start, TabData[] data)
TabDataModel
addTabs
in interface TabDataModel
start
- The insert point for new tabsdata
- The tab data to insertpublic void removeTab(int index)
TabDataModel
removeTab
in interface TabDataModel
index
- The tab indexpublic void removeTabs(int start, int end)
start
up to and including
finish
.
removeTabs
in interface TabDataModel
start
- the start indexend
- the end indexpublic void addTabs(int[] indices, TabData[] data)
TabDataModel
addTabs
in interface TabDataModel
indices
- The indices at which tabs will be addeddata
- The tabs to add, in order corresponding to the indices
parameterpublic void removeTabs(int[] indices)
TabDataModel
removeTabs
in interface TabDataModel
indices
- The indices at which tabs should be removedpublic int size()
TabDataModel
size
in interface TabDataModel
public void addComplexListDataListener(ComplexListDataListener listener)
TabDataModel
addComplexListDataListener
in interface TabDataModel
listener
- The listenerpublic void removeComplexListDataListener(ComplexListDataListener listener)
TabDataModel
removeComplexListDataListener
in interface TabDataModel
listener
- The listenerpublic String toString()
public void addChangeListener(ChangeListener listener)
addChangeListener
in interface TabDataModel
listener
- The listener to register.public void removeChangeListener(ChangeListener listener)
removeChangeListener
in interface TabDataModel
listener
- The listener to remove.public int indexOf(TabData td)
TabDataModel
indexOf
in interface TabDataModel
|
org.netbeans.swing.tabcontrol 1.8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |