Implementation template class that is common to all non-const types. More...
#include <LineString.h>
Public Types | |
using | iterator = internal::SelectLsIteratorT< PointType > |
using | PointType = typename Base::MutablePointType |
using | SegmentType = typename Base::SegmentType |
![]() | |
using | DataType = typename ConstLineStringT ::DataType |
Public Member Functions | |
PointType & | back () |
get a reference to the last element if it exists More... | |
iterator | begin () |
mutable iterator for the elements of this vector. More... | |
void | clear () |
iterator | end () |
mutable iterator to the end of the elements of this vector. More... | |
iterator | erase (iterator position) |
Removes point, returns iterator to the next point. More... | |
PointType & | front () |
get a refernce to the first element (make sure it exists) More... | |
iterator | insert (iterator position, const PointType &point) |
Inserts an element at a specific position. More... | |
template<typename InIter > | |
iterator | insert (iterator position, InIter start, InIter end) |
Inserts an range of elements at a specific position. More... | |
LineStringImpl ()=default | |
template<typename OtherT > | |
LineStringImpl (const LineStringImpl< OtherT > &other) | |
Construct from other (mutable!) LineStrings. More... | |
LineStringImpl (const std::shared_ptr< const LineStringData > &, bool inverted)=delete | |
LineStringImpl (const std::shared_ptr< LineStringData > &data, bool inverted) | |
Construct from linestring data. More... | |
LineStringImpl & | operator= (std::vector< Point3d > &&rhs) |
Move assign from a normal vector. Id and attributes stay unchanged. More... | |
LineStringImpl & | operator= (std::vector< PointType > rhs) |
Copy assign from a normal vector. The Id of this object is unchanged. More... | |
PointType & | operator[] (size_t idx) |
access element at specific position More... | |
void | pop_back () |
removes element from the end More... | |
void | push_back (const PointType &point) |
inserts a new element at the end More... | |
void | reserve (size_t num) |
request a change in capacity More... | |
void | resize (size_t num) |
SegmentType | segment (size_t idx) noexcept |
returns the n-th segment. If n equals size() -1, the segment from back() to front() is returned. More... | |
![]() | |
AttributeMap & | attributes () noexcept |
get the attributes in a mutable way More... | |
Primitive ()=default | |
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... | |
Protected Types | |
using | Base = Primitive< ConstLineStringT > |
Protected Member Functions | |
LineStringImpl (const LineStringImpl &rhs)=default | |
LineStringImpl (LineStringImpl &&rhs) noexcept=default | |
LineStringImpl & | operator= (const LineStringImpl &rhs)=default |
LineStringImpl & | operator= (LineStringImpl &&rhs) noexcept=default |
Points3d & | points () |
~LineStringImpl () noexcept=default | |
![]() | |
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 | |
Additional Inherited Members | |
![]() | |
static constexpr bool | IsConst |
Implementation template class that is common to all non-const types.
Definition at line 364 of file primitives/LineString.h.
|
protected |
Definition at line 366 of file primitives/LineString.h.
using lanelet::LineStringImpl< ConstLineStringT >::iterator = internal::SelectLsIteratorT<PointType> |
Definition at line 371 of file primitives/LineString.h.
using lanelet::LineStringImpl< ConstLineStringT >::PointType = typename Base::MutablePointType |
Definition at line 370 of file primitives/LineString.h.
using lanelet::LineStringImpl< ConstLineStringT >::SegmentType = typename Base::SegmentType |
Definition at line 375 of file primitives/LineString.h.
|
default |
|
inlineexplicit |
Construct from other (mutable!) LineStrings.
Definition at line 380 of file primitives/LineString.h.
|
explicitdelete |
|
inlineexplicit |
Construct from linestring data.
Definition at line 385 of file primitives/LineString.h.
|
protecteddefaultnoexcept |
|
protecteddefault |
|
protecteddefaultnoexcept |
|
inline |
get a reference to the last element if it exists
Definition at line 490 of file primitives/LineString.h.
|
inline |
mutable iterator for the elements of this vector.
Definition at line 481 of file primitives/LineString.h.
|
inline |
Remove all points, making the linestring invalid until new points are inserted.
Definition at line 470 of file primitives/LineString.h.
|
inline |
mutable iterator to the end of the elements of this vector.
Definition at line 484 of file primitives/LineString.h.
|
inline |
Removes point, returns iterator to the next point.
Definition at line 439 of file primitives/LineString.h.
|
inline |
get a refernce to the first element (make sure it exists)
Definition at line 487 of file primitives/LineString.h.
|
inline |
Inserts an element at a specific position.
Just as you would expect from an std::vector... If you plan to insert more elements than one, use the ranged version below. That saves you from some unnecessary cache regenerations.
Definition at line 413 of file primitives/LineString.h.
|
inline |
Inserts an range of elements at a specific position.
Definition at line 421 of file primitives/LineString.h.
|
protecteddefault |
|
protecteddefaultnoexcept |
|
inline |
Move assign from a normal vector. Id and attributes stay unchanged.
Definition at line 398 of file primitives/LineString.h.
|
inline |
Copy assign from a normal vector. The Id of this object is unchanged.
Definition at line 388 of file primitives/LineString.h.
|
inline |
access element at specific position
Definition at line 493 of file primitives/LineString.h.
|
inlineprotected |
Definition at line 515 of file primitives/LineString.h.
|
inline |
removes element from the end
Definition at line 449 of file primitives/LineString.h.
|
inline |
inserts a new element at the end
Definition at line 434 of file primitives/LineString.h.
|
inline |
request a change in capacity
Definition at line 454 of file primitives/LineString.h.
|
inline |
Changes the number of points contained either by deleting them or by inserting new (invalId points).
Definition at line 458 of file primitives/LineString.h.
|
inlinenoexcept |
returns the n-th segment. If n equals size() -1, the segment from back() to front() is returned.
Definition at line 502 of file primitives/LineString.h.