#include <core/object.h>
Public Types | |
typedef shm< char >::string | Attribute |
typedef shm< char >::string | Key |
typedef shm< Attribute >::vector | AttributeList |
typedef std::pair< const Key, AttributeList > | AttributeMapValueType |
typedef shm< AttributeMapValueType >::allocator | AttributeMapAllocator |
typedef interprocess::map< Key, AttributeList, std::less< Key >, AttributeMapAllocator > | AttributeMap |
typedef std::map< std::string, std::vector< std::string > > | StdAttributeMap |
typedef boost::interprocess::scoped_lock< boost::interprocess::interprocess_recursive_mutex > | attachment_mutex_lock_type |
typedef interprocess::offset_ptr< const ObjectData > | Attachment |
typedef std::pair< const Key, Attachment > | AttachmentMapValueType |
typedef shm< AttachmentMapValueType >::allocator | AttachmentMapAllocator |
typedef interprocess::map< Key, Attachment, std::less< Key >, AttachmentMapAllocator > | AttachmentMap |
Public Types inherited from vistle::ShmData | |
enum | ShmType { INVALID , OBJECT , ARRAY } |
Public Member Functions | |
void | addAttribute (const std::string &key, const std::string &value="") |
V_COREEXPORT void | setAttributeList (const std::string &key, const std::vector< std::string > &values) |
void | copyAttributes (const ObjectData *src, bool replace) |
bool | hasAttribute (const std::string &key) const |
std::string | getAttribute (const std::string &key) const |
V_COREEXPORT std::vector< std::string > | getAttributes (const std::string &key) const |
V_COREEXPORT std::vector< std::string > | getAttributeList () const |
bool | addAttachment (const std::string &key, Object::const_ptr att) |
void | copyAttachments (const ObjectData *src, bool replace) |
bool | hasAttachment (const std::string &key) const |
Object::const_ptr | getAttachment (const std::string &key) const |
bool | removeAttachment (const std::string &key) |
V_COREEXPORT | ObjectData (Object::Type id=Object::UNKNOWN, const std::string &name="", const Meta &m=Meta()) |
V_COREEXPORT | ObjectData (const ObjectData &other, const std::string &name, Object::Type id=Object::UNKNOWN) |
V_COREEXPORT | ~ObjectData () |
shallow copy, except for attributes More... | |
V_COREEXPORT void * | operator new (size_t size) |
V_COREEXPORT void * | operator new (std::size_t size, void *ptr) |
V_COREEXPORT void | operator delete (void *ptr) |
V_COREEXPORT void | operator delete (void *ptr, void *voidptr2) |
V_COREEXPORT int | ref () const |
V_COREEXPORT int | unref () const |
V_COREEXPORT bool | isComplete () const |
V_COREEXPORT void | unresolvedReference () |
check whether all references have been resolved More... | |
V_COREEXPORT void | referenceResolved (const std::function< void()> &completeCallback) |
template<class Archive > | |
ARCHIVE_ACCESS_SPLIT void | save (Archive &ar) const |
template<class Archive > | |
void | load (Archive &ar) |
ObjectData (const ObjectData &)=delete | |
ObjectData & | operator= (const ObjectData &)=delete |
Public Member Functions inherited from vistle::ShmData | |
ShmData (ShmType t, const std::string &name=std::string()) | |
~ShmData () | |
int | ref () const |
int | unref () const |
int | refcount () const |
Static Public Member Functions | |
static ObjectData * | create (Object::Type id, const std::string &name, const Meta &m) |
Public Attributes | |
Object::Type | type |
std::atomic< int > | unresolvedReferences |
no. of not-yet-available arrays and referenced objects More... | |
Meta | meta |
AttributeMap | attributes |
boost::interprocess::interprocess_recursive_mutex | attachment_mutex |
AttachmentMap | attachments |
Public Attributes inherited from vistle::ShmData | |
const shm_name_t | name |
std::atomic< int > | m_refcount |
const ShmType | shmtype = INVALID |
typedef interprocess::offset_ptr<const ObjectData> vistle::ObjectData::Attachment |
typedef boost::interprocess::scoped_lock<boost::interprocess::interprocess_recursive_mutex> vistle::ObjectData::attachment_mutex_lock_type |
typedef interprocess::map<Key, Attachment, std::less<Key>, AttachmentMapAllocator> vistle::ObjectData::AttachmentMap |
typedef std::pair<const Key, Attachment> vistle::ObjectData::AttachmentMapValueType |
typedef shm<char>::string vistle::ObjectData::Attribute |
typedef shm<Attribute>::vector vistle::ObjectData::AttributeList |
typedef interprocess::map<Key, AttributeList, std::less<Key>, AttributeMapAllocator> vistle::ObjectData::AttributeMap |
typedef std::pair<const Key, AttributeList> vistle::ObjectData::AttributeMapValueType |
typedef shm<char>::string vistle::ObjectData::Key |
typedef std::map<std::string, std::vector<std::string> > vistle::ObjectData::StdAttributeMap |
vistle::ObjectData::ObjectData | ( | Object::Type | id = Object::UNKNOWN , |
const std::string & | name = "" , |
||
const Meta & | m = Meta() |
||
) |
vistle::ObjectData::ObjectData | ( | const ObjectData & | other, |
const std::string & | name, | ||
Object::Type | id = Object::UNKNOWN |
||
) |
vistle::ObjectData::~ObjectData | ( | ) |
shallow copy, except for attributes
|
delete |
bool vistle::Object::Data::addAttachment | ( | const std::string & | key, |
Object::const_ptr | att | ||
) |
void vistle::Object::Data::addAttribute | ( | const std::string & | key, |
const std::string & | value = "" |
||
) |
void vistle::Object::Data::copyAttachments | ( | const ObjectData * | src, |
bool | replace | ||
) |
void vistle::Object::Data::copyAttributes | ( | const ObjectData * | src, |
bool | replace | ||
) |
|
static |
Object::const_ptr vistle::ObjectData::getAttachment | ( | const std::string & | key | ) | const |
std::string vistle::Object::Data::getAttribute | ( | const std::string & | key | ) | const |
std::vector< std::string > vistle::Object::Data::getAttributeList | ( | ) | const |
std::vector< std::string > vistle::Object::Data::getAttributes | ( | const std::string & | key | ) | const |
bool vistle::Object::Data::hasAttachment | ( | const std::string & | key | ) | const |
bool vistle::Object::Data::hasAttribute | ( | const std::string & | key | ) | const |
bool vistle::Object::Data::isComplete | ( | ) | const |
void vistle::Object::Data::load | ( | Archive & | ar | ) |
void vistle::Object::Data::operator delete | ( | void * | ptr | ) |
void vistle::Object::Data::operator delete | ( | void * | ptr, |
void * | voidptr2 | ||
) |
void * vistle::Object::Data::operator new | ( | size_t | size | ) |
void * vistle::Object::Data::operator new | ( | std::size_t | size, |
void * | ptr | ||
) |
|
delete |
int vistle::ObjectData::ref | ( | ) | const |
void vistle::ObjectData::referenceResolved | ( | const std::function< void()> & | completeCallback | ) |
bool vistle::Object::Data::removeAttachment | ( | const std::string & | key | ) |
ARCHIVE_ACCESS_SPLIT void vistle::ObjectData::save | ( | Archive & | ar | ) | const |
void vistle::Object::Data::setAttributeList | ( | const std::string & | key, |
const std::vector< std::string > & | values | ||
) |
int vistle::ObjectData::unref | ( | ) | const |
void vistle::ObjectData::unresolvedReference | ( | ) |
check whether all references have been resolved
|
mutable |
AttachmentMap vistle::ObjectData::attachments |
AttributeMap vistle::ObjectData::attributes |
Meta vistle::ObjectData::meta |
Object::Type vistle::ObjectData::type |
std::atomic<int> vistle::ObjectData::unresolvedReferences |
no. of not-yet-available arrays and referenced objects