NetTopologySuite
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Pages
NetTopologySuite.GeometriesGraph.Label Class Reference

A Label indicates the topological relationship of a component of a topology graph to a given Geometry. This class supports labels for relationships to two Geometrys, which is sufficient for algorithms for binary operations. Topology graphs support the concept of labeling nodes and edges in the graph. The label of a node or edge specifies its topological relationship to one or more geometries. (In fact, since NTS operations have only two arguments labels are required for only two geometries). A label for a node or edge has one or two elements, depending on whether the node or edge occurs in one or both of the input Geometrys. Elements contain attributes which categorize the topological location of the node or edge relative to the parent Geometry; that is, whether the node or edge is in the interior, boundary or exterior of the Geometry. Attributes have a value from the set {Interior, Boundary, Exterior}. In a node each element has a single attribute On. For an edge each element has a triplet of attributes Left, On, Right. It is up to the client code to associate the 0 and 1 TopologyLocations with specific geometries. More...

Public Member Functions

 Label (Location onLoc)
 Construct a Label with a single location for both Geometries. Initialize the locations to Null. More...
 
 Label (int geomIndex, Location onLoc)
 Construct a Label with a single location for both Geometries. Initialize the location for the Geometry index. More...
 
 Label (Location onLoc, Location leftLoc, Location rightLoc)
 Construct a Label with On, Left and Right locations for both Geometries. Initialize the locations for both Geometries to the given values. More...
 
 Label (int geomIndex, Location onLoc, Location leftLoc, Location rightLoc)
 Construct a Label with On, Left and Right locations for both Geometries. Initialize the locations for the given Geometry index. More...
 
 Label (Label lbl)
 Construct a Label with the same values as the argument Label. More...
 
void Flip ()
 
Location GetLocation (int geomIndex, Positions posIndex)
 
Location GetLocation (int geomIndex)
 
void SetLocation (int geomIndex, Positions posIndex, Location _location)
 
void SetLocation (int geomIndex, Location _location)
 
void SetAllLocations (int geomIndex, Location _location)
 
void SetAllLocationsIfNull (int geomIndex, Location _location)
 
void SetAllLocationsIfNull (Location _location)
 
void Merge (Label lbl)
 Merge this label with another one. Merging updates any null attributes of this label with the attributes from lbl. More...
 
bool IsNull (int geomIndex)
 
bool IsAnyNull (int geomIndex)
 
bool IsArea ()
 
bool IsArea (int geomIndex)
 
bool IsLine (int geomIndex)
 
bool IsEqualOnSide (Label lbl, int side)
 
bool AllPositionsEqual (int geomIndex, Location loc)
 
void ToLine (int geomIndex)
 Converts one GeometryLocation to a Line location. More...
 
override string ToString ()
 

Static Public Member Functions

static Label ToLineLabel (Label label)
 Converts a Label to a Line label (that is, one with no side Location). More...
 

Properties

int GeometryCount [get]
 

Detailed Description

A Label indicates the topological relationship of a component of a topology graph to a given Geometry. This class supports labels for relationships to two Geometrys, which is sufficient for algorithms for binary operations. Topology graphs support the concept of labeling nodes and edges in the graph. The label of a node or edge specifies its topological relationship to one or more geometries. (In fact, since NTS operations have only two arguments labels are required for only two geometries). A label for a node or edge has one or two elements, depending on whether the node or edge occurs in one or both of the input Geometrys. Elements contain attributes which categorize the topological location of the node or edge relative to the parent Geometry; that is, whether the node or edge is in the interior, boundary or exterior of the Geometry. Attributes have a value from the set {Interior, Boundary, Exterior}. In a node each element has a single attribute On. For an edge each element has a triplet of attributes Left, On, Right. It is up to the client code to associate the 0 and 1 TopologyLocations with specific geometries.

Constructor & Destructor Documentation

NetTopologySuite.GeometriesGraph.Label.Label ( Location  onLoc)

Construct a Label with a single location for both Geometries. Initialize the locations to Null.

