2022-10-09 05:13:17 +00:00
|
|
|
#ifndef _CFACTORYMGR
|
|
|
|
#define _CFACTORYMGR
|
2022-04-10 00:17:06 +00:00
|
|
|
|
|
|
|
#include "types.h"
|
|
|
|
|
2022-08-09 23:03:51 +00:00
|
|
|
#include "Kyoto/IObjectStore.hpp"
|
|
|
|
#include "Kyoto/Streams/CInputStream.hpp"
|
2022-09-18 06:05:46 +00:00
|
|
|
#include "Kyoto/TToken.hpp"
|
2022-07-14 16:24:26 +00:00
|
|
|
|
2022-04-10 00:17:06 +00:00
|
|
|
class CFactoryMgr {
|
|
|
|
public:
|
|
|
|
private:
|
2022-10-09 05:37:23 +00:00
|
|
|
uchar pad[0x38];
|
2022-04-10 00:17:06 +00:00
|
|
|
};
|
|
|
|
|
2022-07-14 16:24:26 +00:00
|
|
|
class CFactoryFnReturn {
|
|
|
|
public:
|
|
|
|
template < typename T >
|
2023-01-08 01:42:15 +00:00
|
|
|
CFactoryFnReturn(T* ptr) : obj(TToken< T >::GetIObjObjectFor(ptr).release()) {}
|
2022-07-14 16:24:26 +00:00
|
|
|
|
2023-01-14 06:40:19 +00:00
|
|
|
const rstl::auto_ptr<CObjOwnerDerivedFromIObjUntyped>& GetObjForTransfer() const { return obj; }
|
2022-07-14 16:24:26 +00:00
|
|
|
private:
|
2022-08-13 01:26:00 +00:00
|
|
|
rstl::auto_ptr< CObjOwnerDerivedFromIObjUntyped > obj;
|
2022-07-14 16:24:26 +00:00
|
|
|
};
|
|
|
|
|
2022-09-18 06:05:46 +00:00
|
|
|
CFactoryFnReturn FStringTableFactory(const SObjectTag& tag, CInputStream& in,
|
|
|
|
const CVParamTransfer& xfer);
|
2022-07-14 16:24:26 +00:00
|
|
|
|
2022-10-09 05:13:17 +00:00
|
|
|
#endif // _CFACTORYMGR
|