SHAPER 9.16.0
ConstructionAPI_Axis Class Reference

Interface for Axis feature. More...

#include <ConstructionAPI_Axis.h>

Inheritance diagram for ConstructionAPI_Axis:
Inheritance graph

Public Member Functions

 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature)
 Constructor without values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &theObject1, const ModelHighAPI_Selection &theObject2)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &theObject)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &thePoint, const ModelHighAPI_Double &theX, const ModelHighAPI_Double &theY, const ModelHighAPI_Double &theZ)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Double &theDX, const ModelHighAPI_Double &theDY, const ModelHighAPI_Double &theDZ)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Double &theOffset1, const bool theReverseOffset1, const ModelHighAPI_Selection &thePlane2, const ModelHighAPI_Double &theOffset2, const bool theReverseOffset2)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Selection &thePlane2, const ModelHighAPI_Double &theOffset2, const bool theReverseOffset2)
 Constructor with values. More...
 
 ConstructionAPI_Axis (const std::shared_ptr< ModelAPI_Feature > &theFeature, const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Double &theOffset1, const bool theReverseOffset1, const ModelHighAPI_Selection &thePlane2)
 Constructor with values. More...
 
virtual ~ConstructionAPI_Axis ()
 Destructor. More...
 
virtual std::string getID ()
 
virtual std::shared_ptr< ModelAPI_AttributeString > creationMethod () const
 Creation method. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > firstPoint () const
 First point. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > secondPoint () const
 Second point. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > cylindricalFace () const
 Cylindrical face. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > xDirection () const
 X direction. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > yDirection () const
 Y direction. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > zDirection () const
 Z direction. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > xDimension () const
 X dimension. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > yDimension () const
 Y dimension. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > zDimension () const
 Z dimension. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > line () const
 Line. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > plane () const
 Plane. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > point () const
 Point. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > plane1 () const
 Plane 1. More...
 
virtual std::shared_ptr< ModelAPI_AttributeString > useOffset1 () const
 Use offset 1. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > offset1 () const
 Offset 1. More...
 
virtual std::shared_ptr< ModelAPI_AttributeBoolean > reverseOffset1 () const
 Reverse offset 1. More...
 
virtual std::shared_ptr< ModelAPI_AttributeSelection > plane2 () const
 Plane 2. More...
 
virtual std::shared_ptr< ModelAPI_AttributeString > useOffset2 () const
 Use offset 2. More...
 
virtual std::shared_ptr< ModelAPI_AttributeDouble > offset2 () const
 Offset 2. More...
 
virtual std::shared_ptr< ModelAPI_AttributeBoolean > reverseOffset2 () const
 Reverse offset 2. More...
 
void setByPoints (const ModelHighAPI_Selection &thePoint1, const ModelHighAPI_Selection &thePoint2)
 Set points. More...
 
void setByCylindricalFace (const ModelHighAPI_Selection &theCylindricalFace)
 Set cylindrical face. More...
 
void setByPointAndDirection (const ModelHighAPI_Selection &thePoint, const ModelHighAPI_Double &theX, const ModelHighAPI_Double &theY, const ModelHighAPI_Double &theZ)
 Set direction. More...
 
void setByDimensions (const ModelHighAPI_Double &theDX, const ModelHighAPI_Double &theDY, const ModelHighAPI_Double &theDZ)
 Set dimensions. More...
 
void setByLine (const ModelHighAPI_Selection &theCylindricalFace)
 Set by line. More...
 
void setByPlaneAndPoint (const ModelHighAPI_Selection &thePlane, const ModelHighAPI_Selection &thePoint)
 Set by plane and point. More...
 
void setByTwoPlanes (const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Selection &thePlane2)
 Set by two planes. More...
 
void setByTwoPlanes (const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Double &theOffset1, const bool theReverseOffset1, const ModelHighAPI_Selection &thePlane2, const ModelHighAPI_Double &theOffset2, const bool theReverseOffset2)
 Set by two planes. More...
 
void setByTwoPlanes (const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Selection &thePlane2, const ModelHighAPI_Double &theOffset2, const bool theReverseOffset2)
 Set by two planes. More...
 
void setByTwoPlanes (const ModelHighAPI_Selection &thePlane1, const ModelHighAPI_Double &theOffset1, const bool theReverseOffset1, const ModelHighAPI_Selection &thePlane2)
 Set by two planes. More...
 
virtual void dump (ModelHighAPI_Dumper &theDumper) const
 Dump wrapped feature. More...
 
std::shared_ptr< ModelAPI_Feature > feature () const
 Return ModelAPI_Feature. More...
 
