Otclient  14/8/2020
TPoint< T > Class Template Reference

#include <point.h>

Public Member Functions

 TPoint ()
 
 TPoint (T x, T y)
 
 TPoint (const TPoint< T > &other)
 
bool isNull () const
 
TSize< T > toSize () const
 
TPoint< T > operator- () const
 
TPoint< T > operator+ (const TPoint< T > &other) const
 
TPoint< T > & operator+= (const TPoint< T > &other)
 
TPoint< T > operator- (const TPoint< T > &other) const
 
TPoint< T > & operator-= (const TPoint< T > &other)
 
TPoint< T > operator* (const TPoint< T > &other) const
 
TPoint< T > & operator*= (const TPoint< T > &other)
 
TPoint< T > operator/ (const TPoint< T > &other) const
 
TPoint< T > & operator/= (const TPoint< T > &other)
 
TPoint< T > operator+ (T other) const
 
TPoint< T > & operator+= (T other)
 
TPoint< T > operator- (T other) const
 
TPoint< T > & operator-= (T other)
 
TPoint< T > operator* (float v) const
 
TPoint< T > & operator*= (float v)
 
TPoint< T > operator/ (float v) const
 
TPoint< T > & operator/= (float v)
 
TPoint< T > operator& (int a)
 
TPoint< T > & operator&= (int a)
 
bool operator<= (const TPoint< T > &other) const
 
bool operator>= (const TPoint< T > &other) const
 
bool operator< (const TPoint< T > &other) const
 
bool operator> (const TPoint< T > &other) const
 
TPoint< T > & operator= (const TPoint< T > &other)
 
bool operator== (const TPoint< T > &other) const
 
bool operator!= (const TPoint< T > &other) const
 
float length () const
 
manhattanLength () const
 
float distanceFrom (const TPoint< T > &other) const
 

Public Attributes

x
 
y
 

Detailed Description

template<class T>
class TPoint< T >

Definition at line 34 of file point.h.

Constructor & Destructor Documentation

◆ TPoint() [1/3]

template<class T >
TPoint< T >::TPoint ( )
inline

Definition at line 37 of file point.h.

◆ TPoint() [2/3]

template<class T >
TPoint< T >::TPoint ( x,
y 
)
inline

Definition at line 38 of file point.h.

◆ TPoint() [3/3]

template<class T >
TPoint< T >::TPoint ( const TPoint< T > &  other)
inline

Definition at line 39 of file point.h.

Member Function Documentation

◆ distanceFrom()

template<class T >
float TPoint< T >::distanceFrom ( const TPoint< T > &  other) const
inline

Definition at line 79 of file point.h.

◆ isNull()

template<class T >
bool TPoint< T >::isNull ( ) const
inline

Definition at line 41 of file point.h.

Here is the caller graph for this function:

◆ length()

template<class T >
float TPoint< T >::length ( ) const
inline

Definition at line 76 of file point.h.

Here is the caller graph for this function:

◆ manhattanLength()

template<class T >
T TPoint< T >::manhattanLength ( ) const
inline

Definition at line 77 of file point.h.

◆ operator!=()

template<class T >
bool TPoint< T >::operator!= ( const TPoint< T > &  other) const
inline

Definition at line 74 of file point.h.

◆ operator&()

template<class T >
TPoint<T> TPoint< T >::operator& ( int  a)
inline

Definition at line 64 of file point.h.

◆ operator&=()

template<class T >
TPoint<T>& TPoint< T >::operator&= ( int  a)
inline

Definition at line 65 of file point.h.

◆ operator*() [1/2]

template<class T >
TPoint<T> TPoint< T >::operator* ( const TPoint< T > &  other) const
inline

Definition at line 50 of file point.h.

◆ operator*() [2/2]

template<class T >
TPoint<T> TPoint< T >::operator* ( float  v) const
inline

Definition at line 59 of file point.h.

