1 #ifndef __FBASSETMNG_H__ 2 #define __FBASSETMNG_H__ 43 #include <kaydaradef.h> 48 #define FBSDK_DLL K_DLLIMPORT 53 #ifdef FBSDKUseNamespace 78 FBAssetItem(
const char* pName, HIObject pObject=NULL );
83 virtual FBString GetName()
const = 0;
88 virtual FBString GetLocalPath()
const = 0;
93 virtual FBString GetServerPath()
const = 0;
105 virtual bool GetLatest(
bool pReplaceCheckedOut =
false,
bool pSilent =
false ) = 0;
113 virtual bool CheckIn(
const FBString& pComment =
"",
bool pKeepCheckedOut =
false,
bool pSilent =
false ) = 0;
122 virtual bool CheckOut(
const FBString& pComment =
"",
bool pDontGetLocal =
false,
bool pSilent =
false ) = 0;
129 virtual bool UndoCheckOut(
bool pReplaceLocalFile =
true,
bool pSilent =
false ) = 0;
133 virtual void ShowHistory()
const = 0;
137 virtual void ShowProperties()
const = 0;
153 #define FBRegisterAssetFile( UniqueNameStr, ClassName, Label, Desc, IconFilename ) \ 154 HIObject RegisterAssetFile##ClassName( HIObject ,const char* pName,void * ) \ 156 ClassName *Class = new ClassName( Label ); \ 157 Class->mAllocated = true; \ 158 Class->Name = UniqueNameStr; \ 159 if (Class->FBCreate()) { \ 160 return Class->GetHIObject(); \ 166 FBLibraryModule( ClassName ) \ 168 FBRegisterObject( ClassName,"Asset/AssetItem/AssetFile",Label,Desc,RegisterAssetFile##ClassName, true, IconFilename ); \ 175 #define FBAssetFileDeclare( ClassName, Parent ) \ 176 FBClassDeclare( ClassName,Parent); \ 178 ClassName(const char* pName):Parent(pName) { FBClassInit; } \ 184 #define FBAssetFileImplementation( ThisComponent ) \ 185 FBClassImplementation( ThisComponent ) 200 FBAssetFile(
const char* pName, HIObject pObject=NULL );
202 IObject_Declare(K_IMPLEMENTATION);
207 virtual bool FBCreate();
212 virtual bool IsCheckedOut()
const = 0;
217 virtual bool IsCheckedOutByMe()
const = 0;
222 virtual FBString GetCheckedOutBy()
const = 0;
236 #define FBRegisterAssetFolder( UniqueNameStr, ClassName, Label, Desc, IconFilename ) \ 237 HIObject RegisterAssetFolder##ClassName( HIObject ,const char* pName,void * ) \ 239 ClassName *Class = new ClassName( Label ); \ 240 Class->mAllocated = true; \ 241 Class->Name = UniqueNameStr; \ 242 if (Class->FBCreate()) { \ 243 return Class->GetHIObject(); \ 249 FBLibraryModule( ClassName ) \ 251 FBRegisterObject( ClassName,"Asset/AssetItem/AssetFolder",Label,Desc,RegisterAssetFolder##ClassName, true, IconFilename ); \ 258 #define FBAssetFolderDeclare( ClassName, Parent ) \ 259 FBClassDeclare( ClassName,Parent); \ 261 ClassName(const char* pName):Parent(pName) { FBClassInit; } \ 267 #define FBAssetFolderImplementation( ThisComponent ) \ 268 FBClassImplementation( ThisComponent ) 285 IObject_Declare(K_IMPLEMENTATION);
290 virtual bool FBCreate();
295 virtual int GetChildCount()
const = 0;
319 virtual FBAssetFile* AddFile(
const FBString& pLocalPath,
const FBString& pComment =
"",
bool pCheckOut =
false,
bool pSilent =
false ) = 0;
341 #define FBRegisterAssetMng( UniqueNameStr, ClassName, Label, Desc, IconFilename ) \ 342 HIObject RegisterAssetMng##ClassName( HIObject ,const char* pName,void * ) \ 344 ClassName *Class = new ClassName( Label ); \ 345 Class->mAllocated = true; \ 346 Class->Name = UniqueNameStr; \ 347 Class->Description = Desc; \ 348 if (Class->FBCreate()) { \ 349 return Class->GetHIObject(); \ 355 FBLibraryModule( ClassName ) \ 357 FBRegisterObject( ClassName,"Asset/AssetMng",Label,Desc,RegisterAssetMng##ClassName, false, IconFilename ); \ 364 #define FBAssetMngDeclare( ClassName, Parent ) \ 365 FBClassDeclare( ClassName,Parent); \ 367 ClassName(const char* pName):Parent(pName) { FBClassInit; } \ 373 #define FBAssetMngImplementation( ThisComponent ) \ 374 FBClassImplementation( ThisComponent ) 426 kFileOptionsAll = 0xFFFFFFFF
441 FBAssetMng(
const char* pName, HIObject pObject=NULL );
443 IObject_Declare(K_IMPLEMENTATION);
448 virtual bool Initialize() = 0;
470 virtual bool FileIsManaged(
const FBString& pFilename ) = 0;
476 virtual bool WithinManagedPath(
const FBString& pLocalPath ) = 0;
482 virtual FBString MapLocalPathToServerPath(
const FBString& pLocalPath ) = 0;
510 virtual void ShowSettings() = 0;
515 virtual int GetFileOptions() = 0;
519 virtual bool CheckAvailability()
const = 0;
527 #ifdef FBSDKUseNamespace Version Control -> Show Properties.
Support only the basics functionalities.
Version Control -> Check In.
#define __FBClassDeclare(Name, Parent)
For internal use only.
Version Control -> Disable Version Control Integration.
Used to access asset manager functionity to get files locally or from a server.
FBPropertyInt MenuFlags
Read Write Property: Flags specifing which menu items are added by the manager.
FBAssetMngMenuOptions
Show or hide version control menu items.
FB_DEFINE_COMPONENT(K_DLLIMPORT, AnimationNode)
Animation node class.
FBAssetMngFileOptions
Behavior of the application when working with managed files.
Version Control -> Show Settings.
Class representing a file stored in a version control database.
Version Control -> Undo Check Out.
FBPropertyString Description
Read Write Property: Description of the manager.
File -> Upload to database.
Base class for all managed assets.
Class representing a folder stored in a version control database.
#define FBSDK_DLL
Be sure that FBSDK_DLL is defined only once...
Version Control -> Show History.
Support all elements from the Version Control menu.
FBString LastError
Last error string.
Check in file automatically when closing it.
Version Control -> Show Reference Manager.
Ask for adding new file on save.
FBString LastError
Last error string.
Ask for checkout on load.
Ask for check in file when closing it.
Support all elements from the File menu.
FBPropertyString Name
Read Write Property: Unique Name.
#define __FB_FORWARD(ClassName)
Forwarding of class and typedef declaration.
#define FBSDKNamespace
FBSDKNamespace define.
Property class: const char * (String).
Upload file automatically on save.
Add new file automatically on save.
Version Control -> Show Explorer.
class K_DLLIMPORT FBPropertyBase< int, kFBPT_int > FBPropertyInt
Property: int
Version Control -> Get Latest.
MotionBuilder SDK base class.
File -> Open from database.
Version Control -> Check Out.
Check out file automatically on load.