Public Member Functions | List of all members
sdf::v9::Joint Class Reference

#include <Joint.hh>

Public Member Functions

 Joint ()
 Default constructor. More...
 
 Joint (const Joint &_joint)
 Copy constructor. More...
 
 Joint (Joint &&_joint) noexcept
 Move constructor. More...
 
 ~Joint ()
 Destructor. More...
 
const JointAxisAxis (const unsigned int _index=0) const
 Get a joint axis. More...
 
const std::string & ChildLinkName () const
 Get the name of this joint's child link. More...
 
sdf::ElementPtr Element () const
 Get a pointer to the SDF element that was used during load. More...
 
Errors Load (ElementPtr _sdf)
 Load the joint based on a element pointer. More...
 
const std::string & Name () const
 Get the name of the joint. More...
 
Jointoperator= (Joint &&_joint)
 Move assignment operator. More...
 
Jointoperator= (const Joint &_joint)
 Copy assignment operator. More...
 
const std::string & ParentLinkName () const
 Get the name of this joint's parent link. More...
 
const ignition::math::Pose3d & Pose () const SDF_DEPRECATED(9.0)
 Get the pose of the joint. More...
 
const std::string & PoseFrame () const SDF_DEPRECATED(9.0)
 Get the name of the coordinate frame in which this joint's pose is expressed. More...
 
const std::string & PoseRelativeTo () const
 Get the name of the coordinate frame relative to which this object's pose is expressed. More...
 
const ignition::math::Pose3d & RawPose () const
 Get the pose of the joint. More...
 
sdf::SemanticPose SemanticPose () const
 Get SemanticPose object of this object to aid in resolving poses. More...
 
void SetAxis (const unsigned int _index, const JointAxis &_axis)
 Set a joint axis. More...
 
void SetChildLinkName (const std::string &_name)
 Set the name of the child link. More...
 
void SetName (const std::string &_name)
 Set the name of the joint. More...
 
void SetParentLinkName (const std::string &_name)
 Set the name of the parent link. More...
 
void SetPose (const ignition::math::Pose3d &_pose) SDF_DEPRECATED(9.0)
 Set the pose of the joint. More...
 
void SetPoseFrame (const std::string &_frame) SDF_DEPRECATED(9.0)
 Set the name of the coordinate frame in which this joint's pose is expressed. More...
 
void SetPoseRelativeTo (const std::string &_frame)
 Set the name of the coordinate frame relative to which this object's pose is expressed. More...
 
void SetRawPose (const ignition::math::Pose3d &_pose)
 Set the pose of the joint. More...
 
void SetThreadPitch (double _threadPitch)
 Set the thread pitch (only valid for screw joints) More...
 
void SetType (const JointType _jointType)
 Set the joint type. More...
 
double ThreadPitch () const
 Get the thread pitch (only valid for screw joints) More...
 
JointType Type () const
 Get the joint type. More...
 

Constructor & Destructor Documentation

◆ Joint() [1/3]

sdf::v9::Joint::Joint ( )

Default constructor.

◆ Joint() [2/3]

sdf::v9::Joint::Joint ( const Joint _joint)

Copy constructor.

Parameters
[in]_jointJoint to copy.

◆ Joint() [3/3]

sdf::v9::Joint::Joint ( Joint &&  _joint)
noexcept

Move constructor.

Parameters
[in]_jointJoint to move.

◆ ~Joint()

sdf::v9::Joint::~Joint ( )

Destructor.

Member Function Documentation

◆ Axis()

const JointAxis* sdf::v9::Joint::Axis ( const unsigned int  _index = 0) const

Get a joint axis.

Parameters
[in]_indexThis value specifies which axis to get. A value of zero corresponds to the first axis, which is the <axis> SDF element. Any other value will return the second axis, which is the <axis2> SDF element.
Returns
A JointAxis for either the first or second joint axis. A return value of nullptr indicates that the axis is not specified.

◆ ChildLinkName()

const std::string& sdf::v9::Joint::ChildLinkName ( ) const

Get the name of this joint's child link.

Returns
The name of the child link.

◆ Element()

sdf::ElementPtr sdf::v9::Joint::Element ( ) const

Get a pointer to the SDF element that was used during load.

Returns
SDF element pointer. The value will be nullptr if Load has not been called.

◆ Load()

Errors sdf::v9::Joint::Load ( ElementPtr  _sdf)

Load the joint based on a element pointer.

This is not the usual entry point. Typical usage of the SDF DOM is through the Root object.

Parameters
[in]_sdfThe SDF Element pointer
Returns
Errors, which is a vector of Error objects. Each Error includes an error code and message. An empty vector indicates no error.

◆ Name()

const std::string& sdf::v9::Joint::Name ( ) const

Get the name of the joint.

The name of the joint must be unique within the scope of a Model.

Returns
Name of the joint.

◆ operator=() [1/2]

