Class SpatialNode
This class implements the ISpatialNode for the ISpatialGraphEnvironment
to represent the vertices within the environment.
  
  
  Implements
System.IEquatable<AbstractGraphElement>
    
    
    
    System.Collections.Generic.IEqualityComparer<IGraphEntity>
    
  Inherited Members
      System.Object.Equals(System.Object, System.Object)
    
    
      System.Object.GetType()
    
    
      System.Object.MemberwiseClone()
    
    
      System.Object.ReferenceEquals(System.Object, System.Object)
    
    
      System.Object.ToString()
    
  Namespace: Mars.Components.Environments
Assembly: Mars.Components.dll
Syntax
[MessagePackObject(true)]
public class SpatialNode : AbstractGraphElement, IEquatable<AbstractGraphElement>, ISpatialNode, INode<ISpatialEdge, ISpatialNode>, IGraphEntity, IEqualityComparer<IGraphEntity>, IPositionable
  Constructors
| Improve this Doc View SourceSpatialNode(Int32, Position, IDictionary<String, Object>)
Creates a new SpatialNode and assigns them the given  .
  
  Declaration
[SerializationConstructor]
public SpatialNode(int index, Position position, IDictionary<string, object> attributes)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.Int32 | index | The key used to identify this object. | 
| Position | position | The coordinate where this node is located. | 
| System.Collections.Generic.IDictionary<System.String, System.Object> | attributes | The data dictionary. | 
SpatialNode(Int32)
Creates a new ISpatialNode with a given  
as identifier and position (0,0) as source.
  
  Declaration
public SpatialNode(int key)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.Int32 | key | The key used to identify | 
Properties
| Improve this Doc View SourceDirections
This class implements the ISpatialNode for the ISpatialGraphEnvironment
to represent the vertices within the environment.
  
  Declaration
public IDictionary<(int, int), DirectionType> Directions { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Collections.Generic.IDictionary<System.ValueTuple<System.Int32, System.Int32>, DirectionType> | 
IncomingEdges
Gets the collection of all incoming edges,
targeting into this node.
  
  Declaration
[IgnoreMember]
public IDictionary<int, ISpatialEdge> IncomingEdges { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Collections.Generic.IDictionary<System.Int32, ISpatialEdge> | 
IncomingModalities
Set of all SpatialModalityTypes that incoming edges support.
  
  Declaration
[IgnoreMember]
public ISet<SpatialModalityType> IncomingModalities { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Collections.Generic.ISet<SpatialModalityType> | 
NodeGuard
NodeGuard that controls the transition of agents between edges
  
  Declaration
[IgnoreMember]
public INodeGuard NodeGuard { get; set; }
  Property Value
| Type | Description | 
|---|---|
| INodeGuard | 
OutgoingEdges
Set of all edges starting from the current edge
(directed graph)
  
  Declaration
[IgnoreMember]
public IDictionary<int, ISpatialEdge> OutgoingEdges { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Collections.Generic.IDictionary<System.Int32, ISpatialEdge> | 
OutgoingModalities
Set of all SpatialModalityTypes that outgoing edges support.
  
  Declaration
[IgnoreMember]
public ISet<SpatialModalityType> OutgoingModalities { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Collections.Generic.ISet<SpatialModalityType> | 
Position
Gets or sets the contained spatial position of an object.
  
  Declaration
public Position Position { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Position | 
Methods
| Improve this Doc View SourceAddIncomingEdge(ISpatialEdge)
Adds an edge to the incoming set of this node.
  
  Declaration
public void AddIncomingEdge(ISpatialEdge edge)
  Parameters
| Type | Name | Description | 
|---|---|---|
| ISpatialEdge | edge | The edge to add with incoming direction. | 
AddOutgoingEdge(ISpatialEdge)
Adds an edge to the outgoing set of this node.
  
  Declaration
public void AddOutgoingEdge(ISpatialEdge edge)
  Parameters
| Type | Name | Description | 
|---|---|---|
| ISpatialEdge | edge | The edge to add with outgoing direction. | 
GetDirection(ISpatialEdge, ISpatialEdge)
This class implements the ISpatialNode for the ISpatialGraphEnvironment
to represent the vertices within the environment.
  
  Declaration
public DirectionType GetDirection(ISpatialEdge incoming, ISpatialEdge outgoing)
  Parameters
| Type | Name | Description | 
|---|---|---|
| ISpatialEdge | incoming | |
| ISpatialEdge | outgoing | 
Returns
| Type | Description | 
|---|---|
| DirectionType | 
Merge(NodeData)
This class implements the ISpatialNode for the ISpatialGraphEnvironment
to represent the vertices within the environment.
  
  Declaration
public void Merge(NodeData nodeData)
  Parameters
| Type | Name | Description | 
|---|---|---|
| NodeData | nodeData | 
Implements
      System.IEquatable<T>
  
  
  
  
  
      System.Collections.Generic.IEqualityComparer<T>