Go to the documentation of this file.
26 enum { Mutable = 1 << 1, Const = 1 << 2 };
37 void*
ptr() {
return m_P; }
38 const void*
ptr()
const {
return m_P; }
39 virtual long size()
const = 0;
46 Tag(
long f,
const std::type_info&
s ) : first( f ),
second(
s ) {}
55 _V(
const T&
v ) : m_O(
v ) { m_P = &m_O; }
56 virtual long size()
const {
return sizeof( T ); }
57 virtual void construct(
void* b )
const { ::new ( b ) T(); }
63 _TT() :
Tag( sizeof( T ), typeid( T ) ) {}
70 const std::string& comment,
long flag ) = 0;
73 const std::string& comment ) = 0;
76 const void* pOwner,
const Tag& otag,
const std::string& comment,
80 const void* pOwner,
const Tag& otag,
const std::string& comment ) = 0;
85 template <
class T,
class O>
87 return inspectByRef( pObj,
_TT<T>(), (
void*)pOwner,
_TT<O>(), comment, flag );
90 template <
class T,
class O>
92 return inspectByValue(
new _V<T>( obj ),
_TT<T>(), (
void*)pOwner,
_TT<O>(), comment );
95 template <
class T,
class O>
97 typedef typename T::value_type _VVV;
98 typedef typename T::value_type _TTT;
104 template <
class T,
class O>
106 typedef typename T::value_type _VVV;
107 typedef typename T::value_type _TTT;
virtual long size() const
virtual ~IValue()=default
virtual long size() const =0
virtual StatusCode inspectByValue(IValue *pObj, const Tag &typ, void *pOwner, const Tag &oTag, const std::string &comment)=0
Inspect object by Value.
DeclareInterfaceID(IInspector, 1, 0)
InterfaceID.
StatusCode inspectContByValue(const T &obj, const O *pOwner, const std::string &comment)
Inspect container of object items by its value (const)
virtual StatusCode inspectByRef(const void *pObj, const Tag &typ, void *pOwner, const Tag &otag, const std::string &comment, long flag)=0
Inspect object by Reference.
virtual void construct(void *b) const
virtual StatusCode inspectContByValue(IValue *pObj, const Tag &tag, const Tag &rtag, const Tag &vtag, const void *pOwner, const Tag &otag, const std::string &comment)=0
Inspect container of objects by value.
StatusCode inspectContByRef(const T *pObj, const O *pOwner, const std::string &comment, long flag=Mutable)
Inspect container of object items by its reference (mutable and const)
StatusCode inspectByRef(const T *pObj, const O *pOwner, const std::string &comment, long flag=Mutable)
Inspect single item by its reference (mutable and const)
Tag(long f, const std::type_info &s)
const std::type_info & second
virtual void construct(void *buffer) const =0
StatusCode inspectByValue(const T &obj, const O *pOwner, const std::string &comment)
Inspect single item by its value (const)
virtual StatusCode inspectContByRef(const void *pObj, const Tag &tag, const Tag &rtag, const Tag &vtag, const void *pOwner, const Tag &otag, const std::string &comment, long flags)=0
Inspect container of objects by reference.