com.esri.arcgis.schematic
Class INgNodeProxy

java.lang.Object
  extended by com.esri.arcgis.interop.Dispatch
      extended by com.esri.arcgis.schematic.INgNodeProxy
All Implemented Interfaces:
INgNode, Externalizable, Serializable

public class INgNodeProxy
extends com.esri.arcgis.interop.Dispatch
implements INgNode, Serializable

Provides access to members that control the graphic node.

Description

A node is a vertex in a network graph. It is represented by a symbol and may be assigned various graphic (color, fill style, and so forth), geometric (scaling, rotation, and so forth), or visual (visibility, highlighting, and so forth) attributes. The common properties of a node are stored and defined by its related node element type. Nodes can have geographic, semigeographic, or graph coordinates. The coordinate system is independent of the graphic display window. Several nodes may be aligned along the same horizontal or vertical axis. If the network is thickly populated, several nodes may be compacted into a single compaction node. Two nodes can have a binding—logical and hierarchical—relationship, which means that certain rules will apply when these nodes are manipulated (for example, moving or deleting a parent node will cause the associated child node to be moved or deleted accordingly).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

See Also:
INgElement, INgNodeOnLink, ISchematicNode, Serialized Form

Field Summary
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF, E
 
Constructor Summary
  INgNodeProxy()
           
  INgNodeProxy(Object obj)
           
protected INgNodeProxy(Object obj, String iid)
           
 
Method Summary
 void addListener(String iidStr, Object theListener, Object theSource)
           
 Object getCurrentEffect(int effect)
          Returns the current 'effValue' value for the node effect 'effect' (see esriNgNodeEffect).
 INgDiagram getDiagram()
          Diagram that contains the node.
 Object getEffect(int effect)
          Returns the effect 'effect' set for the node (see esriNgNodeEffect).
 INgElementType getElementType()
          Element type that implements the node.
 INgLinks getIncidentLinks(int endPointType)
          Returns the list of the node's incident links.
 double getInitialRotation()
          Initial rotation angle of the node.
 String getName()
          Name of the node.
 boolean getPortPosition(INgView view, int numPort, int type, INgPoint[] point)
          Returns the position 'point' of the port 'numPort', of type 'type' (see esriNgPortType) associated with the node in the view 'view'.
 double getX()
          X Cartesian coordinate of the node.
 double getY()
          Y Cartesian coordinate of the node.
 INgPoint INgNode_getInitialPosition()
          Initial position of the node.
 boolean isEffectSet(int effect)
          Indicates if the effect 'effect' related to the node is set (see esriNgNodeEffect).
 void move(double x, double y, int computeMode, int moveMode)
          Moves the node to the (X,Y) relative or absolute position.
 void readExternal(ObjectInput in)
           
 void removeEffect(int effect)
          Removes the effect or restores the default effect 'effect' set for the node (see esriNgNodeEffect).
 void removeListener(String iidStr, Object theListener)
           
 void removeSubSymbolEffect(String subName, int effect)
          Removes the effect 'effect' set for the sub-symbol named 'subName' that composes the symbol used to represent the node (see esriNgSubSymbolEffect).
 void restoreInitialPosition(int modeIfNotSet, int modeIfSet)
          Restores the node to its initially defined position.
 void setEffect(int effect, Object effValue)
          Modifies the effect 'effect' set for the node (see esriNgNodeEffect).
 void setInitialPosition(INgPoint pVal)
          Initial position of the node.
 void setInitialRotation(double pVal)
          Initial rotation angle of the node.
 void setSubSymbolEffect(String subName, int effect, Object effValue)
          Sets the effect 'effect' for the sub-symbol named 'subName' that composes the symbol used to represent the node (see esriNgSubSymbolEffect).
 void writeExternal(ObjectOutput out)
           
 
Methods inherited from class com.esri.arcgis.interop.Dispatch
bindUsingMoniker, constructVtblPosTable, convertToNative, cookieForListener, createDispatch, createObjrefMonikerDisplayName, equals, getActiveObject, getActiveObject, getDefaultProperty, getDispatchIdOfName, getLastErrorCode, getMtsObjectContext, getObjRef, getPropertyByName, getPropertyByName, getVtblPos, hashCode, initDispatch, invoke, invokeMethodByName, invokeMethodByName, invokeMethodByName, invokePropertyGetByName, invokePropertyPutByName, invokePropertyPutByRefByName, isNativeMode, isObjRef, queryInterface, release, setNativeMode, setPropertyByName, toString, vtblInvoke
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

