FBAssetMng Class Reference


Detailed Description

Used to access asset manager functionity to get files locally or from a server.

Inheritance diagram for FBAssetMng:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  __init__ (str pName, object pObject=None)
  Constructor.
  IObject_Declare (Implementation)
bool  Initialize ()
  Initialize the connection to the server.
HFBAssetFile  BrowseForFile ()
  Let the user browse the asset database to select a file.
HFBAssetFolder  BrowseForFolder ()
  Let the user browse the asset database to select a folder.
HFBAssetFolder  CreateServerPath (str pServerPath)
  Create a folder path on the server side by adding each missing folders.
bool  FileIsManaged (str pFilename)
  Is the specified local file managed (ie.
bool  WithinManagedPath (str pLocalPath)
  Is the specified local path below a managed path.
str  MapLocalPathToServerPath (str pLocalPath)
  Convert the local path to a server path by using managed paths mapping.
HFBAssetFile  GetAssetFile (str pServerFilename)
  Get a file object using it's server path.
HFBAssetFile  GetAssetFileFromLocalPath (str pLocalFilename)
  Get a file object using it's local path.
HFBAssetFolder  GetAssetFolder (str pServerPath)
  Get a folder object using it's server path.
HFBAssetFolder  GetAssetFolderFromLocalPath (str pLocalPath)
  Get a folder object using it's local path.
  ShowSettings ()
  Display a dialog that let the user changes settings.
int  GetFileOptions ()
  Get the file options (i.e.
bool  CheckAvailability ()
  Check if this manager can be used on the computer.

Public Attributes

FBPropertyString  Name
  Read Write Property: Unique Name.
FBPropertyString  Description
  Read Write Property: Description of the manager.
FBPropertyBase  MenuFlags
  Read Write Property: Flags specifing which menu items are added by the manager.
str  LastError
  Last error string.

Member Function Documentation

__init__ ( str  pName,
object  pObject = None 
)

Constructor.

Parameters:
pName Name of Command.
pObject Internal parent object to own FBComponent (default is NULL).
IObject_Declare ( Implementation  )
bool Initialize ( )

Initialize the connection to the server.

Returns:
True if the connection was established, false otherwise.
HFBAssetFile BrowseForFile ( )

Let the user browse the asset database to select a file.

Returns:
A file object representing the file that was selected, or NULL if none.
HFBAssetFolder BrowseForFolder ( )

Let the user browse the asset database to select a folder.

Returns:
A HFBAssetFolder object representing the folder that was selected, or NULL if none.
HFBAssetFolder CreateServerPath ( str  pServerPath )

Create a folder path on the server side by adding each missing folders.

Parameters:
pServerPath The path to create on the server side.
Returns:
A HFBAssetFolder object representing the deepest folder of the path.
bool FileIsManaged ( str  pFilename )

Is the specified local file managed (ie.

also present in the database).

Parameters:
pFilename Path to the file on the local disk.
Returns:
A boolean indicating if the file is managed or not.
bool WithinManagedPath ( str  pLocalPath )

Is the specified local path below a managed path.

Parameters:
pLocalPath Local path to be checked.
Returns:
A boolean indicating if the path is within a managed path or not.
str MapLocalPathToServerPath ( str  pLocalPath )

Convert the local path to a server path by using managed paths mapping.

Parameters:
pLocalPath Local path to be mapped.
Returns:
A string with the resulting server path, will be empty if the mapping fail.
HFBAssetFile GetAssetFile ( str  pServerFilename )

Get a file object using it's server path.

Parameters:
pServerFilename Path to the file on the server.
Returns:
An HFBAssetFile object, or NULL if the file was not found.
HFBAssetFile GetAssetFileFromLocalPath ( str  pLocalFilename )

Get a file object using it's local path.

Parameters:
pLocalFilename Path to the file on the local disk.
Returns:
An HFBAssetFile object, or NULL if the file was not found or no mapping could be done.
HFBAssetFolder GetAssetFolder ( str  pServerPath )

Get a folder object using it's server path.

Parameters:
pServerPath Path the the folder on the server.
Returns:
An HFBAssetFolder object, or NULL if the folder was not found.
HFBAssetFolder GetAssetFolderFromLocalPath ( str  pLocalPath )

Get a folder object using it's local path.

Parameters:
pLocalPath Path to the folder on the local disk.
Returns:
An HFBAssetFolder object, or NULL if the folder was not found or no mapping could be done.
ShowSettings ( )

Display a dialog that let the user changes settings.

int GetFileOptions ( )

Get the file options (i.e.

what to do when loading, saving or closing managed files).

Returns:
The options.
bool CheckAvailability ( )

Check if this manager can be used on the computer.


Member Data Documentation

Read Write Property: Unique Name.

Reimplemented from FBComponent.

Read Write Property: Description of the manager.

FBPropertyBase MenuFlags

Read Write Property: Flags specifing which menu items are added by the manager.


FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng
FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng FBAssetMng