VR
- The visual root node of the UI toolkit used, e.g.
javafx.scene.Node in case of JavaFX.public abstract class AbstractPolicy<VR> extends java.lang.Object implements IPolicy<VR>
IPolicy
.Constructor and Description |
---|
AbstractPolicy() |
Modifier and Type | Method and Description |
---|---|
protected void |
commit(IPolicy<VR> policy)
If the given
IPolicy is ITransactional , then the policy
is committed and the resulting
IUndoableOperation is executed on the IDomain . |
protected void |
disableRefreshVisuals(IVisualPart<VR,? extends VR> part)
Disable that the given
IVisualPart refreshes its visual, if this
was not already the case (see
IVisualPart.setRefreshVisual(boolean) ). |
protected void |
enableRefreshVisuals(IVisualPart<VR,? extends VR> part)
Restores that the given
IVisualPart refreshes its visual if this
was the case prior to disabling the refresh of visuals. |
IVisualPart<VR,? extends VR> |
getAdaptable() |
IVisualPart<VR,? extends VR> |
getHost()
|
protected void |
init(IPolicy<VR> policy)
|
void |
setAdaptable(IVisualPart<VR,? extends VR> adaptable) |
protected void commit(IPolicy<VR> policy)
IPolicy
is ITransactional
, then the policy
is committed
and the resulting
IUndoableOperation
is executed on the IDomain
.policy
- The IPolicy
to commit.protected void disableRefreshVisuals(IVisualPart<VR,? extends VR> part)
IVisualPart
refreshes its visual, if this
was not already the case (see
IVisualPart.setRefreshVisual(boolean)
). Stores the state (whether
the part was still refreshing its visual or not) so it can be restored
later (see enableRefreshVisuals(IVisualPart)
).part
- The IVisualPart
whose visual refresh is to be
disabled.protected void enableRefreshVisuals(IVisualPart<VR,? extends VR> part)
IVisualPart
refreshes its visual if this
was the case prior to disabling the refresh of visuals.part
- The IVisualPart
for which refreshing of visuals is
restored.public IVisualPart<VR,? extends VR> getAdaptable()
getAdaptable
in interface IAdaptable.Bound<IVisualPart<VR,? extends VR>>
public IVisualPart<VR,? extends VR> getHost()
IPolicy
public void setAdaptable(IVisualPart<VR,? extends VR> adaptable)
setAdaptable
in interface IAdaptable.Bound<IVisualPart<VR,? extends VR>>
Copyright (c) 2014 itemis AG and others. All rights reserved.