std::shared_ptr< ModelHighAPI_Interface > subFeature (const int theIndex) const
 If feature is composite return intefrace for sub-feature by zero-based index, or empty pointer if feature not composite or does not have sub-feature with such index. More...
 
const std::string & getKind () const
 Shortcut for feature()->getKind() More...
 
void execute (bool isForce=false)
 Shortcut for feature()->execute() More...
 
void setName (const std::wstring &theName)
 Shortcut for feature()->data()->setName() More...
 
std::wstring name () const
 Shortcut for feature()->data()->name() More...
 
virtual ModelHighAPI_Selection result () const
 Return firts object of the feature. More...
 
virtual std::list< ModelHighAPI_Selection > results () const
 Return all objects of the feature. More...
 
virtual std::shared_ptr< ModelAPI_Result > defaultResult () const
 Return default result. Default implementation feature()->lastResult() More...
 
void throwException (const std::string &theDescription)
 Throw exception to event loop. More...
 
const std::string & attributeGetter (const std::string &theAttrName)
 Return name of getter for specified attribute. More...
 
virtual ListOfShape vertices (const bool theOnlyUnique=false)
 Returns all the vertices produced by this feature. More...
 
virtual ListOfShape edges (const bool theOnlyUnique=false)
 Returns all the edges produced by this feature. More...
 
virtual ListOfShape wires (const bool theOnlyUnique=false)
 Returns all the wires produced by this feature. More...
 
virtual ListOfShape faces (const bool theOnlyUnique=false)
 Returns all the faces produced by this feature. More...
 
virtual ListOfShape shells (const bool theOnlyUnique=false)
 Returns all the shells produced by this feature. More...
 
virtual ListOfShape solids (const bool theOnlyUnique=false)
 Returns all the solids produced by this feature. More...
 

Static Public Member Functions

static std::string ID ()
 

Protected Member Functions

bool initialize ()
 

Protected Attributes

std::shared_ptr< ModelAPI_AttributeString > mycreationMethod
 
std::shared_ptr< ModelAPI_AttributeSelection > myfirstPoint
 
std::shared_ptr< ModelAPI_AttributeSelection > mysecondPoint
 
std::shared_ptr< ModelAPI_AttributeSelection > mycylindricalFace
 
std::shared_ptr< ModelAPI_AttributeDouble > myxDirection
 
std::shared_ptr< ModelAPI_AttributeDouble > myyDirection
 
std::shared_ptr< ModelAPI_AttributeDouble > myzDirection
 
std::shared_ptr< ModelAPI_AttributeDouble > myxDimension
 
std::shared_ptr< ModelAPI_AttributeDouble > myyDimension
 
std::shared_ptr< ModelAPI_AttributeDouble > myzDimension
 
std::shared_ptr< ModelAPI_AttributeSelection > myline
 
std::shared_ptr< ModelAPI_AttributeSelection > myplane
 
std::shared_ptr< ModelAPI_AttributeSelection > mypoint
 
std::shared_ptr< ModelAPI_AttributeSelection > myplane1
 
std::shared_ptr< ModelAPI_AttributeString > myuseOffset1
 
std::shared_ptr< ModelAPI_AttributeDouble > myoffset1
 
std::shared_ptr< ModelAPI_AttributeBoolean > myreverseOffset1
 
std::shared_ptr< ModelAPI_AttributeSelection > myplane2
 
std::shared_ptr< ModelAPI_AttributeString > myuseOffset2
 
std::shared_ptr< ModelAPI_AttributeDouble > myoffset2
 
std::shared_ptr< ModelAPI_AttributeBoolean > myreverseOffset2
 
std::shared_ptr< ModelAPI_Feature > myFeature
 feature of this interface More...
 
std::map< std::string, std::string > myAttrGetter
 names of attributes and their getters More...
 

Detailed Description

Interface for Axis feature.

Constructor & Destructor Documentation

◆ ConstructionAPI_Axis() [1/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature)
explicit

Constructor without values.

◆ ConstructionAPI_Axis() [2/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  theObject1,
const ModelHighAPI_Selection &  theObject2 
)

Constructor with values.

◆ ConstructionAPI_Axis() [3/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  theObject 
)

Constructor with values.

◆ ConstructionAPI_Axis() [4/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  thePoint,
const ModelHighAPI_Double &  theX,
const ModelHighAPI_Double &  theY,
const ModelHighAPI_Double &  theZ 
)

Constructor with values.

◆ ConstructionAPI_Axis() [5/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Double &  theDX,
const ModelHighAPI_Double &  theDY,
const ModelHighAPI_Double &  theDZ 
)

