Interface element representing a Model. More...
#include <InterfaceModel.hh>
Public Member Functions | |
InterfaceModel (const std::string &_name, const sdf::RepostureFunction &_repostureFunction, bool _static, const std::string &_canonicalLinkName, const ignition::math::Pose3d &_poseInParentFrame={}) | |
Constructor. More... | |
void | AddFrame (sdf::InterfaceFrame _frame) |
Add an interface frame. More... | |
void | AddJoint (sdf::InterfaceJoint _joint) |
Add an interface joint. More... | |
void | AddLink (sdf::InterfaceLink _link) |
Add an interface link. More... | |
void | AddNestedModel (sdf::InterfaceModelConstPtr _nestedModel) |
Provided so that hierarchy can still be leveraged from SDFormat. More... | |
const std::string & | CanonicalLinkName () const |
Get the canonical link name. More... | |
const std::vector< sdf::InterfaceFrame > & | Frames () const |
Gets registered frames. More... | |
const std::vector< sdf::InterfaceJoint > & | Joints () const |
Gets registered joints. More... | |
const std::vector< sdf::InterfaceLink > & | Links () const |
Gets registered links. More... | |
const ignition::math::Pose3d & | ModelFramePoseInParentFrame () const |
Get the pose of this model in the parent frame. More... | |
const std::string & | Name () const |
Get the name of the model. More... | |
const std::vector< sdf::InterfaceModelConstPtr > & | NestedModels () const |
Gets registered nested models. More... | |
bool | Static () const |
Get whether the model is static. More... | |
Interface element representing a Model.
sdf::v11::InterfaceModel::InterfaceModel | ( | const std::string & | _name, |
const sdf::RepostureFunction & | _repostureFunction, | ||
bool | _static, | ||
const std::string & | _canonicalLinkName, | ||
const ignition::math::Pose3d & | _poseInParentFrame = {} |
||
) |
Constructor.
[in] | name | The local name (no nesting, e.g. "::"). If this name contains "::", an error will be raised. |
[in] | _static | Whether the model is static |
[in] | _canonicalLinkName | The canonical link's name. This is the resolved name of the canonical link, therefore, it cannot be an empty string. The link must be added to the model. If the canonical link is nested in a child model, this should be the relative name (using the "::" delimiter) of the canonical link in the scope of this model. |
[in] | _poseInParentFrame | Model frame pose relative to the parent frame. Defaults to identity. |
void sdf::v11::InterfaceModel::AddFrame | ( | sdf::InterfaceFrame | _frame | ) |
Add an interface frame.
Provided so that the including SDFormat model can still interface with the declared frames.
[in] | _frame | A child interface frame. |
void sdf::v11::InterfaceModel::AddJoint | ( | sdf::InterfaceJoint | _joint | ) |
Add an interface joint.
Provided so that the including SDFormat model can still interface with the declared joints.
[in] | _joint | A child interface joint. |
void sdf::v11::InterfaceModel::AddLink | ( | sdf::InterfaceLink | _link | ) |
Add an interface link.
Provided so that the including SDFormat model can still interface with the declared links.
[in] | _link | A child interface link. |
void sdf::v11::InterfaceModel::AddNestedModel | ( | sdf::InterfaceModelConstPtr | _nestedModel | ) |
Provided so that hierarchy can still be leveraged from SDFormat.
[in] | _nestedModel | A child interface model. |
const std::string& sdf::v11::InterfaceModel::CanonicalLinkName | ( | ) | const |
Get the canonical link name.
const std::vector<sdf::InterfaceFrame>& sdf::v11::InterfaceModel::Frames | ( | ) | const |
Gets registered frames.
const std::vector<sdf::InterfaceJoint>& sdf::v11::InterfaceModel::Joints | ( | ) | const |
Gets registered joints.
const std::vector<sdf::InterfaceLink>& sdf::v11::InterfaceModel::Links | ( | ) | const |
Gets registered links.
const ignition::math::Pose3d& sdf::v11::InterfaceModel::ModelFramePoseInParentFrame | ( | ) | const |
Get the pose of this model in the parent frame.
const std::string& sdf::v11::InterfaceModel::Name | ( | ) | const |
Get the name of the model.
const std::vector<sdf::InterfaceModelConstPtr>& sdf::v11::InterfaceModel::NestedModels | ( | ) | const |
Gets registered nested models.
bool sdf::v11::InterfaceModel::Static | ( | ) | const |
Get whether the model is static.