Joint& sdf::v9::Joint::operator= ( Joint &&  _joint)

Move assignment operator.

Parameters
[in]_jointJoint to move.
Returns
Reference to this.

◆ operator=() [2/2]

Joint& sdf::v9::Joint::operator= ( const Joint _joint)

Copy assignment operator.

Parameters
[in]_jointJoint to copy.
Returns
Reference to this.

◆ ParentLinkName()

const std::string& sdf::v9::Joint::ParentLinkName ( ) const

Get the name of this joint's parent link.

Returns
The name of the parent link.

◆ Pose()

const ignition::math::Pose3d& sdf::v9::Joint::Pose ( ) const

Get the pose of the joint.

This is the pose of the joint as specified in SDF (<joint> <pose> ... </pose></joint>). Transformations have not been applied to the return value.

Returns
The pose of the joint. This is the raw pose value, as set in the SDF file.
Deprecated:
See RawPose.

◆ PoseFrame()

const std::string& sdf::v9::Joint::PoseFrame ( ) const

Get the name of the coordinate frame in which this joint's pose is expressed.

A empty value indicates that the frame is the child link frame.

Returns
The name of the pose frame.
Deprecated:
See PoseRelativeTo.

◆ PoseRelativeTo()

const std::string& sdf::v9::Joint::PoseRelativeTo ( ) const

Get the name of the coordinate frame relative to which this object's pose is expressed.

An empty value indicates that the frame is relative to the child link frame.

Returns
The name of the pose relative-to frame.

◆ RawPose()

const ignition::math::Pose3d& sdf::v9::Joint::RawPose ( ) const

Get the pose of the joint.

This is the pose of the joint as specified in SDF (<joint> <pose> ... </pose></joint>). Transformations have not been applied to the return value.

Returns
The pose of the joint. This is the raw pose value, as set in the SDF file.

◆ SemanticPose()

sdf::SemanticPose sdf::v9::Joint::SemanticPose ( ) const

Get SemanticPose object of this object to aid in resolving poses.

Returns
SemanticPose object for this link.

◆ SetAxis()

void sdf::v9::Joint::SetAxis ( const unsigned int  _index,
const JointAxis _axis 
)

Set a joint axis.

Parameters
[in]_indexThis value specifies which axis to set. A value of zero corresponds to the first axis, which is the <axis> SDF element. Any other value will set the second axis, which is the <axis2> SDF element.
[in]_axisThe JointAxis of the joint

◆ SetChildLinkName()

void sdf::v9::Joint::SetChildLinkName ( const std::string &  _name)

Set the name of the child link.

Parameters
[in]_nameName of the child link.

◆ SetName()

void sdf::v9::Joint::SetName ( const std::string &  _name)

Set the name of the joint.

The name of the joint must be unique within the scope of a Model.

Parameters
[in]_nameName of the joint.

◆ SetParentLinkName()

void sdf::v9::Joint::SetParentLinkName ( const std::string &  _name)

Set the name of the parent link.

Parameters
[in]_nameName of the parent link.

◆ SetPose()

void sdf::v9::Joint::SetPose ( const ignition::math::Pose3d &  _pose)

Set the pose of the joint.

See also
const ignition::math::Pose3d &Pose() const;
Parameters
[in]_poseThe pose of the joint.
Deprecated:
See SetRawPose.

◆ SetPoseFrame()

void sdf::v9::Joint::SetPoseFrame ( const std::string &  _frame)

Set the name of the coordinate frame in which this joint's pose is expressed.

A empty value indicates that the frame is the child link frame.

Parameters
[in]_frameThe name of the pose frame.
Deprecated:
See SetPoseRelativeTo.

◆ SetPoseRelativeTo()

void sdf::v9::Joint::SetPoseRelativeTo ( const std::string &  _frame)

Set the name of the coordinate frame relative to which this object's pose is expressed.

An empty value indicates that the frame is relative to the child link frame.

Parameters
[in]_frameThe name of the pose relative-to frame.

◆ SetRawPose()

void sdf::v9::Joint::SetRawPose ( const ignition::math::Pose3d &  _pose)

Set the pose of the joint.

See also
const ignition::math::Pose3d &RawPose() const;
Parameters
[in]_poseThe pose of the joint.

◆ SetThreadPitch()

void sdf::v9::Joint::SetThreadPitch ( double  _threadPitch)

Set the thread pitch (only valid for screw joints)

Parameters
[in]_threadPitchThe thread pitch of the joint

◆ SetType()

void sdf::v9::Joint::SetType ( const JointType  _jointType)

Set the joint type.

Parameters
[in]_jointTypeThe type of joint.

◆ ThreadPitch()

double sdf::v9::Joint::ThreadPitch ( ) const

Get the thread pitch (only valid for screw joints)

Returns
The thread pitch

◆ Type()

JointType sdf::v9::Joint::Type ( ) const

Get the joint type.

Returns
Type of joint.

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