RTI Connext C# API Version 7.3.0
Example.Point Struct Reference

Example C# class generated from the IDL struct Point, used by MyType. More...

Inherits IEquatable< Point >.

Public Member Functions

 Point ()
 Creates an new instance with the default values (X and Y are 0) More...
 
 Point (int X, int Y)
 Creates an new instance with the given values for each property More...
 
 Point (Point other_)
 Creates a new instance by making a deep copy of an existing one More...
 
bool Equals (Point other)
 Compares two Point instances for equality (IEquatable implementation) More...
 
override bool Equals (object obj)
 Compares this instance with another object (override of object.Equals) More...
 
override string ToString ()
 Provides a readable string representation More...
 
override int GetHashCode ()
 Calculates the hash code based on the values of X and Y More...
 

Properties

int X [get, set]
 Gets or sets the value for the field X More...
 
int Y [get, set]
 Gets or sets the value for the field Y More...
 

Detailed Description

Example C# class generated from the IDL struct Point, used by MyType.

See also
Example.MyType

Constructor & Destructor Documentation

◆ Point() [1/3]

Example.Point.Point ( )
inline

Creates an new instance with the default values (X and Y are 0)

◆ Point() [2/3]

Example.Point.Point ( int  X,
int  Y 
)
inline

Creates an new instance with the given values for each property

Parameters
XThe value for the property X
YThe value for the property Y

◆ Point() [3/3]

Example.Point.Point ( Point  other_)
inline

Creates a new instance by making a deep copy of an existing one

Parameters
other_The object to copy

Member Function Documentation

◆ Equals() [1/2]

bool Example.Point.Equals ( Point  other)
inline

Compares two Point instances for equality (IEquatable implementation)

Parameters
otherThe instance to compare
Returns
Whether the two instances have the same values of X and Y

◆ Equals() [2/2]

override bool Example.Point.Equals ( object  obj)

Compares this instance with another object (override of object.Equals)

Parameters
objAny object
Returns
True only if obj is of type Point and both are equal

◆ ToString()

override string Example.Point.ToString ( )

Provides a readable string representation

PointSupport provides additional options (such as XML and JSON formatting) via Rti.Dds.Topics.TypeSupport<T>.ToString(T, Rti.Dds.Topics.PrintFormatProperty).

◆ GetHashCode()

override int Example.Point.GetHashCode ( )
inline

Calculates the hash code based on the values of X and Y

Property Documentation

◆ X

int Example.Point.X
getset

Gets or sets the value for the field X

◆ Y

int Example.Point.Y
getset

Gets or sets the value for the field Y