|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.nebula.widgets.nattable.layer.InvertedLayer
public class InvertedLayer
| Field Summary |
|---|
| Fields inherited from interface org.eclipse.nebula.widgets.nattable.persistence.IPersistable |
|---|
DOT, VALUE_SEPARATOR |
| Constructor Summary | |
|---|---|
InvertedLayer(IUniqueIndexLayer underlyingLayer)
|
|
| Method Summary | |
|---|---|
void |
addLayerListener(ILayerListener listener)
|
void |
configure(ConfigRegistry configRegistry,
UiBindingRegistry uiBindingRegistry)
Every layer gets this call back, starting at the top of the stack. |
void |
dispose()
|
boolean |
doCommand(ILayerCommand command)
Opportunity to respond to a command as it flows down the stack. |
void |
fireLayerEvent(ILayerEvent event)
Events can be fired to notify other components of the grid. |
org.eclipse.swt.graphics.Rectangle |
getBoundsByPosition(int columnPosition,
int rowPosition)
Calculates the bounds in pixel for the given cell position. |
ILayerCell |
getCellByPosition(int columnPosition,
int rowPosition)
|
ICellPainter |
getCellPainter(int columnPosition,
int rowPosition,
ILayerCell cell,
IConfigRegistry configRegistry)
|
IClientAreaProvider |
getClientAreaProvider()
|
int |
getColumnCount()
|
int |
getColumnIndexByPosition(int columnPosition)
Gets the underlying non-transformed column index for the given column position. |
int |
getColumnPositionByIndex(int columnIndex)
|
int |
getColumnPositionByX(int x)
Returns the column position that contains the given x coordinate. |
int |
getColumnWidthByPosition(int columnPosition)
Returns the width in pixels of the given column. |
LabelStack |
getConfigLabelsByPosition(int columnPosition,
int rowPosition)
|
Object |
getDataValueByPosition(int columnPosition,
int rowPosition)
|
String |
getDisplayModeByPosition(int columnPosition,
int rowPosition)
|
int |
getHeight()
Returns the total height in pixels of this layer. |
ILayerPainter |
getLayerPainter()
|
int |
getPreferredColumnCount()
|
int |
getPreferredHeight()
|
int |
getPreferredRowCount()
|
int |
getPreferredWidth()
|
LabelStack |
getRegionLabelsByXY(int x,
int y)
Layer can apply its own labels to any cell it wishes. |
int |
getRowCount()
|
int |
getRowHeightByPosition(int rowPosition)
Returns the height in pixels of the given row. |
int |
getRowIndexByPosition(int rowPosition)
Gets the underlying non-transformed row index for the given row position. |
int |
getRowPositionByIndex(int rowIndex)
|
int |
getRowPositionByY(int y)
Returns the row position that contains the given y coordinate. |
int |
getStartXOfColumnPosition(int columnPosition)
Returns the x offset in pixels of the given column. |
int |
getStartYOfRowPosition(int rowPosition)
Returns the y offset in pixels of the given row. |
ILayer |
getUnderlyingLayerByPosition(int columnPosition,
int rowPosition)
|
Collection<ILayer> |
getUnderlyingLayersByColumnPosition(int columnPosition)
|
Collection<ILayer> |
getUnderlyingLayersByRowPosition(int rowPosition)
|
int |
getWidth()
Returns the total width in pixels of this layer. |
void |
handleLayerEvent(ILayerEvent event)
Handle an event notification from an ILayer |
boolean |
hasLayerListener(Class<? extends ILayerListener> layerListenerClass)
|
boolean |
isColumnPositionResizable(int columnPosition)
|
boolean |
isRowPositionResizable(int rowPosition)
|
void |
loadState(String prefix,
Properties properties)
Restore the state out of the given Properties identified by the specified prefix. |
int |
localToUnderlyingColumnPosition(int localColumnPosition)
Convert a column position to the coordinates of the underlying layer. |
int |
localToUnderlyingRowPosition(int localRowPosition)
|
void |
registerCommandHandler(ILayerCommandHandler<?> commandHandler)
|
void |
registerPersistable(IPersistable persistable)
Persistables registered with a layer will have a chance to write their data out to the Properties instance when the layer is persisted. |
void |
removeLayerListener(ILayerListener listener)
|
void |
saveState(String prefix,
Properties properties)
Saves the state to the given Properties using the specified prefix. |
void |
setClientAreaProvider(IClientAreaProvider clientAreaProvider)
|
int |
underlyingToLocalColumnPosition(ILayer sourceUnderlyingLayer,
int underlyingColumnPosition)
|
Collection<Range> |
underlyingToLocalColumnPositions(ILayer sourceUnderlyingLayer,
Collection<Range> underlyingColumnPositionRanges)
|
int |
underlyingToLocalRowPosition(ILayer sourceUnderlyingLayer,
int underlyingRowPosition)
|
Collection<Range> |
underlyingToLocalRowPositions(ILayer sourceUnderlyingLayer,
Collection<Range> underlyingRowPositionRanges)
|
void |
unregisterCommandHandler(Class<? extends ILayerCommand> commandClass)
|
void |
unregisterPersistable(IPersistable persistable)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public InvertedLayer(IUniqueIndexLayer underlyingLayer)
| Method Detail |
|---|
public void handleLayerEvent(ILayerEvent event)
ILayerListenerILayer
handleLayerEvent in interface ILayerListenerevent - the event
public void saveState(String prefix,
Properties properties)
IPersistable
saveState in interface IPersistableprefix - The prefix to use for the state keys. Is also used as the
state configuration name.properties - The Properties instance to save the state to.
public void loadState(String prefix,
Properties properties)
IPersistable
loadState in interface IPersistableprefix - The prefix to use for the state keys. Is also used as the
state configuration name.properties - The Properties instance to load the state from.public void dispose()
dispose in interface ILayerpublic void registerPersistable(IPersistable persistable)
ILayerProperties instance when the layer is persisted.
registerPersistable in interface ILayerpersistable - the persistable to be registeredpublic void unregisterPersistable(IPersistable persistable)
unregisterPersistable in interface ILayer
public void configure(ConfigRegistry configRegistry,
UiBindingRegistry uiBindingRegistry)
ILayerNatTable.configure() method. This is an
opportunity to add any key/mouse bindings and other general
configuration.
configure in interface ILayerconfigRegistry - instance owned by NatTableuiBindingRegistry - instance owned by NatTable
public LabelStack getRegionLabelsByXY(int x,
int y)
ILayer
getRegionLabelsByXY in interface ILayerx - the x pixel coordinatey - the y pixel coordinate
public boolean doCommand(ILayerCommand command)
ILayerILayerCommand.convertToTargetLayer(ILayer)
doCommand in interface ILayercommand - the command to perform
public void registerCommandHandler(ILayerCommandHandler<?> commandHandler)
registerCommandHandler in interface ILayerpublic void unregisterCommandHandler(Class<? extends ILayerCommand> commandClass)
unregisterCommandHandler in interface ILayerpublic void fireLayerEvent(ILayerEvent event)
ILayer
Example: When the contents of the grid change IVisualChangeEvent
can be fired to notify other layers to refresh their caches etc.
fireLayerEvent in interface ILayerevent - the event to firepublic void addLayerListener(ILayerListener listener)
addLayerListener in interface ILayerpublic void removeLayerListener(ILayerListener listener)
removeLayerListener in interface ILayerpublic boolean hasLayerListener(Class<? extends ILayerListener> layerListenerClass)
hasLayerListener in interface ILayerlayerListenerClass - The type of ILayerListener to check for existence
true if this ILayer has a
ILayerListener registered for the specified type,
false if there is no such listener registered
alreadypublic ILayerPainter getLayerPainter()
getLayerPainter in interface ILayerpublic IClientAreaProvider getClientAreaProvider()
getClientAreaProvider in interface ILayerpublic void setClientAreaProvider(IClientAreaProvider clientAreaProvider)
setClientAreaProvider in interface ILayerpublic int getColumnCount()
getColumnCount in interface ILayerpublic int getPreferredColumnCount()
getPreferredColumnCount in interface ILayerpublic int getColumnIndexByPosition(int columnPosition)
ILayer
getColumnIndexByPosition in interface ILayercolumnPosition - a column position relative to this coordinate model
public int localToUnderlyingColumnPosition(int localColumnPosition)
ILayer
localToUnderlyingColumnPosition in interface ILayerlocalColumnPosition - column position in local (the layer's own) coordinates
public int underlyingToLocalColumnPosition(ILayer sourceUnderlyingLayer,
int underlyingColumnPosition)
underlyingToLocalColumnPosition in interface ILayer
public Collection<Range> underlyingToLocalColumnPositions(ILayer sourceUnderlyingLayer,
Collection<Range> underlyingColumnPositionRanges)
underlyingToLocalColumnPositions in interface ILayerpublic int getWidth()
ILayer
getWidth in interface ILayerpublic int getPreferredWidth()
getPreferredWidth in interface ILayerpublic int getColumnWidthByPosition(int columnPosition)
ILayer
getColumnWidthByPosition in interface ILayercolumnPosition - the column position in this layer
public boolean isColumnPositionResizable(int columnPosition)
isColumnPositionResizable in interface ILayerpublic int getColumnPositionByX(int x)
ILayer
getColumnPositionByX in interface ILayerx - a horizontal pixel location relative to the pixel boundary of
this layer
public int getStartXOfColumnPosition(int columnPosition)
ILayer
getStartXOfColumnPosition in interface ILayercolumnPosition - the column position in this layer
public Collection<ILayer> getUnderlyingLayersByColumnPosition(int columnPosition)
getUnderlyingLayersByColumnPosition in interface ILayerpublic int getColumnPositionByIndex(int columnIndex)
getColumnPositionByIndex in interface IUniqueIndexLayerpublic int getRowCount()
getRowCount in interface ILayerpublic int getPreferredRowCount()
getPreferredRowCount in interface ILayerpublic int getRowIndexByPosition(int rowPosition)
ILayer
getRowIndexByPosition in interface ILayerrowPosition - a row position relative to this coordinate model
public int localToUnderlyingRowPosition(int localRowPosition)
localToUnderlyingRowPosition in interface ILayer
public int underlyingToLocalRowPosition(ILayer sourceUnderlyingLayer,
int underlyingRowPosition)
underlyingToLocalRowPosition in interface ILayer
public Collection<Range> underlyingToLocalRowPositions(ILayer sourceUnderlyingLayer,
Collection<Range> underlyingRowPositionRanges)
underlyingToLocalRowPositions in interface ILayerpublic int getHeight()
ILayer
getHeight in interface ILayerpublic int getPreferredHeight()
getPreferredHeight in interface ILayerpublic int getRowHeightByPosition(int rowPosition)
ILayer
getRowHeightByPosition in interface ILayerrowPosition - the row position in this layer
public boolean isRowPositionResizable(int rowPosition)
isRowPositionResizable in interface ILayerpublic int getRowPositionByY(int y)
ILayer
getRowPositionByY in interface ILayery - a vertical pixel location relative to the pixel boundary of
this layer
public int getStartYOfRowPosition(int rowPosition)
ILayer
getStartYOfRowPosition in interface ILayerrowPosition - the row position in this layer
public Collection<ILayer> getUnderlyingLayersByRowPosition(int rowPosition)
getUnderlyingLayersByRowPosition in interface ILayerpublic int getRowPositionByIndex(int rowIndex)
getRowPositionByIndex in interface IUniqueIndexLayer
public ILayerCell getCellByPosition(int columnPosition,
int rowPosition)
getCellByPosition in interface ILayer
public org.eclipse.swt.graphics.Rectangle getBoundsByPosition(int columnPosition,
int rowPosition)
ILayer
getBoundsByPosition in interface ILayercolumnPosition - the column position of the cellrowPosition - the row position of the cell
null if there are no valid bounds
public String getDisplayModeByPosition(int columnPosition,
int rowPosition)
getDisplayModeByPosition in interface ILayercolumnPosition - the column position of the cellrowPosition - the row position of the cell
DisplayMode for the cell at the given position. The
DisplayMode affects the settings out of the
ConfigRegistry. Display mode is NORMAL by default.
Example: SelectionLayer overrides this to return
the SELECT label for cells which are selected.
public LabelStack getConfigLabelsByPosition(int columnPosition,
int rowPosition)
getConfigLabelsByPosition in interface ILayer
public Object getDataValueByPosition(int columnPosition,
int rowPosition)
getDataValueByPosition in interface ILayer
public ILayer getUnderlyingLayerByPosition(int columnPosition,
int rowPosition)
getUnderlyingLayerByPosition in interface ILayer
public ICellPainter getCellPainter(int columnPosition,
int rowPosition,
ILayerCell cell,
IConfigRegistry configRegistry)
getCellPainter in interface ILayer
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||