Parameters
onLoc
NetTopologySuite.GeometriesGraph.Label.Label ( int  geomIndex,
Location  onLoc 
)

Construct a Label with a single location for both Geometries. Initialize the location for the Geometry index.

Parameters
geomIndex
onLoc
NetTopologySuite.GeometriesGraph.Label.Label ( Location  onLoc,
Location  leftLoc,
Location  rightLoc 
)

Construct a Label with On, Left and Right locations for both Geometries. Initialize the locations for both Geometries to the given values.

Parameters
onLoc
leftLoc
rightLoc
NetTopologySuite.GeometriesGraph.Label.Label ( int  geomIndex,
Location  onLoc,
Location  leftLoc,
Location  rightLoc 
)

Construct a Label with On, Left and Right locations for both Geometries. Initialize the locations for the given Geometry index.

Parameters
geomIndex
onLoc
leftLoc
rightLoc
NetTopologySuite.GeometriesGraph.Label.Label ( Label  lbl)

Construct a Label with the same values as the argument Label.

Parameters
lbl

Member Function Documentation

bool NetTopologySuite.GeometriesGraph.Label.AllPositionsEqual ( int  geomIndex,
Location  loc 
)

Parameters
geomIndex
loc
Returns
void NetTopologySuite.GeometriesGraph.Label.Flip ( )

Location NetTopologySuite.GeometriesGraph.Label.GetLocation ( int  geomIndex,
Positions  posIndex 
)

Parameters
geomIndex
posIndex
Returns
Location NetTopologySuite.GeometriesGraph.Label.GetLocation ( int  geomIndex)

Parameters
geomIndex
Returns
bool NetTopologySuite.GeometriesGraph.Label.IsAnyNull ( int  geomIndex)

Parameters
geomIndex
Returns
bool NetTopologySuite.GeometriesGraph.Label.IsArea ( )

Returns
bool NetTopologySuite.GeometriesGraph.Label.IsArea ( int  geomIndex)

Parameters
geomIndex
Returns
bool NetTopologySuite.GeometriesGraph.Label.IsEqualOnSide ( Label  lbl,
int  side 
)

Parameters
lbl
side
Returns
bool NetTopologySuite.GeometriesGraph.Label.IsLine ( int  geomIndex)

Parameters
geomIndex
Returns
bool NetTopologySuite.GeometriesGraph.Label.IsNull ( int  geomIndex)

Parameters
geomIndex
Returns
void NetTopologySuite.GeometriesGraph.Label.Merge ( Label  lbl)

Merge this label with another one. Merging updates any null attributes of this label with the attributes from lbl.

Parameters
lbl
void NetTopologySuite.GeometriesGraph.Label.SetAllLocations ( int  geomIndex,
Location  _location 
)

Parameters
geomIndex
_location
void NetTopologySuite.GeometriesGraph.Label.SetAllLocationsIfNull ( int  geomIndex,
Location  _location 
)

Parameters
geomIndex
_location
void NetTopologySuite.GeometriesGraph.Label.SetAllLocationsIfNull ( Location  _location)

Parameters
_location
void NetTopologySuite.GeometriesGraph.Label.SetLocation ( int  geomIndex,
Positions  posIndex,
Location  _location 
)

Parameters
geomIndex
posIndex
_location
void NetTopologySuite.GeometriesGraph.Label.SetLocation ( int  geomIndex,
Location  _location 
)

Parameters
geomIndex
_location
void NetTopologySuite.GeometriesGraph.Label.ToLine ( int  geomIndex)

Converts one GeometryLocation to a Line location.

Parameters
geomIndex
static Label NetTopologySuite.GeometriesGraph.Label.ToLineLabel ( Label  label)
static

Converts a Label to a Line label (that is, one with no side Location).

Parameters
labelLabel to convert.
Returns
Label as Line label.
override string NetTopologySuite.GeometriesGraph.Label.ToString ( )

Returns

Property Documentation

int NetTopologySuite.GeometriesGraph.Label.GeometryCount
get


The documentation for this class was generated from the following file: