|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface TableColumn
This interface provides access to an Azureus table column.
| Field Summary | |
|---|---|
static int |
ALIGN_CENTER
center alignment |
static int |
ALIGN_LEAD
leading alignment |
static int |
ALIGN_TRAIL
trailing alignment |
static int |
INTERVAL_GRAPHIC
Trigger refresh listeners every time a graphic cycle occurs (set by user) |
static int |
INTERVAL_INVALID_ONLY
Trigger refresh only when the cell/row becomes invalid |
static int |
INTERVAL_LIVE
Trigger refresh listeners every time a GUI update cycle occurs (set by user) |
static int |
POSITION_INVISIBLE
For setPosition(int). |
static int |
POSITION_LAST
For setPosition(int). |
static int |
TYPE_GRAPHIC
The graphic type, providing access to graphic specific functions in TableCell. |
static int |
TYPE_TEXT
The cells in this column display textual information. |
static int |
TYPE_TEXT_ONLY
The cells in this column display only textual information, and does not set any other visible properties of cell (background, foreground, icon, etc). |
| Method Summary | |
|---|---|
void |
addCellAddedListener(TableCellAddedListener listener)
Adds a listener that triggers when a TableCell that belongs to this column is being added. |
void |
addCellDisposeListener(TableCellDisposeListener listener)
Adds a listener that triggers when a TableCell that belongs to this column is being disposed. |
void |
addCellMouseListener(TableCellMouseListener listener)
Adds a listener that triggers when a TableCell that belongs to this column has a mouse event. |
void |
addCellRefreshListener(TableCellRefreshListener listener)
Adds a listener that triggers when a TableCell that belongs to this column needs refreshing. |
void |
addCellToolTipListener(TableCellToolTipListener listener)
Adds a listener that triggers when a TableCell that belongs to this column has a tooltip action |
TableContextMenuItem |
addContextMenuItem(java.lang.String resourceKey)
Adds a Context Menu item to the "This Column" sub menu |
void |
addListeners(java.lang.Object listenerObject)
A listener is added for every type of cell listener the supplied object implements |
int |
getAlignment()
Returns the alignment of the column |
int |
getMaxWidth()
Gets the maximum width the column can be Not all UIs may have this feature implemented. |
int |
getMinWidth()
Gets the minimum width that the column can be before other columns start collapsing. |
java.lang.String |
getName()
The logical name of the column. |
int |
getPosition()
Returns the position of the column |
int |
getPreferredWidth()
Gets the preferred width of the coloumn. |
int |
getRefreshInterval()
Returns the refresh interval of the column. |
java.lang.String |
getTableID()
Which table the column will be visible in. |
int |
getType()
Returns the type of the contained data. |
java.lang.Object |
getUserData(java.lang.String key)
|
int |
getWidth()
Returns the column's size |
void |
initialize(int iAlignment,
int iPosition,
int iWidth)
Initialize a group of variables all at once. |
void |
initialize(int iAlignment,
int iPosition,
int iWidth,
int iInterval)
Initialize a group of variables all at once. |
void |
invalidateCell(java.lang.Object data_source)
Invalidates any cells which are linked to the given data source object. |
void |
invalidateCells()
Invalidate all cells in this column. |
boolean |
isMaxWidthAuto()
Retrieve whether the max width is automatically being set. |
boolean |
isMinWidthAuto()
Retrieve whether the min width is automatically being set |
boolean |
isObfusticated()
Returns whether the column's data will be obfusticated when screen capturing (for bug reports, etc). |
boolean |
isPreferredWidthAuto()
Retrieves whether the preferred width is automatically calculated. |
boolean |
isVisible()
Gets the visibility of the column Not all UIs may have this feature implemented. |
void |
postConfigLoad()
implement this method if you want to be notified when the stored column configuration such as user data or GUI-adjustable properties have been loaded |
void |
preConfigSave()
implement this method if you want to be notified when the column configuration is about to be serialized |
void |
removeCellAddedListener(TableCellAddedListener listener)
|
void |
removeCellDisposeListener(TableCellDisposeListener listener)
|
void |
removeCellMouseListener(TableCellMouseListener listener)
Remove a previously added TableCellMouseListener |
void |
removeCellRefreshListener(TableCellRefreshListener listener)
Removed a previously added TableCellRefreshListener |
void |
removeCellToolTipListener(TableCellToolTipListener listener)
|
void |
removeUserData(java.lang.String key)
|
void |
setAlignment(int alignment)
Orientation of the columns text and header. |
void |
setMaxWidth(int maxwidth)
Sets the maximum width that the column can be Not all UIs may have this feature implemented. |
void |
setMaxWidthAuto(boolean automaxwidth)
Sets whether the max width is automatically set. |
void |
setMinWidth(int minwidth)
Sets the minimum width that the column can be before other columns start collapsing. |
void |
setMinWidthAuto(boolean autowidth)
Sets whether the min width of the column is automatically set. |
void |
setObfustication(boolean hideData)
Sets whether the column's data will be obfusticated during a screen capture (for bug reports, etc). |
void |
setPosition(int position)
Location to put the column. |
void |
setPreferredWidth(int width)
Sets the preferred width of the column. |
void |
setPreferredWidthAuto(boolean auto)
Sets whether the preferred with is automatically calculated. |
void |
setRefreshInterval(int interval)
Set how often the cell receives a refresh() trigger |
void |
setType(int type)
The type of the contained data. |
void |
setUserData(java.lang.String key,
java.lang.Object value)
Associates custom data with the column, usually meant for column-specific settings and stores it across sessions |
void |
setVisible(boolean visible)
Sets the visibility of the column |
void |
setWidth(int width)
The column size. |
void |
setWidthLimits(int min,
int max)
Sets the minimum and maximum widths in one call Not all UIs may have this min and max limits implemented. |
| Field Detail |
|---|
static final int TYPE_TEXT
static final int TYPE_GRAPHIC
TableCell.
static final int TYPE_TEXT_ONLY
static final int ALIGN_LEAD
static final int ALIGN_TRAIL
static final int ALIGN_CENTER
static final int POSITION_INVISIBLE
setPosition(int). Make column invisible initially.
static final int POSITION_LAST
setPosition(int). Make column the last column initially.
static final int INTERVAL_GRAPHIC
static final int INTERVAL_LIVE
static final int INTERVAL_INVALID_ONLY
| Method Detail |
|---|
void initialize(int iAlignment,
int iPosition,
int iWidth,
int iInterval)
iAlignment - See setAlignment(int)iPosition - See setPosition(int)iWidth - See setWidth(int)iInterval - See setRefreshInterval(int)
void initialize(int iAlignment,
int iPosition,
int iWidth)
iAlignment - See setAlignment(int)iPosition - See setPosition(int)iWidth - See setWidth(int)java.lang.String getName()
TableManager.createColumn(java.lang.String, java.lang.String) and can not be changed.
java.lang.String getTableID()
TableManager.createColumn(java.lang.String, java.lang.String) and can not be changed.
TableManager.TABLE_* constant(s)void setType(int type)
NOTE: This MUST be set BEFORE adding the column to a table.
The default type is TYPE_TEXT_ONLY.
type - TYPE_TEXT, TYPE_TEXT_ONLY, TYPE_GRAPHICint getType()
void setWidth(int width)
NOTE: This MUST be set BEFORE adding the column to a table.
width - the size in pixelsint getWidth()
void setPosition(int position)
TableManager.addColumn(org.gudy.azureus2.plugins.ui.tables.TableColumn)), the supplied value will be used
as the default position. If the user has moved the column previously,
the new position will be used, and the default position will be ignored.
This function cannot be called after you have added the column to a UI
table. In the future, setting the position after adding the column to the
UI table will result in the column being moved.
position - Column Number (0 based), POSITION_INVISIBLE or POSITION_LASTint getPosition()
void setAlignment(int alignment)
NOTE: This MUST be set BEFORE adding the column to a table.
alignment - ALIGN_TRAIL, ALIGN_LEAD, or ALIGN_CENTERint getAlignment()
void setRefreshInterval(int interval)
interval - INTERVAL_GRAPHIC, INTERVAL_LIVE, INTERVAL_INVALID_ONLY
constants, or an integer based on the user-configurable
"GUI refresh interval". For example, specifying 4 will
result in a refresh trigger every 4 "GUI refresh intervals"int getRefreshInterval()
void setMinWidth(int minwidth)
If not set, the width specified on initialize will be the minimum width
Not all UIs may have this feature implemented.
minwidth - new minumum widthint getMinWidth()
If not set, the width specified on initialize will be the minimum width
Not all UIs may have this feature implemented.
void setMaxWidth(int maxwidth)
Not all UIs may have this feature implemented.
maxwidth - new maximum widthint getMaxWidth()
Not all UIs may have this feature implemented.
void setWidthLimits(int min,
int max)
Not all UIs may have this min and max limits implemented.
min - New minimum column widthmax - New maximum column widthvoid setMaxWidthAuto(boolean automaxwidth)
automaxwidth - boolean isMaxWidthAuto()
void setMinWidthAuto(boolean autowidth)
autowidth - boolean isMinWidthAuto()
void setPreferredWidth(int width)
width - New preferred widthint getPreferredWidth()
boolean isPreferredWidthAuto()
void setPreferredWidthAuto(boolean auto)
auto - Preferred Width Auto Stateboolean isVisible()
Not all UIs may have this feature implemented.
void setUserData(java.lang.String key,
java.lang.Object value)
key - the key under which the value will be stored and serializedvalue - should be BEncodable, otherwise it won't be serializedvoid removeUserData(java.lang.String key)
void postConfigLoad()
void preConfigSave()
java.lang.Object getUserData(java.lang.String key)
key -
void setVisible(boolean visible)
visible - New visibility statevoid addCellRefreshListener(TableCellRefreshListener listener)
listener - Listener Object to be called when refresh is needed.void removeCellRefreshListener(TableCellRefreshListener listener)
listener - Previously added listenervoid addCellAddedListener(TableCellAddedListener listener)
listener - Listener Object to be called when refresh is needed.void removeCellAddedListener(TableCellAddedListener listener)
void addCellDisposeListener(TableCellDisposeListener listener)
listener - Listener Object to be called when refresh is needed.void removeCellDisposeListener(TableCellDisposeListener listener)
void addCellToolTipListener(TableCellToolTipListener listener)
listener - Listener Object to be called when refresh is needed.void removeCellToolTipListener(TableCellToolTipListener listener)
void addCellMouseListener(TableCellMouseListener listener)
listener - void removeCellMouseListener(TableCellMouseListener listener)
listener - Previously added listenervoid addListeners(java.lang.Object listenerObject)
listenerObject - Object implementing some cell listenetersvoid invalidateCells()
void invalidateCell(java.lang.Object data_source)
TableContextMenuItem addContextMenuItem(java.lang.String resourceKey)
resourceKey - ID of the context menu, which is also used to retreieve
the textual name from the plugin language file.
boolean isObfusticated()
Currently not fully implemented for plugins
void setObfustication(boolean hideData)
hideData - new state of obfustication
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||