Mike Mazur wrote:
> Hi,
> 
> In Cable Beach all asset information is split over two datatypes:
> 
> - the Metadata class[1]
> - a byte array containing the actual asset data
> 
> In OpenSim we have the AssetBase class[2] which contains asset metadata
> and data together. I'd like to modify the AssetBase class in OpenSim
> so it's composed of one Metadata class.
> 
> So instead of having:
> 
>   AssetBase ab = new AssetBase();
>   ab.Name = "some name";
>   ab.Description = "some description";
> 
> I would write:
> 
>   AssetBase ab = new AssetBase();
>   ab.Metadata.Name = "some name";
>   ab.Metadata.Description = "some description";
> 

Just to clarify, you're anticipating changing the OpenSim.Framework.AssetBase 
class (instead of having a parallel class 
in the AssetServer code)?  If so, sounds good to me.

> I would define the Metadata class in AssetBase.cs. The serialization
> and deserialization methods currently in the Metadata class may or may
> not be included; I see those methods belonging in the Utils class[3],
> perhaps.
> 
> The Metadata class itself will immediately be used within the new asset
> server, and I can see it being useful elsewhere in the future.
> 
> Should the Metadata class be renamed to AssetMetadata? Any other
> thoughts?

 From a readability perspective I would rather see it remain as just Metadata, 
since something like

AssetBase myAsset = new AssetBase();
myAsset.AssetMetadata.Name = "Heloooo";

looks kind of redundant to me (though this may just be a taste issue).

-- 
justincc
Justin Clark-Casey
http://justincc.wordpress.com
_______________________________________________
Opensim-dev mailing list
Opensim-dev@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/opensim-dev

Reply via email to