From 1232eb1c587ffdc06c26a1c5b1b4fa5f22848754 Mon Sep 17 00:00:00 2001 From: Tleiades Hax Date: Sat, 13 Oct 2007 07:26:21 +0000 Subject: Asset server implementation. Again one of these "plumbing" releases, where no real functionality has been introduced, but ground work has been made, enabling the asset server, and preparing the sim server to query the asset server. Introduced an "IPlugin" interface, which plugins can inherit from. --- OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/Data.SQLite') diff --git a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs index 4616275..922d714 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs @@ -53,7 +53,7 @@ namespace OpenSim.Framework.Data.SQLite private const string assetSelect = "select * from assets"; private DataSet ds; private SqliteDataAdapter da; - + public void Initialise(string dbfile, string dbname) { SqliteConnection conn = new SqliteConnection("URI=file:" + dbfile + ",version=3"); @@ -275,5 +275,26 @@ namespace OpenSim.Framework.Data.SQLite return true; } + #region IPlugin interface + public string Version { + get + { + System.Reflection.Module module = this.GetType().Module; + string dllName = module.Assembly.ManifestModule.Name; + Version dllVersion = module.Assembly.GetName().Version; + + return string.Format("{0}.{1}.{2}.{3}", dllVersion.Major, dllVersion.Minor, dllVersion.Build, dllVersion.Revision); + } + } + + public void Initialise() + { + Initialise("AssetStorage.db", ""); + } + + public string Name { + get { return "SQLite Asset storage engine"; } + } + #endregion } } -- cgit v1.1