INgNodeProxy

public INgNodeProxy()

INgNodeProxy

public INgNodeProxy(Object obj)
             throws IOException
Throws:
IOException

INgNodeProxy

protected INgNodeProxy(Object obj,
                       String iid)
                throws IOException
Throws:
IOException
Method Detail

addListener

public void addListener(String iidStr,
                        Object theListener,
                        Object theSource)
                 throws IOException
Overrides:
addListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

removeListener

public void removeListener(String iidStr,
                           Object theListener)
                    throws IOException
Overrides:
removeListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

getElementType

public INgElementType getElementType()
                              throws IOException,
                                     AutomationException
Element type that implements the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getElementType in interface INgNode
Returns:
A reference to a com.esri.arcgis.schematic.INgElementType
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

public String getName()
               throws IOException,
                      AutomationException
Name of the node.

Description

This name is defined when the node is created:

- either by triggering the INgDiagram CreateNode method or INgProjectEvents NameOfDigitNode event in the code,

- or when the node element type is created through ArcGIS Schematics Designer.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getName in interface INgNode
Returns:
The pVal
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getX

public double getX()
            throws IOException,
                   AutomationException
X Cartesian coordinate of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getX in interface INgNode
Returns:
The pVal
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getY

public double getY()
            throws IOException,
                   AutomationException
Y Cartesian coordinate of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getY in interface INgNode
Returns:
The pVal
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDiagram

public INgDiagram getDiagram()
                      throws IOException,
                             AutomationException
Diagram that contains the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getDiagram in interface INgNode
Returns:
A reference to a com.esri.arcgis.schematic.INgDiagram
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

move

public void move(double x,
                 double y,
                 int computeMode,
                 int moveMode)
          throws IOException,
                 AutomationException
Moves the node to the (X,Y) relative or absolute position.

Description

The values taken by the moveMode parameter are detailed in esriNgMoveMode

The default value for moveMode is esriNgAbsoluteMove, which means that, by default, the node is moved to the (X,Y) absolute position.

Moving the node causes the connected links to be recomputed. The computeMode parameter tells Schematics how these links are to be redrawn (see esriNgComputeLinkPointMode list).

By default, link points are kept, which means that the default computeMode parameter is esriNgKeepLinkPoints

Remarks

If there are schematic relations between schematics objects contained in a schematic diagram, it’s the developer responsibility to call the appropriate ISchematicRelationController or ISchematicRelationManager methods for the related objects as the containers to be automatically redrawn when he uses the INgNode:Move method. Please also note that programming the relations redraw on the INgProjectEvents::OnMoveElements or ISchematicRelationControllerEvent::OnMoveElements events will be completely unuseful because these events are only triggered when schematic elements are moved using the GUI tools; that is when end-users move schematic elements using the mouse or the keyboard arrows. So when elements are moved by programming using any "Move" method, the custom code specified on these events will be not fired. In this case, you must either force the redraw at the end of the move operations sequences in your custom procedure or customize the SchematicAlgorithmEvents::AfterExecuteAlgorithm event (when the "Move" methods are called during a custom algorithm).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
move in interface INgNode
Parameters:
x - The x (in)
y - The y (in)
computeMode - A com.esri.arcgis.schematic.esriNgComputeLinkPointMode constant (in, optional, pass 2059 if not required)
moveMode - A com.esri.arcgis.schematic.esriNgMoveMode constant (in, optional, pass 2085 if not required)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgProjectEvents.onMoveElements(com.esri.arcgis.schematic.INgProjectEventsOnMoveElementsEvent)

getIncidentLinks

public INgLinks getIncidentLinks(int endPointType)
                          throws IOException,
                                 AutomationException
Returns the list of the node's incident links.

Description

The endPointType parameter is used to specify whether you want to obtain:

- A list of the links having that node as origin node only (endPointType = esriNgOriginNode),

- A list of the links having that node as end node only (endPointType=esriNgExtremityNode),