Constructor with values.

◆ ConstructionAPI_Axis() [6/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Double &  theOffset1,
const bool  theReverseOffset1,
const ModelHighAPI_Selection &  thePlane2,
const ModelHighAPI_Double &  theOffset2,
const bool  theReverseOffset2 
)

Constructor with values.

◆ ConstructionAPI_Axis() [7/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Selection &  thePlane2,
const ModelHighAPI_Double &  theOffset2,
const bool  theReverseOffset2 
)

Constructor with values.

◆ ConstructionAPI_Axis() [8/8]

ConstructionAPI_Axis::ConstructionAPI_Axis ( const std::shared_ptr< ModelAPI_Feature > &  theFeature,
const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Double &  theOffset1,
const bool  theReverseOffset1,
const ModelHighAPI_Selection &  thePlane2 
)

Constructor with values.

◆ ~ConstructionAPI_Axis()

ConstructionAPI_Axis::~ConstructionAPI_Axis ( )
virtual

Destructor.

Member Function Documentation

◆ creationMethod()

virtual std::shared_ptr< ModelAPI_AttributeString > ConstructionAPI_Axis::creationMethod ( ) const
inlinevirtual

Creation method.

◆ firstPoint()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::firstPoint ( ) const
inlinevirtual

First point.

◆ secondPoint()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::secondPoint ( ) const
inlinevirtual

Second point.

◆ cylindricalFace()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::cylindricalFace ( ) const
inlinevirtual

Cylindrical face.

◆ xDirection()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::xDirection ( ) const
inlinevirtual

X direction.

◆ yDirection()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::yDirection ( ) const
inlinevirtual

Y direction.

◆ zDirection()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::zDirection ( ) const
inlinevirtual

Z direction.

◆ xDimension()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::xDimension ( ) const
inlinevirtual

X dimension.

◆ yDimension()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::yDimension ( ) const
inlinevirtual

Y dimension.

◆ zDimension()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::zDimension ( ) const
inlinevirtual

Z dimension.

◆ line()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::line ( ) const
inlinevirtual

Line.

◆ plane()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::plane ( ) const
inlinevirtual

Plane.

◆ point()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::point ( ) const
inlinevirtual

Point.

◆ plane1()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::plane1 ( ) const
inlinevirtual

Plane 1.

◆ useOffset1()

virtual std::shared_ptr< ModelAPI_AttributeString > ConstructionAPI_Axis::useOffset1 ( ) const
inlinevirtual

Use offset 1.

◆ offset1()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::offset1 ( ) const
inlinevirtual

Offset 1.

◆ reverseOffset1()

virtual std::shared_ptr< ModelAPI_AttributeBoolean > ConstructionAPI_Axis::reverseOffset1 ( ) const
inlinevirtual

Reverse offset 1.

◆ plane2()

virtual std::shared_ptr< ModelAPI_AttributeSelection > ConstructionAPI_Axis::plane2 ( ) const
inlinevirtual

Plane 2.

◆ useOffset2()

virtual std::shared_ptr< ModelAPI_AttributeString > ConstructionAPI_Axis::useOffset2 ( ) const
inlinevirtual

Use offset 2.

◆ offset2()

virtual std::shared_ptr< ModelAPI_AttributeDouble > ConstructionAPI_Axis::offset2 ( ) const
inlinevirtual

Offset 2.

◆ reverseOffset2()

virtual std::shared_ptr< ModelAPI_AttributeBoolean > ConstructionAPI_Axis::reverseOffset2 ( ) const
inlinevirtual

Reverse offset 2.

◆ setByPoints()

void ConstructionAPI_Axis::setByPoints ( const ModelHighAPI_Selection &  thePoint1,
const ModelHighAPI_Selection &  thePoint2 
)

Set points.

◆ setByCylindricalFace()

void ConstructionAPI_Axis::setByCylindricalFace ( const ModelHighAPI_Selection &  theCylindricalFace)

Set cylindrical face.

◆ setByPointAndDirection()

void ConstructionAPI_Axis::setByPointAndDirection ( const ModelHighAPI_Selection &  thePoint,
const ModelHighAPI_Double &  theX,
const ModelHighAPI_Double &  theY,
const ModelHighAPI_Double &  theZ 
)

Set direction.

◆ setByDimensions()

void ConstructionAPI_Axis::setByDimensions ( const ModelHighAPI_Double &  theDX,
const ModelHighAPI_Double &  theDY,
const ModelHighAPI_Double &  theDZ 
)

