13 #include "filexml.inc"
16 #include "pluginserver.inc"
17 #include "sharedlocation.h"
19 class Assets
: public List
<Asset
>
25 int load(ArrayList
<PluginServer
*> *plugindb
,
28 int save(ArrayList
<PluginServer
*> *plugindb
,
31 Assets
& operator=(Assets
&assets
);
32 void copy_from(Assets
*assets
);
34 // Enter a new asset into the table.
35 // If the asset already exists return the asset which exists.
36 // If the asset doesn't exist, store a copy of the argument and return the copy.
37 Asset
* update(Asset
*asset
);
38 // Update the index information for assets with the same path
39 void update_index(Asset
*asset
);
56 // return the asset containing this path or create a new asset containing this path
57 Asset
* update(const char *path
);
59 // Insert the asset into the list if it doesn't exist already but
60 // don't create a new asset.
61 void update_ptr(Asset
*asset
);
63 // return the asset containing this path or 0 if not found
64 Asset
* get_asset(const char *filename
);
65 // remove asset from table
66 Asset
* remove_asset(Asset
*asset
);
68 // return number of the asset
69 int number_of(Asset
*asset
);
70 Asset
* asset_number(int number
);
72 int update_old_filename(char *old_filename
, char *new_filename
);