CVB.Net 14.0
Polygon3D< T > Struct Template Reference

A polygon in 3D space. More...

Public Member Functions

 Polygon3D (T[] points)
 Constructor. More...
 
override bool Equals (object obj)
 Indicates whether this instance and the given obj are equal. More...
 
bool Equals (Polygon3D< T > obj)
 Indicates whether this instance and the given obj are equal. More...
 
override int GetHashCode ()
 Returns the hash code for this instance. More...
 

Static Public Member Functions

static bool operator== (Polygon3D< T > left, Polygon3D< T > right)
 Equality comparison operator. More...
 
static bool operator!= (Polygon3D< T > left, Polygon3D< T > right)
 Inequality comparison operator. More...
 

Properties

ReadOnlyCollection< T > Points [get]
 The points of the polygon.
 

Detailed Description

A polygon in 3D space.

Template Parameters
TType of the points. Use Point3Dd or Point3Df here.
Type Constraints
T :struct 

Constructor & Destructor Documentation

◆ Polygon3D()

Polygon3D ( T[]  points)

Constructor.

Parameters
pointsPoints of the polygon.
Exceptions
ArgumentExceptionWhen the type of the points contained in points is not Point3Dd or Point3Df or points contains less than 3 points.
ArgumentNullExceptionWhen points is null.

Member Function Documentation

◆ Equals() [1/2]

override bool Equals ( object  obj)

Indicates whether this instance and the given obj are equal.

Parameters
objObject to compare to.
Returns
True if obj and this instance are the same type and represent the same value; otherwise, false.

◆ Equals() [2/2]

bool Equals ( Polygon3D< T >  obj)

Indicates whether this instance and the given obj are equal.

Parameters
objObject to compare to.
Returns
True if obj and this instance represent the same value; otherwise, false.

◆ GetHashCode()

override int GetHashCode ( )

Returns the hash code for this instance.

Returns
A 32-bit signed integer that is the hash code for this instance.

◆ operator!=()

static bool operator!= ( Polygon3D< T >  left,
Polygon3D< T >  right 
)
static

Inequality comparison operator.

Parameters
leftLeft hand side operand.
rightRight hand side operand.
Returns
True if left != right , otherwise false.

◆ operator==()

static bool operator== ( Polygon3D< T >  left,
Polygon3D< T >  right 
)
static

Equality comparison operator.

Parameters
leftLeft hand side operand.
rightRight hand side operand.
Returns
True if left == right , otherwise false.