Package org.goplanit.network.virtual
Class ConjugateConnectoidNodeImpl
- java.lang.Object
-
- org.goplanit.utils.id.IdAbleImpl
-
- org.goplanit.utils.id.ExternalIdAbleImpl
-
- org.goplanit.graph.GraphEntityImpl
-
- org.goplanit.graph.VertexImpl<Edge>
-
- org.goplanit.graph.directed.DirectedVertexImpl<ConjugateEdgeSegment>
-
- org.goplanit.network.virtual.ConjugateConnectoidNodeImpl
-
- All Implemented Interfaces:
Serializable,Comparable<IdAble>,ConjugateDirectedVertex,DirectedVertex,GraphEntity,Vertex,ExternalIdAble,IdAble,ManagedId,ConjugateConnectoidNode
public class ConjugateConnectoidNodeImpl extends DirectedVertexImpl<ConjugateEdgeSegment> implements ConjugateConnectoidNode
Conjugate node representation connected to one or more conjugate (entry and exit) conjugate links.- Author:
- markr
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.goplanit.graph.directed.DirectedVertexImpl
DirectedVertexImpl.EdgeSegmentIterable<ESI extends EdgeSegment>, DirectedVertexImpl.EdgeSegmentIterator<ES extends EdgeSegment>
-
-
Field Summary
Fields Modifier and Type Field Description protected ConnectoidEdgeoriginaloriginal this conjugate represents-
Fields inherited from class org.goplanit.graph.directed.DirectedVertexImpl
entryEdgeSegments, exitEdgeSegments
-
Fields inherited from class org.goplanit.graph.VertexImpl
edges, inputProperties, position
-
Fields inherited from interface org.goplanit.utils.network.virtual.ConjugateConnectoidNode
CONJUGATE_NODE_ID_CLASS
-
Fields inherited from interface org.goplanit.utils.graph.directed.DirectedVertex
getEntryEdgeSegments, getExitEdgeSegments
-
Fields inherited from interface org.goplanit.utils.graph.Vertex
VERTEX_ID_CLASS
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedConjugateConnectoidNodeImpl(ConjugateConnectoidNodeImpl other, boolean deepCopy)Copy constructor, see alsoVertexImplprotectedConjugateConnectoidNodeImpl(ConnectoidEdge original)Conjugate connectoid node constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConjugateConnectoidNodeImpldeepClone()An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call.protected longgenerateAndSetId(IdGroupingToken tokenId)Special case where the id is based on the original link and does not rely on generating based on token when recreating managed ids this should override the default behaviour of generating an id based on tokenCollection<ConjugateDirectedEdge>getEdges()Returns a collection of Edge objects (unmodifiable)ConnectoidEdgegetOriginalEdge()Original edge in original directed graph this conjugate representsConjugateConnectoidNodeImplshallowClone()Create a shallow copy of this entity-
Methods inherited from class org.goplanit.graph.directed.DirectedVertexImpl
getEntryEdgeSegments, getExitEdgeSegments
-
Methods inherited from class org.goplanit.graph.VertexImpl
addEdge, addInputProperty, getInputProperty, getPosition, removeAllEdges, removeEdge, setPosition
-
Methods inherited from class org.goplanit.graph.GraphEntityImpl
generateId, recreateManagedIds, toString
-
Methods inherited from class org.goplanit.utils.id.ExternalIdAbleImpl
getExternalId, getXmlId, setExternalId, setXmlId
-
Methods inherited from class org.goplanit.utils.id.IdAbleImpl
equals, generateAndSetId, getId, hashCode, setId
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.goplanit.utils.network.virtual.ConjugateConnectoidNode
getConjugateNodeIdClass
-
Methods inherited from interface org.goplanit.utils.graph.directed.ConjugateDirectedVertex
getEdgeSegment, getEntryEdgeSegments, getExitEdgeSegments
-
Methods inherited from interface org.goplanit.utils.graph.directed.DirectedVertex
getNumberOfEntryEdgeSegments, getNumberOfExitEdgeSegments, hasEntryEdgeSegments, hasEntrySegment, hasExitEdgeSegments, hasExitSegment
-
Methods inherited from interface org.goplanit.utils.id.ExternalIdAble
appendExternalId, appendExternalId, getExternalId, getIdsAsString, getSplitExternalId, getSplitExternalId, getXmlId, hasExternalId, hasXmlId, setExternalId, setXmlId, setXmlId
-
Methods inherited from interface org.goplanit.utils.id.IdAble
compareTo, getId, idEquals, idHashCode
-
Methods inherited from interface org.goplanit.utils.id.ManagedId
recreateManagedIds, resetChildManagedIdEntities
-
Methods inherited from interface org.goplanit.utils.graph.Vertex
addEdge, addEdges, addInputProperty, getEdges, getIdClass, getInputProperty, getNumberOfEdges, getPosition, hasPosition, isPositionEqual2D, isPositionEqual2D, removeAllEdges, removeEdge, removeEdge, removeEdges, replace, setPosition, transformPosition, validate
-
-
-
-
Field Detail
-
original
protected final ConnectoidEdge original
original this conjugate represents
-
-
Constructor Detail
-
ConjugateConnectoidNodeImpl
protected ConjugateConnectoidNodeImpl(ConnectoidEdge original)
Conjugate connectoid node constructor. Relies on original connectoid edge to sync id with- Parameters:
original- original this conjugate represents
-
ConjugateConnectoidNodeImpl
protected ConjugateConnectoidNodeImpl(ConjugateConnectoidNodeImpl other, boolean deepCopy)
Copy constructor, see alsoVertexImpl- Parameters:
other- to copydeepCopy- when true, create a deep copy, shallow copy otherwise
-
-
Method Detail
-
generateAndSetId
protected long generateAndSetId(IdGroupingToken tokenId)
Special case where the id is based on the original link and does not rely on generating based on token when recreating managed ids this should override the default behaviour of generating an id based on token- Overrides:
generateAndSetIdin classGraphEntityImpl- Parameters:
tokenId- to use for id generation- Returns:
- created and set id
-
getEdges
public Collection<ConjugateDirectedEdge> getEdges()
Returns a collection of Edge objects (unmodifiable)- Specified by:
getEdgesin interfaceConjugateDirectedVertex- Specified by:
getEdgesin interfaceDirectedVertex- Specified by:
getEdgesin interfaceVertex- Overrides:
getEdgesin classDirectedVertexImpl<ConjugateEdgeSegment>- Returns:
- Set of Edge objects
-
shallowClone
public ConjugateConnectoidNodeImpl shallowClone()
Create a shallow copy of this entity- Specified by:
shallowClonein interfaceConjugateConnectoidNode- Specified by:
shallowClonein interfaceGraphEntity- Specified by:
shallowClonein interfaceIdAble- Specified by:
shallowClonein interfaceVertex- Overrides:
shallowClonein classDirectedVertexImpl<ConjugateEdgeSegment>- Returns:
- shallow copy of entity
-
deepClone
public ConjugateConnectoidNodeImpl deepClone()
An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call. To be used with caution if not called by managed id container related code- Specified by:
deepClonein interfaceConjugateConnectoidNode- Specified by:
deepClonein interfaceGraphEntity- Specified by:
deepClonein interfaceIdAble- Specified by:
deepClonein interfaceVertex- Overrides:
deepClonein classDirectedVertexImpl<ConjugateEdgeSegment>- Returns:
- deep copy of entity
-
getOriginalEdge
public ConnectoidEdge getOriginalEdge()
Original edge in original directed graph this conjugate represents- Specified by:
getOriginalEdgein interfaceConjugateDirectedVertex- Returns:
- original edge
-
-