Click or drag to resize

Connector Class

Represents a location on an IConnectable object that another IConnectable object can connect to, via a suitable Connector of its own. When two Connectors are connected, their owning objects must be translated in space so that the respective Connector Location points coincide. Additionally, the orientation Normal may be used to align the two objects.
Inheritance Hierarchy
SystemObject
  Demo3D.VisualsConnector

Namespace:  Demo3D.Visuals
Assembly:  Demo3D.Core (in Demo3D.Core.dll) Version: 10.0.0.6737
Syntax
C#
public class Connector

The Connector type exposes the following members.

Properties
  NameDescription
Public propertyAlignmentStyle
Gets or sets the way in which this connector aligns its parent to other connectors.
Public propertyAllowed
Public propertyAllowsTransferIn
Public propertyAllowsTransferOut
Public propertyAutoConfigure
Public propertyAutoConnect
Public propertyBoundaryOffset
Public propertyCenter
Get the center of the connector for convenient visual point
Public propertyConnectedTo
The first connector this connector is connected to, or null if no connected at all.
Public propertyConnectionWorldLocation
World location of connector.
Public propertyConnectors
All connectors that are connected to this one.
Public propertyControlPointEnabled
Public propertyControlPointSize
Public propertyDefaultAlignmentStyle
Gets the default alignment style for this connector.
Public propertyDisallowed
Public propertyEnd
Public propertyHeightOffset
Public propertyIsConnected
Is this connector connected to other connectors?
Public propertyKeepInBounds
Public propertyLength
Get the length of the connector.
Public propertyMaxAllowedConnections
Optional limit to the number of connectors that this connector can connect to. This is int.MaxValue by default making it effectively unlimited.
Public propertyName
The name of the connector.
Public propertyNormal
Public propertyParent
Public propertyReparentOnConnect
Public propertySnapDistance
Public propertyStart
Public propertyTransferDirection
Public propertyType
Public propertyWorldCenter
Get the center of the connector in world coordinates
Public propertyWorldEnd
Get the end of the connector in world coordinates.
Public propertyWorldNormal
The world normal of the connector.
Public propertyWorldStart
Get the start of the connector in world coordinates.
Top
Methods
  NameDescription
Public methodAddAspectT
Public methodAlignConnectors
Public methodAlignConnectors(ConnectorAlignment)
Public methodAlignConnectors(ConnectorAlignment, Boolean)
Align the parent of this connector to be in line with the connector it is connected to. Modify the transform of the parent of this connector to align to the Normal of the ConnectedTo connector.
Public methodAngularDistanceFrom
Find distance between the world normals as the difference between their world-Y rotations, snapped to 5 degree increments
Public methodCanConnectTo
Indicate if the two Connectors may actually be connected. This allows connectors for different purposes. The GUI may use this to provide visual feedback when the user drags an object near to another object.
Public methodStatic memberClosest
Find the closest connectors between two IConnectable objects (normally Visuals).
Public methodStatic memberConnect(IConnectable, String, IConnectable, String, ConnectorAlignment, Boolean)
Connect two named connectors together with parameters determining whether and how the connectables (Visuals) should move when aligned.
Public methodStatic memberConnect(IConnectable, String, IConnectable, String, Boolean, Boolean)
Connect two named connectors together with parameters determining whether and how the connectables (Visuals) should move when aligned.
Public methodStatic memberConnect(IConnectable, String, IConnectable, String, ConnectorAlignment, Boolean, Boolean)
Connect two named connectors together with parameters determining whether and how the connectables (Visuals) should move when aligned.
Public methodStatic memberConnect(IConnectable, String, IConnectable, String, Boolean, Boolean, Boolean)
Connect two named connectors together with parameters determining whether and how the connectables (Visuals) should move when aligned.
Public methodConnectTo(Connector, ConnectorAlignment)
Connect this and another connector together.
Public methodConnectTo(Connector, Boolean)
Connect two objects together. The method must take care of the placement and orientation of the respective visual objects.
Public methodConnectTo(Connector, Boolean, Boolean)
Connect two objects together. The method must take care of the placement and orientation of the respective visual objects.
Public methodConnectTo(Connector, ConnectorAlignment, Boolean, Boolean)
Connect this and another connector together.
Public methodConnectTo(Connector, Boolean, Boolean, Boolean)
Connect two objects together. The method must take care of the placement and orientation of the respective visual objects.
Public methodConnectTo(Connector, ConnectorAlignment, Boolean, Boolean, Action)
Connect this and another connector together (Only usable from C# scripting, not JScript).
Public methodStatic memberDisconnect
Disconnect a named connector.
Public methodDisconnectAll
Disconnect all connectors
Public methodDisconnectFrom
Disconnect two objects from each other. The orientation is left the same after disconnection.
Public methodDistanceFrom
Calculates the distance of the centers of this connector to the extents (start->end) of another connector.
Public methodFindAspectT
Public methodIsConnectedTo(Connector)
Public methodIsConnectedTo(Visual)
Public methodRemoveAspectT
Public methodToString
Connected "name:visual" string.
(Overrides ObjectToString.)
Public methodToVisualLocation
The center of the connector as a VisualLocation.
Top
Events
  NameDescription
Public eventAfterDisconnectedListeners
Called just after this connector is disconnected from.
Public eventConnectedListeners
Called when this connector is connected to.
Public eventDisconnectedListeners
Called just before this connector is disconnected from.
Top
See Also