public class IlvApp6aSymbologyTreeViewActions extends IlvAbstractGroupTreeViewActions
Modifier and Type | Field and Description |
---|---|
static String |
APP6A
The SDM tag used for APP6a nodes.
|
Constructor and Description |
---|
IlvApp6aSymbologyTreeViewActions()
Creates actions to manage App6a symbol tree.
|
Modifier and Type | Method and Description |
---|---|
void |
actOnSymbologyChanged()
The APP6 Symbology is not supposed to change on the fly.
|
void |
createSymbol(IlvSDMModel model,
Object group,
IlvApplyObject applier)
Creates a new symbol interactively.
|
Object |
dropSymbolAt(IlvSDMModel model,
Object data,
Double lonRad,
Double latRad)
Returns null (you cannot drop an app6 symbol)
|
Object |
duplicateSymbol(IlvSDMModel model,
Object node)
Duplicated the symbol
|
void |
editSymbol(IlvSDMModel model,
Object node,
IlvApplyObject applier)
Shows an app6a symbol edition dialog
|
void |
editSymbology(IlvSDMModel model,
IlvApplyObject applier)
Not implemented
|
IlvSymbolLocationEditor |
getLatLonPicker()
Returns the locator used.
|
IlvPersistentObject |
getPersistentContext()
This method does nothing by default and returns null
Returns the context that should persist with the model.
|
boolean |
isCreateSymbolEnabled(IlvSDMModel model)
Returns true
|
boolean |
isDuplicateSymbolEnabled(IlvSDMModel model)
Returns true
|
boolean |
isEditSymbolEnabled(IlvSDMModel model)
Returns true
|
boolean |
isEditSymbologyEnabled(IlvSDMModel model)
Returns false
|
boolean |
isPropertyIgnored(IlvSDMModel model,
Object node,
String propertyName)
This method ignores the "this" property because it is set at construction time.
|
Object |
newSymbol(String tag)
This method will be called when a node needs to be created at read time.
|
void |
setLatLonPicker(IlvSymbolLocationEditor locator)
Sets the locator to use to pick a point interactively.
|
void |
setPersistentContext(IlvPersistentObject context)
This method does nothing by default.
|
String |
toString() |
askGroupName, createGroup, editGroup, getView, isCreateGroupEnabled, isEditGroupEnabled, setView
public static final String APP6A
public IlvApp6aSymbologyTreeViewActions()
public void editSymbology(IlvSDMModel model, IlvApplyObject applier)
model
- The symbol model of the symbologyapplier
- The apply object to be called when the symbology changesIlvSymbologyTreeViewActions.editSymbology(IlvSDMModel,
ilog.views.IlvApplyObject)
public boolean isEditSymbologyEnabled(IlvSDMModel model)
model
- The symbol modeltrue
if the operation is allowedIlvSymbologyTreeViewActions.isEditSymbologyEnabled(IlvSDMModel)
public void actOnSymbologyChanged()
public void createSymbol(IlvSDMModel model, Object group, IlvApplyObject applier)
model.createNode()
to create the new symbol and sets the symbol properties. It adds the new
symbol using model.addObject
and sets its group using
model.setGroup
. Finally, it must call
applier.apply(null, symbol)
to update the symbol tree
panel.
Here is a simple sample implementation:
public void createSymbol(IlvSDMModel model, Object group, IlvApplyObject applier) { Object node = newSymbol("symbol"); model.setObjectProperty(node, "name", "NewSymbol"); model.addObject(node, null, null); model.setGroup(node, group); applier.apply(null, node); }Creates a new default symbol and displays a symbol modification dialog. Adds the symbol in the tree if validated by the user.
model
- The symbol model to which the new symbol will belonggroup
- The group of the new symbol or null
applier
- The apply object to be called when the symbol is creatednewSymbol(String)
public Object newSymbol(String tag)
public void newSymbol(String tag) { return(new IlvDefaultSDMNode(tag)); }
tag
- The tag to be used for the new symbol.APP6A
or this method will return null.public boolean isCreateSymbolEnabled(IlvSDMModel model)
model
- The symbol modeltrue
if the operation is allowedIlvSymbologyTreeViewActions.isCreateSymbolEnabled(IlvSDMModel)
public void editSymbol(IlvSDMModel model, Object node, IlvApplyObject applier)
model
- The symbol model to which the symbol will belong.node
- The symbol model node to be edited.applier
- The apply object to be called when the symbol is changed.IlvSymbologyTreeViewActions.editSymbol(IlvSDMModel,
java.lang.Object, ilog.views.IlvApplyObject)
public boolean isEditSymbolEnabled(IlvSDMModel model)
model
- The symbol modeltrue
if the operation is allowedIlvSymbologyTreeViewActions.isEditSymbolEnabled(IlvSDMModel)
public Object duplicateSymbol(IlvSDMModel model, Object node)
model
- The symbol model to which the new symbol will belongnode
- The symbol model node to be duplicatedIlvSymbologyTreeViewActions.duplicateSymbol(IlvSDMModel,
java.lang.Object)
public boolean isDuplicateSymbolEnabled(IlvSDMModel model)
model
- The symbol modeltrue
if the operation is allowedIlvSymbologyTreeViewActions.isDuplicateSymbolEnabled(IlvSDMModel)
public Object dropSymbolAt(IlvSDMModel model, Object data, Double lonRad, Double latRad)
model
- The model to drop symbol into.data
- Transferable data as per Transferable.getTransferData(java.awt.datatransfer.DataFlavor)
.lonRad
- Latitude in radians matching the mouse cursor for the drop.latRad
- Longitude in radians matching the mouse cursor for the drop.IlvSymbologyTreeViewActions.dropSymbolAt(IlvSDMModel,Object, Double, Double)
public void setLatLonPicker(IlvSymbolLocationEditor locator)
locator
- locator to use.public IlvSymbolLocationEditor getLatLonPicker()
public String toString()
toString
in class Object
Object.toString()
public IlvPersistentObject getPersistentContext()
null
if nothing needs to be persistent.IlvPersistentSDMNodeFactory.getPersistentContext()
public void setPersistentContext(IlvPersistentObject context)
context
- The data that has persisted with the modelIlvPersistentSDMNodeFactory.setPersistentContext(ilog.views.io.IlvPersistentObject)
public boolean isPropertyIgnored(IlvSDMModel model, Object node, String propertyName)
model
- Model impactednode
- Node for which the property needs to be changedpropertyName
- Name of the propertyIlvPersistentSDMNodeFactory.newSymbol(String)
at read time.IlvPersistentSDMNodeFactory.isPropertyIgnored(ilog.views.sdm.IlvSDMModel, java.lang.Object, java.lang.String)
© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.