18 #ifndef IGNITION_PHYSICS_ENTITY_HH_ 19 #define IGNITION_PHYSICS_ENTITY_HH_ 25 #include <ignition/physics/Export.hh> 26 #include <ignition/physics/detail/Identity.hh> 33 namespace detail {
template <
typename,
typename>
struct DeterminePlugin; }
41 template <
typename EntityT>
62 public:
EntityPtr &operator=(std::nullopt_t);
69 public:
template <
typename Pimpl>
71 const Identity &_identity);
77 public:
template <
typename OtherEntityT>
84 public:
template <
typename OtherEntityT>
92 public: EntityT * operator->()
const;
100 public: EntityT & operator*()
const;
104 public:
bool Valid()
const;
108 public:
operator bool()
const;
125 public:
template <
typename OtherEntityT>
136 public:
template <
typename OtherEntityT>
137 bool operator <(const EntityPtr<OtherEntityT> &_other)
const;
147 public:
template <
typename OtherEntityT>
158 public:
template <
typename OtherEntityT>
169 public:
template <
typename OtherEntityT>
170 bool operator <=(const EntityPtr<OtherEntityT> &_other)
const;
180 public:
template <
typename OtherEntityT>
197 private:
mutable std::optional<std::remove_const_t<EntityT>> entity;
215 template <
typename PolicyT,
typename FeaturesT>
220 public:
using Pimpl =
221 typename detail::DeterminePlugin<Policy, Features>::type;
224 public:
const Identity &FullIdentity()
const;
254 const Identity &_identity = Identity());
266 const Identity &_identity);
275 protected:
template <
typename FeatureT>
276 typename FeatureT::template Implementation<PolicyT> *Interface();
282 protected:
template <
typename FeatureT>
283 const typename FeatureT::template Implementation<PolicyT> *Interface()
295 public:
virtual ~
Entity() =
default;
304 #include <ignition/physics/detail/Entity.hh>
This is the base class of all "proxy objects". The "proxy objects" are essentially interfaces into th...
Definition: Entity.hh:216
Identity identity
This field contains information to identify the entity.
Definition: Entity.hh:292
typename detail::DeterminePlugin< Policy, Features >::type Pimpl
Definition: Entity.hh:221
This class can be used to request features from an entity, or identify what features are missing from...
Definition: Entity.hh:34
const std::size_t INVALID_ENTITY_ID
This constant-value should be used to indicate that an Entity ID is invalid (i.e. does not refer to a...
Definition: Entity.hh:38
FeaturesT Features
Definition: Entity.hh:219
Policy Policy
Definition: Entity.hh:218
std::shared_ptr< Pimpl > pimpl
This is a pointer to the physics engine implementation, and it can be used by the object features to ...
Definition: Entity.hh:289