|
void | AddEntity (const Entity &_entity, const RequiredEntityPtr &_physicsEntity) |
| Add a mapping between gazebo and physics entities.
|
|
template<typename ToFeatureList > |
PhysicsEntityPtr< ToFeatureList > | EntityCast (const RequiredEntityPtr &_physicsEntity) const |
| Helper function to cast from an entity type with minimum features to an entity with a different set of features. This overload takes a physics entity as input.
|
|
template<typename ToFeatureList > |
PhysicsEntityPtr< ToFeatureList > | EntityCast (sim::Entity _entity) const |
| Helper function to cast from an entity type with minimum features to an entity with a different set of features. When the entity is cast successfully, it is added to an internal cache so that subsequent casts will use the entity from the cache.
|
|
RequiredEntityPtr | Get (const Entity &_entity) const |
| Get the physics entity with required features that corresponds to the input Gazebo entity.
|
|
Entity | Get (const RequiredEntityPtr &_physEntity) const |
| Get Gazebo entity that corresponds to the physics entity with required features.
|
|
Entity | GetByPhysicsId (std::size_t _id) const |
| Get Gazebo entity that corresponds to the physics entity ID.
|
|
RequiredEntityPtr | GetPhysicsEntityPtr (std::size_t _id) const |
| Get the physics entity with required features that has a particular ID.
|
|
bool | HasEntity (const Entity &_entity) const |
| Check whether there is a physics entity associated with the given Gazebo entity.
|
|
bool | HasEntity (const RequiredEntityPtr &_physicsEntity) const |
| Check whether there is a gazebo entity associated with the given physics entity.
|
|
const std::unordered_map< Entity, RequiredEntityPtr > & | Map () const |
| Get the map from Gazebo entity to physics entities with required features.
|
|
bool | Remove (const RequiredEntityPtr &_physicsEntity) |
| Remove physics entity from all associated maps.
|
|
bool | Remove (Entity _entity) |
| Remove entity from all associated maps.
|
|
std::size_t | TotalMapEntryCount () const |
| Get the total number of entries in the maps. Only used for testing.
|
|
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
template<typename ToFeatureList >
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
template<typename ToFeatureList >
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
Get Gazebo entity that corresponds to the physics entity with required features.
- Parameters
-
[in] | _physEntity | Physics entity with required features |
- Returns
- If found, returns the corresponding Gazebo entity. Otherwise, kNullEntity
References gz::sim::kNullEntity.
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
Remove physics entity from all associated maps.
- Parameters
-
- Returns
- True if the entity was found and removed.
References unordered_map< K, T >::erase().
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
Remove entity from all associated maps.
- Parameters
-
[in] | _entity | Gazebo entity. |
- Returns
- True if the entity was found and removed.
References unordered_map< K, T >::erase().
template<template< typename, typename > class PhysicsEntityT, typename PolicyT , typename RequiredFeatureList , typename... OptionalFeatureLists>
Get the total number of entries in the maps. Only used for testing.
- Returns
- Number of entries in all the maps.
References unordered_map< K, T >::size().