#include <TypesafePtr.h>
Public Member Functions | |
TypesafePtr () | |
TypesafePtr (const TypesafePtr &other)=delete | |
TypesafePtr (std::nullptr_t) | |
TypesafePtr (TypesafePtr &&other) | |
TypesafePtr (void *ptr, std::size_t nelem, const std::size_t *shape, std::size_t flags) | |
~TypesafePtr () | |
Here we create all the required instances 1: void 3: integral 4: floating 5: FILE 0x100: unsigned. More... | |
TypesafePtr | copy () const |
template<typename T > | |
std::enable_if< std::is_pointer< T >::value, T >::type | get () const |
template<typename T > | |
std::enable_if<!std::is_pointer< T >::value, T >::type | get () const |
template<typename T > | |
T | get (std::initializer_list< std::size_t > shape) const |
template<typename T > | |
T | get (std::size_t nelem) const |
std::size_t | getFlags () const noexcept |
std::size_t | getNelem () const noexcept |
void * | getRaw () const noexcept |
const std::size_t * | getShape () const noexcept |
operator bool () const noexcept | |
TypesafePtr & | operator= (const TypesafePtr &other)=delete |
TypesafePtr & | operator= (TypesafePtr &&other) |
template<typename T > | |
void | set (T val) const |
std::string | type_str () const |
Static Public Member Functions | |
static TypesafePtr | fromSafePtr (void *safe) |
static TypesafePtr | setNelemAndShape (const TypesafePtr &other, std::size_t nelem, const std::size_t *shape) |
static TypesafePtr | unchecked (const void *ptr) |
Static Public Attributes | |
static constexpr unsigned short | is_file =5 |
static constexpr unsigned short | is_floating_point =4 |
static constexpr unsigned short | is_integral =3 |
static const unsigned | maxrank =4 |
Private Member Functions | |
template<typename T > | |
T * | get_priv (std::size_t nelem, const std::size_t *shape, bool byvalue) const |
void | init_shape (const std::size_t *shape) |
Static Private Member Functions | |
static std::string | extra_msg () |
Private Attributes | |
std::array< char, 32 > | buffer |
std::size_t | flags =0 |
std::size_t | nelem =0 |
void * | ptr =nullptr |
std::array< std::size_t, maxrank+1 > | shape |
Class to deal with propoagation of typesafe pointers.
|
inline |
|
inline |
|
inline |
|
inline |
Here we create all the required instances 1: void 3: integral 4: floating 5: FILE 0x100: unsigned.
|
delete |
|
inline |
TypesafePtr PLMD::TypesafePtr::copy | ( | ) | const |
|
staticprivate |
|
static |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineprivate |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlineprivate |
|
inlinenoexcept |
|
delete |
|
inline |
|
inline |
|
inlinestatic |
|
inline |
|
inlinestatic |
|
private |
|
private |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
static |
|
private |
|
private |
|
private |
Hosted by GitHub
![]() |
![]() |