Open CASCADE Technology  6.5.4
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Attributes
Geom2d_Vector Class Reference

The abstract class Vector describes the common
behavior of vectors in 2D space.
The Geom2d package provides two concrete
classes of vectors: Geom2d_Direction (unit vector)
and Geom2d_VectorWithMagnitude.

#include <Geom2d_Vector.hxx>

Inheritance diagram for Geom2d_Vector:
Inheritance graph
[legend]

Public Member Functions

void Reverse ()
 Reverses the vector <me>.

Handle_Geom2d_Vector Reversed () const
 Returns a copy of <me> reversed.

Standard_Real Angle (const Handle< Geom2d_Vector > &Other) const
 Computes the angular value, in radians, between this
vector and vector Other. The result is a value
between -Pi and Pi. The orientation is from this
vector to vector Other.
Raises VectorWithNullMagnitude if one of the two vectors is a vector with
null magnitude because the angular value is indefinite.

void Coord (Standard_Real &X, Standard_Real &Y) const
 Returns the coordinates of <me>.

virtual Standard_Real Magnitude () const =0
 Returns the Magnitude of <me>.

virtual Standard_Real SquareMagnitude () const =0
 Returns the square magnitude of <me>.

Standard_Real X () const
 Returns the X coordinate of <me>.

Standard_Real Y () const
 Returns the Y coordinate of <me>.

virtual Standard_Real Crossed (const Handle< Geom2d_Vector > &Other) const =0
 Cross product of <me> with the vector <Other>.

Standard_Real Dot (const Handle< Geom2d_Vector > &Other) const
 Returns the scalar product of 2 Vectors.

gp_Vec2d Vec2d () const
 Returns a non persistent copy of <me>.

Protected Attributes

gp_Vec2d gpVec2d

Member Function Documentation

virtual Standard_Real Geom2d_Vector::Crossed ( const Handle< Geom2d_Vector > &  Other) const [pure virtual]
virtual Standard_Real Geom2d_Vector::Magnitude ( ) const [pure virtual]
Handle_Geom2d_Vector Geom2d_Vector::Reversed ( ) const
virtual Standard_Real Geom2d_Vector::SquareMagnitude ( ) const [pure virtual]

Field Documentation


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