Base class for all mutable Primitives of lanelet2. More...
#include <Primitive.h>
Public Types | |
using | DataType = typename DerivedConstPrimitive::DataType |
Public Member Functions | |
AttributeMap & | attributes () noexcept |
get the attributes in a mutable way More... | |
Primitive ()=default | |
template<typename OtherT > | |
Primitive (const Primitive< OtherT > &rhs) | |
Construct from another primitive. Only works if both share the same. More... | |
Primitive (const std::shared_ptr< const DataType > &)=delete | |
Primitive (const std::shared_ptr< DataType > &data) | |
Construct a new primitive from shared_ptr to its data. More... | |
void | setAttribute (AttributeName name, const Attribute &attribute) |
set or overwrite an attribute (enum version) More... | |
void | setAttribute (const std::string &name, const Attribute &attribute) |
set or overwrite an attribute More... | |
void | setId (Id id) noexcept |
set a new id for this primitive More... | |
Static Public Attributes | |
static constexpr bool | IsConst = false |
Protected Member Functions | |
std::shared_ptr< DataType > | data () const |
Primitive & | operator= (const Primitive &rhs) noexcept |
Primitive & | operator= (Primitive &&rhs) noexcept |
Primitive (const Primitive &rhs) noexcept | |
Primitive (Primitive &&rhs) noexcept | |
~Primitive () noexcept=default | |
Friends | |
template<typename > | |
class | Primitive |
Base class for all mutable Primitives of lanelet2.
DerivedConstPrimitive | the ConstPrimitive class that this class derives from |
Definition at line 243 of file Primitive.h.
using lanelet::Primitive< DerivedConstPrimitive >::DataType = typename DerivedConstPrimitive::DataType |
Definition at line 246 of file Primitive.h.
|
default |
|
delete |
|
inlineexplicit |
Construct a new primitive from shared_ptr to its data.
Definition at line 254 of file Primitive.h.
|
inlineexplicit |
Construct from another primitive. Only works if both share the same.
Definition at line 262 of file Primitive.h.
|
protecteddefaultnoexcept |
|
protecteddefaultnoexcept |
|
protecteddefaultnoexcept |
|
inlinenoexcept |
get the attributes in a mutable way
Definition at line 284 of file Primitive.h.
|
inlineprotected |
Definition at line 287 of file Primitive.h.
|
protecteddefaultnoexcept |
|
protecteddefaultnoexcept |
|
inline |
set or overwrite an attribute (enum version)
Definition at line 276 of file Primitive.h.
|
inline |
set or overwrite an attribute
Definition at line 273 of file Primitive.h.
|
inlinenoexcept |
set a new id for this primitive
This is the best way to corrupt a map, because all primitives are identified by their id. Make sure you know what you are doing!
Definition at line 270 of file Primitive.h.
Definition at line 280 of file Primitive.h.
|
staticconstexpr |
Definition at line 248 of file Primitive.h.