Search Results for

    Show / Hide Table of Contents

    Class Node

    A node in a PlanarGraph is a location where 0 or more Edges meet. A node is connected to each of its incident Edges via an outgoing DirectedEdge. Some clients using a PlanarGraph may want to subclass Node to add their own application-specific data and methods.

    Inheritance
    object
    GraphComponent
    Node
    Inherited Members
    GraphComponent.SetVisited(IEnumerator, bool)
    GraphComponent.SetMarked(IEnumerator, bool)
    GraphComponent.GetComponentWithVisitedState(IEnumerator, bool)
    GraphComponent.IsVisited
    GraphComponent.Visited
    GraphComponent.IsMarked
    GraphComponent.Marked
    GraphComponent.Data
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: NetTopologySuite.Planargraph
    Assembly: NetTopologySuite.dll
    Syntax
    public class Node : GraphComponent

    Constructors

    | Edit this page View Source

    Node(Coordinate)

    Constructs a Node with the given location.

    Declaration
    public Node(Coordinate pt)
    Parameters
    Type Name Description
    Coordinate pt
    | Edit this page View Source

    Node(Coordinate, DirectedEdgeStar)

    Constructs a Node with the given location and collection of outgoing DirectedEdges.

    Declaration
    public Node(Coordinate pt, DirectedEdgeStar deStar)
    Parameters
    Type Name Description
    Coordinate pt
    DirectedEdgeStar deStar

    Fields

    | Edit this page View Source

    deStar

    The collection of DirectedEdges that leave this Node.

    Declaration
    protected DirectedEdgeStar deStar
    Field Value
    Type Description
    DirectedEdgeStar
    | Edit this page View Source

    pt

    The location of this Node.

    Declaration
    protected Coordinate pt
    Field Value
    Type Description
    Coordinate

    Properties

    | Edit this page View Source

    Coordinate

    Returns the location of this Node.

    Declaration
    public Coordinate Coordinate { get; }
    Property Value
    Type Description
    Coordinate
    | Edit this page View Source

    Degree

    Returns the number of edges around this Node.

    Declaration
    public int Degree { get; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    IsRemoved

    Tests whether this component has been removed from its containing graph.

    Declaration
    public override bool IsRemoved { get; }
    Property Value
    Type Description
    bool
    Overrides
    GraphComponent.IsRemoved
    | Edit this page View Source

    OutEdges

    Returns the collection of DirectedEdges that leave this Node.

    Declaration
    public DirectedEdgeStar OutEdges { get; }
    Property Value
    Type Description
    DirectedEdgeStar

    Methods

    | Edit this page View Source

    AddOutEdge(DirectedEdge)

    Adds an outgoing DirectedEdge to this Node.

    Declaration
    public void AddOutEdge(DirectedEdge de)
    Parameters
    Type Name Description
    DirectedEdge de
    | Edit this page View Source

    GetEdgesBetween(Node, Node)

    Returns all Edges that connect the two nodes (which are assumed to be different).

    Declaration
    public static IList<DirectedEdge> GetEdgesBetween(Node node0, Node node1)
    Parameters
    Type Name Description
    Node node0
    Node node1
    Returns
    Type Description
    IList<DirectedEdge>
    | Edit this page View Source

    GetIndex(Edge)

    Returns the zero-based index of the given Edge, after sorting in ascending order by angle with the positive x-axis.

    Declaration
    public int GetIndex(Edge edge)
    Parameters
    Type Name Description
    Edge edge
    Returns
    Type Description
    int
    | Edit this page View Source

    Remove(DirectedEdge)

    Removes a DirectedEdge incident on this node. Does not change the state of the directed edge.

    Declaration
    public void Remove(DirectedEdge de)
    Parameters
    Type Name Description
    DirectedEdge de
    | Edit this page View Source

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    object.ToString()
    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX