quick start:g++ [flags ...] file ... #include <Wrapper.h> Wrapper(); boolean assign(const Wrapper<TObject>& arg); boolean assign(const TObject& arg);
// declare a character wrapper and insert a character in it
//
Wrapper<Char> wrapper0;
Char item(L'a');
wrapper0.assign(&item);
// use the copy constructor to create a second wrapper
//
Wrapper<Char> wrapper1(wrapper0);
// get the items out of each of the wrappers
//
Char* char1 = wrapper0.getItem();
Char* char2 = wrapper1.getItem();
// test the characters for equality
//
if (!char1->eq(*char2)) {
// error
}
description:
static const SysString CLASS_NAME = L"Wrapper";
static const SysString DEF_PARAM = L"item";
static const long ERR = 42100;
static const long ERR_NOTDEF = 42101;
static Integral::DEBUG debug_level_d;
static MemoryManager mgr_d;
static const String& name();
static boolean diagnose(Integral::DEBUG debug_level);
boolean debug(const unichar* message) const;
static boolean setDebug(Integral::DEBUG debug_level);
~Wrapper();
Wrapper();
Wrapper(const Wrapper<TObject>& copy_wrapper);
boolean assign(const Wrapper<TObject>& copy_wrapper);
Wrapper<TObject>& operator=(const Wrapper<TObject>& arg);
long sofSize() const;
boolean read(Sof& sof, long tag);
boolean read(Sof& sof, long tag, const String& name);
boolean write(Sof& sof, long tag) const;
boolean write(Sof& sof, long tag, const String& name) const;
boolean readData(Sof& sof, const String& pname = DEF_PARAM,long size = SofParser::FULL_OBJECT, boolean param = true, boolean nested = false);
boolean writeData(Sof& sof, const String& pname = DEF_PARAM) const;
boolean eq(const Wrapper<TObject>& compare_wrapper) const;
static void* operator new(size_t size);
static void* operator new[](size_t size);
static void operator delete(void* ptr);
static void operator delete[](void* ptr);
static boolean setGrowSize(long grow_size);
boolean clear(Integral::CMODE cmode_a = Integral::DEF_CMODE);
Wrapper(const TObject& arg);
boolean assign(const TObject& arg);
Wrapper<TObject>& operator=(const TObject& arg);
friend class WrapperDiagnose;examples: