|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.knime.core.node.workflow.NodeUIInformation
public class NodeUIInformation
Special NodeExtraInfo object used by the workflow editor.
Basically this stores the visual bounds of the node in the workflow editor
pane. Note: To be independent of draw2d/GEF this doesn't use the "natural"
Rectangle object, but simply stores an int[].
TODO This needs to be in "core", as by now the WFM tries to make instances of
this class while load()ing.
see org.eclipse.draw2d.geometry.Rectangle
| Constructor Summary | |
|---|---|
NodeUIInformation()
Creates new object, the bounds to be set are assumed to be absolute (m_isInitialized is true). |
|
NodeUIInformation(int x,
int y,
int width,
int height,
boolean absoluteCoords)
Inits new node figure with given coordinates. |
|
| Method Summary | |
|---|---|
NodeUIInformation |
clone()
UIInformation objects are cloneable without further restriction. |
NodeUIInformation |
createNewWithOffsetPosition(int[] moveDist)
Changes the position by setting the bounds left top corner according to the given moving distance. |
int[] |
getBounds()
|
boolean |
hasAbsoluteCoordinates()
|
boolean |
isFilledProperly()
Returns if the loaded UI information is complete. |
boolean |
isSymbolRelative()
If false, the coordinates are loaded with an old workflow and are relative to the top left corner of the node's figure. |
void |
load(NodeSettingsRO conf,
WorkflowPersistorVersion200.LoadVersion loadVersion)
Reads the information from the NodeSettings object. |
void |
save(NodeSettingsWO config)
Stores all contained information into the given configuration. |
void |
setNodeLocation(int x,
int y,
int w,
int h)
Sets the location. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public NodeUIInformation()
public NodeUIInformation(int x,
int y,
int width,
int height,
boolean absoluteCoords)
x - x coordinate of the figures symbol (i.e. the background image)y - y coordinate of the figures symbol (i.e. the background image)width - width of figureheight - height of figureabsoluteCoords - If the coordinates are absolute.| Method Detail |
|---|
public void save(NodeSettingsWO config)
save in interface UIInformationconfig - The configuration to write the current settings into.UIInformation.load(org.knime.core.node.NodeSettingsRO, org.knime.core.node.workflow.WorkflowPersistorVersion200.LoadVersion)
public void load(NodeSettingsRO conf,
WorkflowPersistorVersion200.LoadVersion loadVersion)
throws InvalidSettingsException
load in interface UIInformationconf - Retrieve the data from.loadVersion - The workflow version that was used to store this
object
InvalidSettingsException - If the required keys are not available
in the NodeSettings.UIInformation.save(org.knime.core.node.NodeSettingsWO)public boolean isFilledProperly()
true if it is filled properly, false
otherwisepublic boolean hasAbsoluteCoordinates()
public boolean isSymbolRelative()
public void setNodeLocation(int x,
int y,
int w,
int h)
x - x-coordinate of the figures symbol (i.e. the background image)y - y-coordinate of the figures symbol (i.e. the background image)w - widthh - heightpublic int[] getBounds()
public NodeUIInformation createNewWithOffsetPosition(int[] moveDist)
moveDist - the distance to change the left top corner
public NodeUIInformation clone()
clone in interface UIInformationclone in class Objectpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||