Set dimensions.

◆ setByLine()

void ConstructionAPI_Axis::setByLine ( const ModelHighAPI_Selection &  theCylindricalFace)

Set by line.

◆ setByPlaneAndPoint()

void ConstructionAPI_Axis::setByPlaneAndPoint ( const ModelHighAPI_Selection &  thePlane,
const ModelHighAPI_Selection &  thePoint 
)

Set by plane and point.

◆ setByTwoPlanes() [1/4]

void ConstructionAPI_Axis::setByTwoPlanes ( const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Selection &  thePlane2 
)

Set by two planes.

◆ setByTwoPlanes() [2/4]

void ConstructionAPI_Axis::setByTwoPlanes ( const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Double &  theOffset1,
const bool  theReverseOffset1,
const ModelHighAPI_Selection &  thePlane2,
const ModelHighAPI_Double &  theOffset2,
const bool  theReverseOffset2 
)

Set by two planes.

◆ setByTwoPlanes() [3/4]

void ConstructionAPI_Axis::setByTwoPlanes ( const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Selection &  thePlane2,
const ModelHighAPI_Double &  theOffset2,
const bool  theReverseOffset2 
)

Set by two planes.

◆ setByTwoPlanes() [4/4]

void ConstructionAPI_Axis::setByTwoPlanes ( const ModelHighAPI_Selection &  thePlane1,
const ModelHighAPI_Double &  theOffset1,
const bool  theReverseOffset1,
const ModelHighAPI_Selection &  thePlane2 
)

Set by two planes.

◆ dump()

void ConstructionAPI_Axis::dump ( ModelHighAPI_Dumper &  theDumper) const
virtual

Dump wrapped feature.

Reimplemented from ModelHighAPI_Interface.

◆ feature()

std::shared_ptr< ModelAPI_Feature > ModelHighAPI_Interface::feature ( ) const
inherited

◆ subFeature()

std::shared_ptr< ModelHighAPI_Interface > ModelHighAPI_Interface::subFeature ( const int  theIndex) const
inherited

If feature is composite return intefrace for sub-feature by zero-based index, or empty pointer if feature not composite or does not have sub-feature with such index.

◆ getKind()

const std::string & ModelHighAPI_Interface::getKind ( ) const
inherited

Shortcut for feature()->getKind()

◆ execute()

void ModelHighAPI_Interface::execute ( bool  isForce = false)
inherited

Shortcut for feature()->execute()

Parameters
isForcestart execution of feature instead of sending events

◆ setName()

void ModelHighAPI_Interface::setName ( const std::wstring &  theName)
inherited

Shortcut for feature()->data()->setName()

◆ name()

std::wstring ModelHighAPI_Interface::name ( ) const
inherited

Shortcut for feature()->data()->name()

◆ result()

ModelHighAPI_Selection ModelHighAPI_Interface::result ( ) const
virtualinherited

Return firts object of the feature.

◆ results()

std::list< ModelHighAPI_Selection > ModelHighAPI_Interface::results ( ) const
virtualinherited

Return all objects of the feature.

◆ defaultResult()

std::shared_ptr< ModelAPI_Result > ModelHighAPI_Interface::defaultResult ( ) const
virtualinherited

Return default result. Default implementation feature()->lastResult()

◆ throwException()

void ModelHighAPI_Interface::throwException ( const std::string &  theDescription)
inherited

Throw exception to event loop.

◆ attributeGetter()

const std::string & ModelHighAPI_Interface::attributeGetter ( const std::string &  theAttrName)
inherited

Return name of getter for specified attribute.

◆ vertices()

ListOfShape ModelHighAPI_Interface::vertices ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the vertices produced by this feature.

◆ edges()

ListOfShape ModelHighAPI_Interface::edges ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the edges produced by this feature.

◆ wires()

ListOfShape ModelHighAPI_Interface::wires ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the wires produced by this feature.

◆ faces()

ListOfShape ModelHighAPI_Interface::faces ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the faces produced by this feature.

◆ shells()

ListOfShape ModelHighAPI_Interface::shells ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the shells produced by this feature.

◆ solids()

ListOfShape ModelHighAPI_Interface::solids ( const bool  theOnlyUnique = false)
virtualinherited

Returns all the solids produced by this feature.

Field Documentation

◆ myFeature

std::shared_ptr<ModelAPI_Feature> ModelHighAPI_Interface::myFeature
protectedinherited

feature of this interface

◆ myAttrGetter

std::map<std::string, std::string> ModelHighAPI_Interface::myAttrGetter
protectedinherited

names of attributes and their getters