◆ operator*=() [1/2]

template<class T >
TPoint<T>& TPoint< T >::operator*= ( const TPoint< T > &  other)
inline

Definition at line 51 of file point.h.

◆ operator*=() [2/2]

template<class T >
TPoint<T>& TPoint< T >::operator*= ( float  v)
inline

Definition at line 60 of file point.h.

◆ operator+() [1/2]

template<class T >
TPoint<T> TPoint< T >::operator+ ( const TPoint< T > &  other) const
inline

Definition at line 46 of file point.h.

◆ operator+() [2/2]

template<class T >
TPoint<T> TPoint< T >::operator+ ( other) const
inline

Definition at line 55 of file point.h.

◆ operator+=() [1/2]

template<class T >
TPoint<T>& TPoint< T >::operator+= ( const TPoint< T > &  other)
inline

Definition at line 47 of file point.h.

◆ operator+=() [2/2]

template<class T >
TPoint<T>& TPoint< T >::operator+= ( other)
inline

Definition at line 56 of file point.h.

◆ operator-() [1/3]

template<class T >
TPoint<T> TPoint< T >::operator- ( ) const
inline

Definition at line 44 of file point.h.

◆ operator-() [2/3]

template<class T >
TPoint<T> TPoint< T >::operator- ( const TPoint< T > &  other) const
inline

Definition at line 48 of file point.h.

◆ operator-() [3/3]

template<class T >
TPoint<T> TPoint< T >::operator- ( other) const
inline

Definition at line 57 of file point.h.

◆ operator-=() [1/2]

template<class T >
TPoint<T>& TPoint< T >::operator-= ( const TPoint< T > &  other)
inline

Definition at line 49 of file point.h.

◆ operator-=() [2/2]

template<class T >
TPoint<T>& TPoint< T >::operator-= ( other)
inline

Definition at line 58 of file point.h.

◆ operator/() [1/2]

template<class T >
TPoint<T> TPoint< T >::operator/ ( const TPoint< T > &  other) const
inline

Definition at line 52 of file point.h.

◆ operator/() [2/2]

template<class T >
TPoint<T> TPoint< T >::operator/ ( float  v) const
inline

Definition at line 61 of file point.h.

◆ operator/=() [1/2]

template<class T >
TPoint<T>& TPoint< T >::operator/= ( const TPoint< T > &  other)
inline

Definition at line 53 of file point.h.

◆ operator/=() [2/2]

template<class T >
TPoint<T>& TPoint< T >::operator/= ( float  v)
inline

Definition at line 62 of file point.h.

◆ operator<()

template<class T >
bool TPoint< T >::operator< ( const TPoint< T > &  other) const
inline

Definition at line 69 of file point.h.

◆ operator<=()

template<class T >
bool TPoint< T >::operator<= ( const TPoint< T > &  other) const
inline

Definition at line 67 of file point.h.

◆ operator=()

template<class T >
TPoint<T>& TPoint< T >::operator= ( const TPoint< T > &  other)
inline

Definition at line 72 of file point.h.

◆ operator==()

template<class T >
bool TPoint< T >::operator== ( const TPoint< T > &  other) const
inline

Definition at line 73 of file point.h.

◆ operator>()

template<class T >
bool TPoint< T >::operator> ( const TPoint< T > &  other) const
inline

Definition at line 70 of file point.h.

◆ operator>=()

template<class T >
bool TPoint< T >::operator>= ( const TPoint< T > &  other) const
inline

Definition at line 68 of file point.h.

◆ toSize()

template<class T >
TSize<T> TPoint< T >::toSize ( ) const
inline

Definition at line 42 of file point.h.

Here is the caller graph for this function:

Member Data Documentation

◆ x

template<class T >
T TPoint< T >::x

Definition at line 83 of file point.h.

◆ y

template<class T >
T TPoint< T >::y

Definition at line 83 of file point.h.


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