|
|
| SPR_IFDEF (UTTypeDesc) |
| |
|
void | SetSize (size_t sz) |
| |
|
void | SetAccess (UTAccessBase *a) |
| |
|
void | SetOffset (int field, int offset) |
| |
|
void | SetIfInfo (const IfInfo *info) |
| |
|
int | AddField (std::string pre, std::string ty, std::string n, std::string post) |
| |
|
int | AddBase (std::string tn) |
| |
|
void | AddEnumConst (int field, std::string name, int val) |
| |
|
void | Print (std::ostream &os) const |
| | 表示
|
| |
|
std::string | GetTypeName () const |
| | 型名
|
| |
|
void | SetTypeName (const char *s) |
| | 型名
|
| |
|
size_t | GetSize () |
| | 型のサイズ
|
| |
|
bool | IsPrimitive () |
| | 組み立て型かどうか
|
| |
|
bool | IsSimple () |
| | 文字列やvectorや参照を含まなければ true
|
| |
|
int | NFields () |
| | 組み立て型のフィールドの数
|
| |
|
UTTypeDescIf * | GetFieldType (int i) |
| | フィールドのTypeDesc
|
| |
|
int | GetFieldLength (int i) |
| | Fieldが配列の場合の配列の長さを返す
|
| |
|
int | GetFieldVectorSize (int i, const void *base) |
| | Fieldのvector場合のvectorの長さを返す
|
| |
|
const char * | GetFieldLengthName (int i) |
| | 要素数を別のフィールドからとる場合のフィールド名
|
| |
|
UTTypeDescIf::FieldType | GetFieldVarType (int i) |
| | vector/配列かどうか
|
| |
|
bool | GetFieldIsReference (int i) |
| | 参照かどうか
|
| |
|
const char * | GetFieldName (int i) |
| | フィールド名
|
| |
|
void * | GetFieldAddress (int i, void *base, int pos) |
| | フィールドのアドレスの取得
|
| |
|
const void * | GetFieldAddress (int i, const void *base, int pos) |
| |
|
void * | GetFieldAddressEx (int i, void *base, int pos) |
| | フィールドのアドレスを計算.vectorを拡張する.
|
| |
|
std::string | ReadToString (int i, void *base, int pos) |
| | 文字列にフィールドを読み出す
|
| |
|
void | WriteFromString (std::string from, int i, void *base, int pos) |
| | 文字列からフィールドに書き込む
|
| |
|
const IfInfo * | GetIfInfoOfType () |
| |
|
bool | IsBool () |
| |
|
bool | IsNumber () |
| |
|
bool | IsString () |
| |
|
bool | ReadBool (const void *ptr) |
| | TypeDescがboolの単純型の場合に,boolを読み出す関数
|
| |
|
void | WriteBool (bool val, void *ptr) |
| | TypeDescが数値の単純型の場合に,数値を書き込む関数
|
| |
|
double | ReadNumber (const void *ptr) |
| | TypeDescが数値の単純型の場合に,数値を読み出す関数
|
| |
|
void | WriteNumber (double val, void *ptr) |
| | TypeDescが数値の単純型の場合に,数値を書き込む関数
|
| |
|
std::string | ReadString (const void *ptr) |
| | 文字列読み出し
|
| |
|
void | WriteString (const char *val, void *ptr) |
| | 文字列書き込み
|
| |
|
void * | Create () |
| | オブジェクトの構築
|
| |
|
void | Delete (void *ptr) |
| | オブジェクトの後始末
|
| |
|
void * | VectorPush (void *v) |
| | vector::push_back() return &vector::back();
|
| |
|
void | VectorPop (void *v) |
| | vector::pop_back();
|
| |
|
void * | VectorAt (void *v, int pos) |
| | return &vector::at(pos);
|
| |
|
const void * | VectorAt (const void *v, int pos) |
| |
|
size_t | VectorSize (const void *v) |
| | return vector::size();
|
| |
|
size_t | SizeOfVector () |
| |
|
void | Write (std::ostream &os, void *base) |
| | ストリームに書き出し
|
| |
|
void | Read (std::istream &is, void *base) |
| | ストリームから読み出し
|
| |
|
| SPR_IFDEF (Object) |
| |
|
ObjectIf * | GetObjectIf () |
| |
|
const ObjectIf * | GetObjectIf () const |
| |
|
int | DelRef () const |
| |
|
void | Print (std::ostream &os) const |
| | デバッグ用の表示。子オブジェクトを含む。
|
| |
|
void | PrintShort (std::ostream &os) const |
| | デバッグ用の表示。子オブジェクトを含まない。
|
| |
|
void | DumpObjectR (std::ostream &os, int level=0) const |
| | オブジェクトツリーのメモリイメージをダンプ
|
| |
|
int | AddRef () |
| |
|
int | RefCount () |
| |
|
size_t | NChildObject () const |
| | 子オブジェクトの数
|
| |
|
ObjectIf * | GetChildObject (size_t pos) |
| | 子オブジェクトの取得
|
| |
|
const ObjectIf * | GetChildObject (size_t pos) const |
| |
|
bool | AddChildObject (ObjectIf *o) |
| | 子オブジェクトの追加.複数のオブジェクトの子オブジェクトとして追加してよい. 例えば,GRFrameはツリーを作るが,全ノードがGRSceneの子でもある.
|
| |
|
bool | DelChildObject (ObjectIf *o) |
| | 子オブジェクトの削除
|
| |
|
void | Clear () |
| | すべての子オブジェクトの削除と、プロパティのクリア
|
| |
|
ObjectIf * | CreateObject (const IfInfo *info, const void *desc) |
| | オブジェクトを作成し,AddChildObject()を呼ぶ.
|
| |
|
template<class T > |
| ObjectIf * | CreateObject (const T &desc) |
| | CreateObjectを呼び出すユーティリティ関数
|
| |
|
const void * | GetDescAddress () const |
| | デスクリプタの読み出し(参照版 NULLを返すこともある). これが実装されていなくても,ObjectIf::GetDesc()は実装されていることが多い.
|
| |
|
bool | GetDesc (void *desc) const |
| | デスクリプタの読み出し(コピー版 失敗する(falseを返す)こともある). ObjectIf::GetDescAddress() が実装されていなくても,こちらは実装されていることがある.
|
| |
|
void | SetDesc (const void *desc) |
| | デスクリプタの設定
|
| |
|
size_t | GetDescSize () const |
| | デスクリプタのサイズ
|
| |
|
const void * | GetStateAddress () const |
| | 状態の読み出し(参照版 NULLを返すこともある). これが実装されていなくても,ObjectIf::GetState()は実装されていることがある.
|
| |
|
bool | GetState (void *state) const |
| | 状態の読み出し(コピー版 失敗する(falseを返す)こともある). ObjectIf::GetStateAddress() が実装されていなくても,こちらは実装されていることがある.
|
| |
|
void | SetState (const void *state) |
| | 状態の設定
|
| |
|
bool | WriteStateR (std::ostream &fout) |
| | 状態の書き出し
|
| |
|
bool | WriteState (std::string fileName) |
| |
|
bool | ReadStateR (std::istream &fin) |
| | 状態の読み込み
|
| |
|
bool | ReadState (std::string fileName) |
| |
|
size_t | GetStateSize () const |
| | 状態のサイズ
|
| |
|
void | ConstructState (void *m) const |
| | メモリブロックを状態型に初期化
|
| |
|
void | DestructState (void *m) const |
| | 状態型をメモリブロックに戻す
|
| |