- A list of all the links that are incident to the node (endPointType=esriNgOriginAndExtremityNode).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getIncidentLinks in interface INgNode
Parameters:
endPointType - A com.esri.arcgis.schematic.esriNgEndPoint constant (in, optional, pass -1 if not required)
Returns:
A reference to a com.esri.arcgis.schematic.INgLinks
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgDiagram

getEffect

public Object getEffect(int effect)
                 throws IOException,
                        AutomationException
Returns the effect 'effect' set for the node (see esriNgNodeEffect).

Description

Only the effects set by calling the SetEffect method on the INgNode interface in the project code will be returned when using the GetEffect method. If the GetEffect method returns no value, the GetCurrentEffect method can return a value. The effect returned in this case can have been set either when defining the element type effects or the properties effects related to the link.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getEffect in interface INgNode
Parameters:
effect - A com.esri.arcgis.schematic.esriNgNodeEffect constant (in)
Returns:
A Variant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode.setEffect(int, java.lang.Object), INgNode.getCurrentEffect(int), INgNode.isEffectSet(int), INgNode.removeEffect(int)

setEffect

public void setEffect(int effect,
                      Object effValue)
               throws IOException,
                      AutomationException
Modifies the effect 'effect' set for the node (see esriNgNodeEffect).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setEffect in interface INgNode
Parameters:
effect - A com.esri.arcgis.schematic.esriNgNodeEffect constant (in)
effValue - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode.getEffect(int), INgNode.getCurrentEffect(int), INgNode.isEffectSet(int), INgNode.removeEffect(int)

removeEffect

public void removeEffect(int effect)
                  throws IOException,
                         AutomationException
Removes the effect or restores the default effect 'effect' set for the node (see esriNgNodeEffect).

Description

Note that when removing an effect that is always set, the node default effect value is automatically restored; and removing an effect that is not set by default, really removes the node effect.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
removeEffect in interface INgNode
Parameters:
effect - A com.esri.arcgis.schematic.esriNgNodeEffect constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode.setEffect(int, java.lang.Object), INgNode.getEffect(int), INgNode.getCurrentEffect(int), INgNode.isEffectSet(int)

isEffectSet

public boolean isEffectSet(int effect)
                    throws IOException,
                           AutomationException
Indicates if the effect 'effect' related to the node is set (see esriNgNodeEffect).

Description

By default, Schematics automatically sets default values for some node effects (see the List of default node effects, below). For all these effects, the IsEffectSet method returns True. For the others effects (those that are not automatically set by default), the IsEffectSet method returns True only if the effect has been set by calling the INgNode SetEffect method in the project.

Note that even if the IsEffectSet method returns False for a given effect (for example, esriNgNodeXScaling), the GetCurrentEffect method can returns a value! GetCurrentEffect returns the current effect positioned for the node. This effect cans have been set:

- Either when the associated element type effects have been defined,

- Or when the graphic effects for its related properties have been defined.


List of the default node effect values

esriNgNodeDetectability: esriNgDetectable.

esriNgNodeHighlightedState: esriNgNotHighlighted

esriNgNodeMobility: esriNgMovable.

esriNgNodePriority: 201 or more

esriNgNodeResizability: esriNgResizable

esriNgNodeSelectability: esriNgSelectable

esriNgNodeVisibility: esriNgVisible


For more details, see Node Effects Constants Definition.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
isEffectSet in interface INgNode
Parameters:
effect - A com.esri.arcgis.schematic.esriNgNodeEffect constant (in)
Returns:
The isSet
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode.setEffect(int, java.lang.Object), INgNode.getEffect(int), INgNode.getCurrentEffect(int), INgNode.removeEffect(int)

setSubSymbolEffect

public void setSubSymbolEffect(String subName,
                               int effect,
                               Object effValue)
                        throws IOException,
                               AutomationException
Sets the effect 'effect' for the sub-symbol named 'subName' that composes the symbol used to represent the node (see esriNgSubSymbolEffect).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setSubSymbolEffect in interface INgNode
Parameters:
subName - The subName (in)
effect - A com.esri.arcgis.schematic.esriNgSubSymbolEffect constant (in)
effValue - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode, INgNode.removeSubSymbolEffect(String, int)

removeSubSymbolEffect

public void removeSubSymbolEffect(String subName,
                                  int effect)
                           throws IOException,
                                  AutomationException
Removes the effect 'effect' set for the sub-symbol named 'subName' that composes the symbol used to represent the node (see esriNgSubSymbolEffect).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
removeSubSymbolEffect in interface INgNode
Parameters:
subName - The subName (in)
effect - A com.esri.arcgis.schematic.esriNgSubSymbolEffect constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode, INgNode.setSubSymbolEffect(String, int, java.lang.Object)

getPortPosition

public boolean getPortPosition(INgView view,
                               int numPort,
                               int type,
                               INgPoint[] point)
                        throws IOException,
                               AutomationException
Returns the position 'point' of the port 'numPort', of type 'type' (see esriNgPortType) associated with the node in the view 'view'.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getPortPosition in interface INgNode
Parameters:
view - A reference to a com.esri.arcgis.schematic.INgView (in)
numPort - The numPort (in)
type - A com.esri.arcgis.schematic.esriNgPortType constant (in)
point - A reference to a com.esri.arcgis.schematic.INgPoint (out: use single element array)
Returns:
The found
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

INgNode_getInitialPosition

public INgPoint INgNode_getInitialPosition()
                                    throws IOException,
                                           AutomationException
Initial position of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
INgNode_getInitialPosition in interface INgNode
Returns:
A reference to a com.esri.arcgis.schematic.INgPoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setInitialPosition

public void setInitialPosition(INgPoint pVal)
                        throws IOException,
                               AutomationException
Initial position of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setInitialPosition in interface INgNode
Parameters:
pVal - A reference to a com.esri.arcgis.schematic.INgPoint (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getInitialRotation

public double getInitialRotation()
                          throws IOException,
                                 AutomationException
Initial rotation angle of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getInitialRotation in interface INgNode
Returns:
The pVal
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setInitialRotation

public void setInitialRotation(double pVal)
                        throws IOException,
                               AutomationException
Initial rotation angle of the node.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setInitialRotation in interface INgNode
Parameters:
pVal - The pVal (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

restoreInitialPosition

public void restoreInitialPosition(int modeIfNotSet,
                                   int modeIfSet)
                            throws IOException,
                                   AutomationException
Restores the node to its initially defined position.

Description

If the node was positioned using its database coordinates, the modelfSet parameter must be specified so that its position is modified and the modelfNotSet parameter can be ignored.

If the node was positioned without using its database coordinates, then the modelfNotSet parameter must be specified and the modelfSet parameter can be ignored.

At all events,

- The esriNgDB parameter value causes the node to be repositioned based on its database coordinate values (if modeIfSet is used) or to be placed on the 0, 0 coordinate value position (if modeIfNotSet is used).

- The esriNgCenter parameter value causes the node to be relocated on a position averaging the current position of the neighboring elements (modeIfSet case or modeIfNotSet case)

- The esriNgNothing parameter value does not cause the node to be relocated (modeIfSet case or modeIfNotSet case). The node retains its current position.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
restoreInitialPosition in interface INgNode
Parameters:
modeIfNotSet - A com.esri.arcgis.schematic.esriNgInitialPositionMode constant (in, optional, pass 0 if not required)
modeIfSet - A com.esri.arcgis.schematic.esriNgInitialPositionMode constant (in, optional, pass 0 if not required)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgDiagram.restoreInitialPosition(int, int), INgNode.setInitialPosition(com.esri.arcgis.schematic.INgPoint)

getCurrentEffect

public Object getCurrentEffect(int effect)
                        throws IOException,
                               AutomationException
Returns the current 'effValue' value for the node effect 'effect' (see esriNgNodeEffect).

Description

Current effect set for a node can come from its associated element type effects definition, its related properties effects definition, its own effects definition.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getCurrentEffect in interface INgNode
Parameters:
effect - A com.esri.arcgis.schematic.esriNgNodeEffect constant (in)
Returns:
A Variant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
INgNode.setEffect(int, java.lang.Object), INgNode.getEffect(int), INgNode.isEffectSet(int), INgNode.removeEffect(int)

writeExternal

public void writeExternal(ObjectOutput out)
                   throws IOException
Specified by:
writeExternal in interface Externalizable
Overrides:
writeExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

readExternal

public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
Specified by:
readExternal in interface Externalizable
Overrides:
readExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException
ClassNotFoundException