GH_WireTopology

References
Represents the topological data for a single connector wire.

Constructors

GH_WireTopology

#
public GH_WireTopology()
Blank constructor.

GH_WireTopology

#
public GH_WireTopology(Guid source_id, Guid target_id, int source_index)
Default constructor.
source_id (Guid)Instance ID of source parameter.
target_id (Guid)Instance ID of target parameter.
source_index (int)Index of source parameter in target Sources list.

GH_WireTopology

#
public GH_WireTopology(Guid source_id, Guid target_id)
Index-less constructor.
source_id (Guid)Instance ID of source parameter.
target_id (Guid)Instance ID of target parameter.

GH_WireTopology

#
public GH_WireTopology(IGH_Param source, IGH_Param target)
Utility constructor, takes two parameters and figures out the index all by itself.
source (IGH_Param)Source parameter.
target (IGH_Param)Target parameter.
InvalidOperationExceptionThrown if the source is not an actual source of the target.

GH_WireTopology

#
public GH_WireTopology(IGH_Param target, int index)
Utility constructor, figures out the source all by itself.
target (IGH_Param)Target parameter.
index (int)Index of source to extract.

Properties

SourceIndex

#
public int SourceIndex { get; }
Gets the index of the source parameter in the Sources list of the target parameter.

SourceParameterID

#
public Guid SourceParameterID { get; }
Gets the instance ID of the source parameter.

TargetParameterID

#
public Guid TargetParameterID { get; }
Gets the instance ID of the target parameter.

ValidIndex

#
public bool ValidIndex { get; }
Gets a value indicating whether or not the source index is a valid number.

Methods

DestroyConnection

#
public void DestroyConnection(GH_Document doc)
Destroys the topological connector wire if it exists.
doc (GH_Document)Document which contains the source and parameter indices.

EnsureConnection

#
public void EnsureConnection(GH_Document doc)
Creates the topological connector wire if it doesn't already exist.
doc (GH_Document)Document which contains the source and parameter indices.

Read

#
public bool Read(GH_IReader reader)
reader (GH_IReader)
Read

Write

#
public bool Write(GH_IWriter writer)
writer (GH_IWriter)
Write