From fef3b3689492dea63693c964bcdbec9f5137eb5e Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Mon, 21 Apr 2008 07:09:17 +0000 Subject: * Optimised using statements and namespace references across entire project (this took a while to run). --- OpenSim/Data/AssetDataBase.cs | 3 --- OpenSim/Data/Base/BaseRowMapper.cs | 2 -- OpenSim/Data/Base/BaseSchema.cs | 1 - OpenSim/Data/Base/BaseTableMapper.cs | 1 - OpenSim/Data/DB4o/DB4oUserData.cs | 4 ++-- OpenSim/Data/DataStoreBase.cs | 4 ---- OpenSim/Data/GridDataBase.cs | 3 --- OpenSim/Data/IGridData.cs | 1 - OpenSim/Data/InventoryDataBase.cs | 4 ---- OpenSim/Data/MSSQL/MSSQLAssetData.cs | 5 +++-- OpenSim/Data/MSSQL/MSSQLDataStore.cs | 7 +++---- OpenSim/Data/MSSQL/MSSQLGridData.cs | 5 +++-- OpenSim/Data/MSSQL/MSSQLInventoryData.cs | 5 +++-- OpenSim/Data/MSSQL/MSSQLManager.cs | 4 ++-- OpenSim/Data/MSSQL/MSSQLUserData.cs | 13 +++++++------ OpenSim/Data/MSSQLMapper/MSSQLDatabaseMapper.cs | 1 - OpenSim/Data/MySQL/MySQLAssetData.cs | 5 +++-- OpenSim/Data/MySQL/MySQLDataStore.cs | 9 +++++---- OpenSim/Data/MySQL/MySQLGridData.cs | 6 +++--- OpenSim/Data/MySQL/MySQLInventoryData.cs | 7 ++++--- OpenSim/Data/MySQL/MySQLManager.cs | 5 ++--- OpenSim/Data/MySQL/MySQLUserData.cs | 13 +++++++------ OpenSim/Data/MySQLMapper/MySQLDataReader.cs | 4 ---- OpenSim/Data/MySQLMapper/MySQLDatabaseMapper.cs | 1 - OpenSim/Data/NHibernate/NHibernateAssetData.cs | 14 ++++++-------- OpenSim/Data/NHibernate/NHibernateInventoryData.cs | 18 ++++++++---------- OpenSim/Data/NHibernate/NHibernateManager.cs | 9 +++------ OpenSim/Data/NHibernate/NHibernateUserData.cs | 16 ++++++---------- OpenSim/Data/NHibernate/Types/LLUUIDUserType.cs | 6 +++--- OpenSim/Data/OpenSimDataReader.cs | 1 - OpenSim/Data/OpenSimDatabaseConnector.cs | 2 -- OpenSim/Data/OpenSimObjectFieldMapper.cs | 2 -- OpenSim/Data/OpenSimTableMapper.cs | 2 -- OpenSim/Data/PrimitiveBaseShapeTableMapper.cs | 4 ++-- OpenSim/Data/ReservationData.cs | 9 +++++---- OpenSim/Data/SQLite/SQLiteAssetData.cs | 4 ++-- OpenSim/Data/SQLite/SQLiteInventoryStore.cs | 4 ++-- OpenSim/Data/SQLite/SQLiteManager.cs | 6 +++--- OpenSim/Data/SQLite/SQLiteRegionData.cs | 5 +++-- OpenSim/Data/SQLite/SQLiteUserData.cs | 17 +++++++++-------- OpenSim/Data/UserDataBase.cs | 2 +- 41 files changed, 100 insertions(+), 134 deletions(-) (limited to 'OpenSim/Data') diff --git a/OpenSim/Data/AssetDataBase.cs b/OpenSim/Data/AssetDataBase.cs index 0a58126..b30ae73 100644 --- a/OpenSim/Data/AssetDataBase.cs +++ b/OpenSim/Data/AssetDataBase.cs @@ -25,9 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; -using System.Text; using libsecondlife; using OpenSim.Framework; diff --git a/OpenSim/Data/Base/BaseRowMapper.cs b/OpenSim/Data/Base/BaseRowMapper.cs index 45af15a..a61ce49d 100644 --- a/OpenSim/Data/Base/BaseRowMapper.cs +++ b/OpenSim/Data/Base/BaseRowMapper.cs @@ -25,8 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using OpenSim.Data.Base; - namespace OpenSim.Data.Base { public abstract class BaseRowMapper diff --git a/OpenSim/Data/Base/BaseSchema.cs b/OpenSim/Data/Base/BaseSchema.cs index f6bea50..656433f 100644 --- a/OpenSim/Data/Base/BaseSchema.cs +++ b/OpenSim/Data/Base/BaseSchema.cs @@ -26,7 +26,6 @@ */ using System.Collections.Generic; -using OpenSim.Data.Base; namespace OpenSim.Data.Base { diff --git a/OpenSim/Data/Base/BaseTableMapper.cs b/OpenSim/Data/Base/BaseTableMapper.cs index d088769..ad60009 100644 --- a/OpenSim/Data/Base/BaseTableMapper.cs +++ b/OpenSim/Data/Base/BaseTableMapper.cs @@ -28,7 +28,6 @@ using System; using System.Data; using System.Data.Common; -using OpenSim.Data.Base; namespace OpenSim.Data.Base { diff --git a/OpenSim/Data/DB4o/DB4oUserData.cs b/OpenSim/Data/DB4o/DB4oUserData.cs index d0108ab..4a2fc9c 100644 --- a/OpenSim/Data/DB4o/DB4oUserData.cs +++ b/OpenSim/Data/DB4o/DB4oUserData.cs @@ -174,10 +174,10 @@ namespace OpenSim.Data.DB4o - public List GeneratePickerResults(LLUUID queryID, string query) + public List GeneratePickerResults(LLUUID queryID, string query) { //Do nothing yet - List returnlist = new List(); + List returnlist = new List(); return returnlist; } diff --git a/OpenSim/Data/DataStoreBase.cs b/OpenSim/Data/DataStoreBase.cs index 607dcd7..e361799 100644 --- a/OpenSim/Data/DataStoreBase.cs +++ b/OpenSim/Data/DataStoreBase.cs @@ -25,10 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; -using System.Text; - namespace OpenSim.Data { public abstract class DataStoreBase diff --git a/OpenSim/Data/GridDataBase.cs b/OpenSim/Data/GridDataBase.cs index 0a90eca..036e2eb 100644 --- a/OpenSim/Data/GridDataBase.cs +++ b/OpenSim/Data/GridDataBase.cs @@ -25,9 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; -using System.Text; using libsecondlife; namespace OpenSim.Data diff --git a/OpenSim/Data/IGridData.cs b/OpenSim/Data/IGridData.cs index c924031..7681516 100644 --- a/OpenSim/Data/IGridData.cs +++ b/OpenSim/Data/IGridData.cs @@ -25,7 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System.Collections.Generic; using libsecondlife; namespace OpenSim.Data diff --git a/OpenSim/Data/InventoryDataBase.cs b/OpenSim/Data/InventoryDataBase.cs index 242d016..0f4799e 100644 --- a/OpenSim/Data/InventoryDataBase.cs +++ b/OpenSim/Data/InventoryDataBase.cs @@ -25,10 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; -using System.Text; - namespace OpenSim.Data { public abstract class InventoryDataBase diff --git a/OpenSim/Data/MSSQL/MSSQLAssetData.cs b/OpenSim/Data/MSSQL/MSSQLAssetData.cs index e68b5c4..2029b80 100644 --- a/OpenSim/Data/MSSQL/MSSQLAssetData.cs +++ b/OpenSim/Data/MSSQL/MSSQLAssetData.cs @@ -29,15 +29,16 @@ using System; using System.Collections.Generic; using System.Data; using System.Data.SqlClient; +using System.Reflection; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MSSQL { internal class MSSQLAssetData : AssetDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private MSSQLManager database; diff --git a/OpenSim/Data/MSSQL/MSSQLDataStore.cs b/OpenSim/Data/MSSQL/MSSQLDataStore.cs index 525eeca..e881cf1 100644 --- a/OpenSim/Data/MSSQL/MSSQLDataStore.cs +++ b/OpenSim/Data/MSSQL/MSSQLDataStore.cs @@ -30,20 +30,19 @@ using System.Collections.Generic; using System.Data; using System.Data.SqlClient; using System.IO; +using System.Reflection; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; -using OpenSim.Data; using OpenSim.Region.Environment.Interfaces; using OpenSim.Region.Environment.Scenes; -using OpenSim.Data.MSSQL; namespace OpenSim.Data.MSSQL { public class MSSQLDataStore : IRegionDataStore { // private static FileSystemDataStore Instance = new FileSystemDataStore(); - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private const string m_primSelect = "select * from prims"; private const string m_shapeSelect = "select * from primshapes"; diff --git a/OpenSim/Data/MSSQL/MSSQLGridData.cs b/OpenSim/Data/MSSQL/MSSQLGridData.cs index 5617900..3d859ff 100644 --- a/OpenSim/Data/MSSQL/MSSQLGridData.cs +++ b/OpenSim/Data/MSSQL/MSSQLGridData.cs @@ -28,10 +28,11 @@ using System; using System.Collections.Generic; using System.Data; +using System.Reflection; using System.Security.Cryptography; using System.Text; using libsecondlife; -using OpenSim.Framework.Console; +using log4net; namespace OpenSim.Data.MSSQL { @@ -40,7 +41,7 @@ namespace OpenSim.Data.MSSQL /// public class MSSQLGridData : GridDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// Database manager diff --git a/OpenSim/Data/MSSQL/MSSQLInventoryData.cs b/OpenSim/Data/MSSQL/MSSQLInventoryData.cs index 09d4710..27f8b60 100644 --- a/OpenSim/Data/MSSQL/MSSQLInventoryData.cs +++ b/OpenSim/Data/MSSQL/MSSQLInventoryData.cs @@ -29,9 +29,10 @@ using System; using System.Collections.Generic; using System.Data; using System.Data.SqlClient; +using System.Reflection; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MSSQL { @@ -40,7 +41,7 @@ namespace OpenSim.Data.MSSQL /// public class MSSQLInventoryData : IInventoryData { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database manager diff --git a/OpenSim/Data/MSSQL/MSSQLManager.cs b/OpenSim/Data/MSSQL/MSSQLManager.cs index e3179f7..6d73c64 100644 --- a/OpenSim/Data/MSSQL/MSSQLManager.cs +++ b/OpenSim/Data/MSSQL/MSSQLManager.cs @@ -32,8 +32,8 @@ using System.Data.SqlClient; using System.IO; using System.Reflection; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MSSQL { @@ -42,7 +42,7 @@ namespace OpenSim.Data.MSSQL /// public class MSSQLManager { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database connection object diff --git a/OpenSim/Data/MSSQL/MSSQLUserData.cs b/OpenSim/Data/MSSQL/MSSQLUserData.cs index 3d4cabf..a44d022 100644 --- a/OpenSim/Data/MSSQL/MSSQLUserData.cs +++ b/OpenSim/Data/MSSQL/MSSQLUserData.cs @@ -29,9 +29,10 @@ using System; using System.Collections.Generic; using System.Data; using System.Data.SqlClient; +using System.Reflection; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MSSQL { @@ -40,7 +41,7 @@ namespace OpenSim.Data.MSSQL /// public class MSSQLUserData : UserDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// Database manager for MySQL @@ -326,9 +327,9 @@ namespace OpenSim.Data.MSSQL - override public List GeneratePickerResults(LLUUID queryID, string query) + override public List GeneratePickerResults(LLUUID queryID, string query) { - List returnlist = new List(); + List returnlist = new List(); string[] querysplit; querysplit = query.Split(' '); if (querysplit.Length == 2) @@ -350,7 +351,7 @@ namespace OpenSim.Data.MSSQL while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string)reader["UUID"]); user.firstName = (string)reader["username"]; user.lastName = (string)reader["lastname"]; @@ -385,7 +386,7 @@ namespace OpenSim.Data.MSSQL while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string)reader["UUID"]); user.firstName = (string)reader["username"]; user.lastName = (string)reader["lastname"]; diff --git a/OpenSim/Data/MSSQLMapper/MSSQLDatabaseMapper.cs b/OpenSim/Data/MSSQLMapper/MSSQLDatabaseMapper.cs index 25ea1b4..4c807b1 100644 --- a/OpenSim/Data/MSSQLMapper/MSSQLDatabaseMapper.cs +++ b/OpenSim/Data/MSSQLMapper/MSSQLDatabaseMapper.cs @@ -28,7 +28,6 @@ using System; using System.Data.Common; using System.Data.SqlClient; -using OpenSim.Data; namespace OpenSim.Data.MSSQLMapper { diff --git a/OpenSim/Data/MySQL/MySQLAssetData.cs b/OpenSim/Data/MySQL/MySQLAssetData.cs index 50f1cc5..111f7d1 100644 --- a/OpenSim/Data/MySQL/MySQLAssetData.cs +++ b/OpenSim/Data/MySQL/MySQLAssetData.cs @@ -28,16 +28,17 @@ using System; using System.Collections.Generic; using System.Data; +using System.Reflection; using libsecondlife; +using log4net; using MySql.Data.MySqlClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MySQL { internal class MySQLAssetData : AssetDataBase, IPlugin { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private MySQLManager _dbConnection; diff --git a/OpenSim/Data/MySQL/MySQLDataStore.cs b/OpenSim/Data/MySQL/MySQLDataStore.cs index de15421..08e4456 100644 --- a/OpenSim/Data/MySQL/MySQLDataStore.cs +++ b/OpenSim/Data/MySQL/MySQLDataStore.cs @@ -28,12 +28,13 @@ using System; using System.Collections.Generic; using System.Data; -using System.Diagnostics; using System.IO; +using System.Reflection; +using System.Threading; using libsecondlife; +using log4net; using MySql.Data.MySqlClient; using OpenSim.Framework; -using OpenSim.Framework.Console; using OpenSim.Region.Environment.Interfaces; using OpenSim.Region.Environment.Scenes; @@ -41,7 +42,7 @@ namespace OpenSim.Data.MySQL { public class MySQLDataStore : IRegionDataStore { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private const string m_primSelect = "select * from prims"; private const string m_shapeSelect = "select * from primshapes"; @@ -1498,7 +1499,7 @@ namespace OpenSim.Data.MySQL { m_log.Error("[MySql]: Error connecting to MySQL server: " + ex.Message); m_log.Error("[MySql]: Application is terminating!"); - System.Threading.Thread.CurrentThread.Abort(); + Thread.CurrentThread.Abort(); } } diff --git a/OpenSim/Data/MySQL/MySQLGridData.cs b/OpenSim/Data/MySQL/MySQLGridData.cs index 639f899..b6274d4 100644 --- a/OpenSim/Data/MySQL/MySQLGridData.cs +++ b/OpenSim/Data/MySQL/MySQLGridData.cs @@ -28,11 +28,11 @@ using System; using System.Collections.Generic; using System.Data; +using System.Reflection; using System.Security.Cryptography; using System.Text; -using System.Text.RegularExpressions; using libsecondlife; -using OpenSim.Framework.Console; +using log4net; namespace OpenSim.Data.MySQL { @@ -41,7 +41,7 @@ namespace OpenSim.Data.MySQL /// public class MySQLGridData : GridDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// MySQL Database Manager diff --git a/OpenSim/Data/MySQL/MySQLInventoryData.cs b/OpenSim/Data/MySQL/MySQLInventoryData.cs index 82bbf4f..3aed301 100644 --- a/OpenSim/Data/MySQL/MySQLInventoryData.cs +++ b/OpenSim/Data/MySQL/MySQLInventoryData.cs @@ -27,10 +27,11 @@ using System; using System.Collections.Generic; +using System.Reflection; using libsecondlife; +using log4net; using MySql.Data.MySqlClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MySQL { @@ -39,8 +40,8 @@ namespace OpenSim.Data.MySQL /// public class MySQLInventoryData : IInventoryData { - private static readonly log4net.ILog m_log - = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log + = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database manager diff --git a/OpenSim/Data/MySQL/MySQLManager.cs b/OpenSim/Data/MySQL/MySQLManager.cs index a122954..1e7038f 100644 --- a/OpenSim/Data/MySQL/MySQLManager.cs +++ b/OpenSim/Data/MySQL/MySQLManager.cs @@ -28,13 +28,12 @@ using System; using System.Collections.Generic; using System.Data; -using System.Data.SqlClient; using System.IO; using System.Reflection; using libsecondlife; +using log4net; using MySql.Data.MySqlClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MySQL { @@ -43,7 +42,7 @@ namespace OpenSim.Data.MySQL /// internal class MySQLManager { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database connection object diff --git a/OpenSim/Data/MySQL/MySQLUserData.cs b/OpenSim/Data/MySQL/MySQLUserData.cs index d04c932..66b65dc 100644 --- a/OpenSim/Data/MySQL/MySQLUserData.cs +++ b/OpenSim/Data/MySQL/MySQLUserData.cs @@ -28,10 +28,11 @@ using System; using System.Collections.Generic; using System.Data; +using System.Reflection; using System.Text.RegularExpressions; using libsecondlife; +using log4net; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.MySQL { @@ -40,7 +41,7 @@ namespace OpenSim.Data.MySQL /// internal class MySQLUserData : UserDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// Database manager for MySQL @@ -348,9 +349,9 @@ namespace OpenSim.Data.MySQL m_log.Info("[USER]: Stub UpdateUserCUrrentRegion called"); } - override public List GeneratePickerResults(LLUUID queryID, string query) + override public List GeneratePickerResults(LLUUID queryID, string query) { - List returnlist = new List(); + List returnlist = new List(); Regex objAlphaNumericPattern = new Regex("[^a-zA-Z0-9]"); @@ -373,7 +374,7 @@ namespace OpenSim.Data.MySQL while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string) reader["UUID"]); user.firstName = (string) reader["username"]; user.lastName = (string) reader["lastname"]; @@ -407,7 +408,7 @@ namespace OpenSim.Data.MySQL while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string) reader["UUID"]); user.firstName = (string) reader["username"]; user.lastName = (string) reader["lastname"]; diff --git a/OpenSim/Data/MySQLMapper/MySQLDataReader.cs b/OpenSim/Data/MySQLMapper/MySQLDataReader.cs index f242007..9b5de2a 100644 --- a/OpenSim/Data/MySQLMapper/MySQLDataReader.cs +++ b/OpenSim/Data/MySQLMapper/MySQLDataReader.cs @@ -25,11 +25,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; using System.Data; -using System.Text; -using OpenSim.Data.Base; namespace OpenSim.Data.MySQLMapper { diff --git a/OpenSim/Data/MySQLMapper/MySQLDatabaseMapper.cs b/OpenSim/Data/MySQLMapper/MySQLDatabaseMapper.cs index 16f133a..37b94fa 100644 --- a/OpenSim/Data/MySQLMapper/MySQLDatabaseMapper.cs +++ b/OpenSim/Data/MySQLMapper/MySQLDatabaseMapper.cs @@ -28,7 +28,6 @@ using System.Data; using System.Data.Common; using MySql.Data.MySqlClient; -using OpenSim.Data; using OpenSim.Data.Base; namespace OpenSim.Data.MySQLMapper diff --git a/OpenSim/Data/NHibernate/NHibernateAssetData.cs b/OpenSim/Data/NHibernate/NHibernateAssetData.cs index cc018dd..db90d09 100644 --- a/OpenSim/Data/NHibernate/NHibernateAssetData.cs +++ b/OpenSim/Data/NHibernate/NHibernateAssetData.cs @@ -26,17 +26,15 @@ */ using System; -using System.Data; +using System.IO; using System.Reflection; using libsecondlife; +using log4net; using NHibernate; using NHibernate.Cfg; -using NHibernate.Tool.hbm2ddl; using NHibernate.Mapping.Attributes; -using OpenSim.Data; using OpenSim.Framework; -using OpenSim.Framework.Console; -using Environment = NHibernate.Cfg.Environment; +using Environment=NHibernate.Cfg.Environment; namespace OpenSim.Data.NHibernate { @@ -45,7 +43,7 @@ namespace OpenSim.Data.NHibernate /// public class NHibernateAssetData : AssetDataBase, IDisposable { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private Configuration cfg; private ISessionFactory factory; @@ -67,8 +65,8 @@ namespace OpenSim.Data.NHibernate cfg.AddAssembly("OpenSim.Data.NHibernate"); HbmSerializer.Default.Validate = true; - using ( System.IO.MemoryStream stream = - HbmSerializer.Default.Serialize(System.Reflection.Assembly.GetExecutingAssembly())) + using ( MemoryStream stream = + HbmSerializer.Default.Serialize(Assembly.GetExecutingAssembly())) cfg.AddInputStream(stream); // new SchemaExport(cfg).Create(true, true); diff --git a/OpenSim/Data/NHibernate/NHibernateInventoryData.cs b/OpenSim/Data/NHibernate/NHibernateInventoryData.cs index a004e29..1ac0f0c 100644 --- a/OpenSim/Data/NHibernate/NHibernateInventoryData.cs +++ b/OpenSim/Data/NHibernate/NHibernateInventoryData.cs @@ -26,25 +26,23 @@ */ using System; -using System.Data; -using System.Reflection; using System.Collections.Generic; +using System.IO; +using System.Reflection; using libsecondlife; +using log4net; using NHibernate; -using NHibernate.Expression; using NHibernate.Cfg; -using NHibernate.Tool.hbm2ddl; +using NHibernate.Expression; using NHibernate.Mapping.Attributes; -using OpenSim.Data; using OpenSim.Framework; -using OpenSim.Framework.Console; -using Environment = NHibernate.Cfg.Environment; +using Environment=NHibernate.Cfg.Environment; namespace OpenSim.Data.NHibernate { public class NHibernateInventoryData: IInventoryData { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private Configuration cfg; private ISessionFactory factory; @@ -74,8 +72,8 @@ namespace OpenSim.Data.NHibernate cfg.AddAssembly("OpenSim.Data.NHibernate"); HbmSerializer.Default.Validate = true; - using ( System.IO.MemoryStream stream = - HbmSerializer.Default.Serialize(System.Reflection.Assembly.GetExecutingAssembly())) + using ( MemoryStream stream = + HbmSerializer.Default.Serialize(Assembly.GetExecutingAssembly())) cfg.AddInputStream(stream); // new SchemaExport(cfg).Create(true, true); diff --git a/OpenSim/Data/NHibernate/NHibernateManager.cs b/OpenSim/Data/NHibernate/NHibernateManager.cs index edef8ad..6f13294 100644 --- a/OpenSim/Data/NHibernate/NHibernateManager.cs +++ b/OpenSim/Data/NHibernate/NHibernateManager.cs @@ -25,18 +25,15 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections.Generic; -using System.Data; -using libsecondlife; +using System.Reflection; +using log4net; using NHibernate; -using NHibernate.Cfg; namespace OpenSim.Data.NHibernate { internal class NHibernateManager { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private ISessionFactory factory; private ISession session; diff --git a/OpenSim/Data/NHibernate/NHibernateUserData.cs b/OpenSim/Data/NHibernate/NHibernateUserData.cs index 0bbebaa..c0fe26c 100644 --- a/OpenSim/Data/NHibernate/NHibernateUserData.cs +++ b/OpenSim/Data/NHibernate/NHibernateUserData.cs @@ -25,20 +25,16 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Data; -using System.Reflection; using System.Collections.Generic; +using System.IO; +using System.Reflection; using libsecondlife; +using log4net; using NHibernate; using NHibernate.Cfg; using NHibernate.Expression; -using NHibernate.Tool.hbm2ddl; using NHibernate.Mapping.Attributes; -using OpenSim.Data; using OpenSim.Framework; -using OpenSim.Framework.Console; -using Environment = NHibernate.Cfg.Environment; namespace OpenSim.Data.NHibernate { @@ -47,7 +43,7 @@ namespace OpenSim.Data.NHibernate /// public class NHibernateUserData : UserDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private Configuration cfg; private ISessionFactory factory; @@ -69,8 +65,8 @@ namespace OpenSim.Data.NHibernate cfg.AddAssembly("OpenSim.Data.NHibernate"); HbmSerializer.Default.Validate = true; - using ( System.IO.MemoryStream stream = - HbmSerializer.Default.Serialize(System.Reflection.Assembly.GetExecutingAssembly())) + using ( MemoryStream stream = + HbmSerializer.Default.Serialize(Assembly.GetExecutingAssembly())) cfg.AddInputStream(stream); // new SchemaExport(cfg).Create(true, true); diff --git a/OpenSim/Data/NHibernate/Types/LLUUIDUserType.cs b/OpenSim/Data/NHibernate/Types/LLUUIDUserType.cs index 2c1f7dd..e4f1dc2 100644 --- a/OpenSim/Data/NHibernate/Types/LLUUIDUserType.cs +++ b/OpenSim/Data/NHibernate/Types/LLUUIDUserType.cs @@ -27,10 +27,10 @@ using System; using System.Data; +using libsecondlife; using NHibernate; using NHibernate.SqlTypes; using NHibernate.UserTypes; -using libsecondlife; namespace OpenSim.Data.NHibernate { @@ -67,7 +67,7 @@ namespace OpenSim.Data.NHibernate get { return false; } } - public object NullSafeGet(System.Data.IDataReader rs, string[] names, object owner) + public object NullSafeGet(IDataReader rs, string[] names, object owner) { object uuid = null; @@ -81,7 +81,7 @@ namespace OpenSim.Data.NHibernate return uuid; } - public void NullSafeSet(System.Data.IDbCommand cmd, object obj, int index) + public void NullSafeSet(IDbCommand cmd, object obj, int index) { LLUUID uuid = (LLUUID)obj; ((IDataParameter)cmd.Parameters[index]).Value = uuid.ToString(); diff --git a/OpenSim/Data/OpenSimDataReader.cs b/OpenSim/Data/OpenSimDataReader.cs index aaf9aaf..cb613c1 100644 --- a/OpenSim/Data/OpenSimDataReader.cs +++ b/OpenSim/Data/OpenSimDataReader.cs @@ -25,7 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; using System.Data; using libsecondlife; using OpenSim.Data.Base; diff --git a/OpenSim/Data/OpenSimDatabaseConnector.cs b/OpenSim/Data/OpenSimDatabaseConnector.cs index 1a998a7..ee54f4f 100644 --- a/OpenSim/Data/OpenSimDatabaseConnector.cs +++ b/OpenSim/Data/OpenSimDatabaseConnector.cs @@ -26,9 +26,7 @@ */ using System.Data; -using System.Data.Common; using libsecondlife; - using OpenSim.Data.Base; namespace OpenSim.Data diff --git a/OpenSim/Data/OpenSimObjectFieldMapper.cs b/OpenSim/Data/OpenSimObjectFieldMapper.cs index 72bfbb1..d67881b 100644 --- a/OpenSim/Data/OpenSimObjectFieldMapper.cs +++ b/OpenSim/Data/OpenSimObjectFieldMapper.cs @@ -28,9 +28,7 @@ using System; using System.Collections.Generic; using System.Data.Common; -using System.Text; using libsecondlife; - using OpenSim.Data.Base; namespace OpenSim.Data diff --git a/OpenSim/Data/OpenSimTableMapper.cs b/OpenSim/Data/OpenSimTableMapper.cs index bf45b71..f09ef7d 100644 --- a/OpenSim/Data/OpenSimTableMapper.cs +++ b/OpenSim/Data/OpenSimTableMapper.cs @@ -25,8 +25,6 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System.Data; - using OpenSim.Data.Base; namespace OpenSim.Data diff --git a/OpenSim/Data/PrimitiveBaseShapeTableMapper.cs b/OpenSim/Data/PrimitiveBaseShapeTableMapper.cs index a946fe6..fe49978 100644 --- a/OpenSim/Data/PrimitiveBaseShapeTableMapper.cs +++ b/OpenSim/Data/PrimitiveBaseShapeTableMapper.cs @@ -26,9 +26,9 @@ */ using System; -using OpenSim.Framework; -using OpenSim.Data.Base; using libsecondlife; +using OpenSim.Data.Base; +using OpenSim.Framework; namespace OpenSim.Data { diff --git a/OpenSim/Data/ReservationData.cs b/OpenSim/Data/ReservationData.cs index e284708..43fb299 100644 --- a/OpenSim/Data/ReservationData.cs +++ b/OpenSim/Data/ReservationData.cs @@ -25,6 +25,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +using System; using libsecondlife; namespace OpenSim.Data @@ -37,11 +38,11 @@ namespace OpenSim.Data public int reservationMaxX = 65536; public int reservationMaxY = 65536; - public string reservationName = System.String.Empty; - public string reservationCompany = System.String.Empty; + public string reservationName = String.Empty; + public string reservationCompany = String.Empty; public bool status = true; - public string gridSendKey = System.String.Empty; - public string gridRecvKey = System.String.Empty; + public string gridSendKey = String.Empty; + public string gridRecvKey = String.Empty; } } diff --git a/OpenSim/Data/SQLite/SQLiteAssetData.cs b/OpenSim/Data/SQLite/SQLiteAssetData.cs index 25a127b..2b63d2b 100644 --- a/OpenSim/Data/SQLite/SQLiteAssetData.cs +++ b/OpenSim/Data/SQLite/SQLiteAssetData.cs @@ -29,9 +29,9 @@ using System; using System.Data; using System.Reflection; using libsecondlife; +using log4net; using Mono.Data.SqliteClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.SQLite { @@ -40,7 +40,7 @@ namespace OpenSim.Data.SQLite /// public class SQLiteAssetData : AssetDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database manager diff --git a/OpenSim/Data/SQLite/SQLiteInventoryStore.cs b/OpenSim/Data/SQLite/SQLiteInventoryStore.cs index 4ccea59..442ba39 100644 --- a/OpenSim/Data/SQLite/SQLiteInventoryStore.cs +++ b/OpenSim/Data/SQLite/SQLiteInventoryStore.cs @@ -30,15 +30,15 @@ using System.Collections.Generic; using System.Data; using System.Reflection; using libsecondlife; +using log4net; using Mono.Data.SqliteClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.SQLite { public class SQLiteInventoryStore : SQLiteUtil, IInventoryData { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private const string invItemsSelect = "select * from inventoryitems"; private const string invFoldersSelect = "select * from inventoryfolders"; diff --git a/OpenSim/Data/SQLite/SQLiteManager.cs b/OpenSim/Data/SQLite/SQLiteManager.cs index c8ba2af..66ce6ab 100644 --- a/OpenSim/Data/SQLite/SQLiteManager.cs +++ b/OpenSim/Data/SQLite/SQLiteManager.cs @@ -29,15 +29,15 @@ using System; using System.Collections.Generic; using System.Data; using System.Data.SQLite; +using System.Reflection; using libsecondlife; -using Mono.Data.SqliteClient; -using OpenSim.Framework.Console; +using log4net; namespace OpenSim.Data.SQLite { internal class SQLiteManager : SQLiteUtil { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private IDbConnection dbcon; diff --git a/OpenSim/Data/SQLite/SQLiteRegionData.cs b/OpenSim/Data/SQLite/SQLiteRegionData.cs index 85617e5..4355033 100644 --- a/OpenSim/Data/SQLite/SQLiteRegionData.cs +++ b/OpenSim/Data/SQLite/SQLiteRegionData.cs @@ -29,10 +29,11 @@ using System; using System.Collections.Generic; using System.Data; using System.IO; +using System.Reflection; using libsecondlife; +using log4net; using Mono.Data.SqliteClient; using OpenSim.Framework; -using OpenSim.Framework.Console; using OpenSim.Region.Environment.Interfaces; using OpenSim.Region.Environment.Scenes; @@ -40,7 +41,7 @@ namespace OpenSim.Data.SQLite { public class SQLiteRegionData : IRegionDataStore { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private const string primSelect = "select * from prims"; private const string shapeSelect = "select * from primshapes"; diff --git a/OpenSim/Data/SQLite/SQLiteUserData.cs b/OpenSim/Data/SQLite/SQLiteUserData.cs index 089c9df..97797e0 100644 --- a/OpenSim/Data/SQLite/SQLiteUserData.cs +++ b/OpenSim/Data/SQLite/SQLiteUserData.cs @@ -28,10 +28,11 @@ using System; using System.Collections.Generic; using System.Data; +using System.Reflection; using libsecondlife; +using log4net; using Mono.Data.SqliteClient; using OpenSim.Framework; -using OpenSim.Framework.Console; namespace OpenSim.Data.SQLite { @@ -40,7 +41,7 @@ namespace OpenSim.Data.SQLite /// public class SQLiteUserData : UserDataBase { - private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); + private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); /// /// The database manager @@ -238,9 +239,9 @@ namespace OpenSim.Data.SQLite } - override public List GeneratePickerResults(LLUUID queryID, string query) + override public List GeneratePickerResults(LLUUID queryID, string query) { - List returnlist = new List(); + List returnlist = new List(); string[] querysplit; querysplit = query.Split(' '); if (querysplit.Length == 2) @@ -254,7 +255,7 @@ namespace OpenSim.Data.SQLite { while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string) reader["UUID"]); user.firstName = (string) reader["username"]; user.lastName = (string) reader["surname"]; @@ -275,7 +276,7 @@ namespace OpenSim.Data.SQLite { while (reader.Read()) { - Framework.AvatarPickerAvatar user = new Framework.AvatarPickerAvatar(); + AvatarPickerAvatar user = new AvatarPickerAvatar(); user.AvatarID = new LLUUID((string) reader["UUID"]); user.firstName = (string) reader["username"]; user.lastName = (string) reader["surname"]; @@ -766,7 +767,7 @@ namespace OpenSim.Data.SQLite pcmd.ExecuteNonQuery(); } - catch (System.Exception) + catch (Exception) { m_log.Info("[USERS]: users table already exists"); } @@ -775,7 +776,7 @@ namespace OpenSim.Data.SQLite { fcmd.ExecuteNonQuery(); } - catch (System.Exception) + catch (Exception) { m_log.Info("[USERS]: userfriends table already exists"); } diff --git a/OpenSim/Data/UserDataBase.cs b/OpenSim/Data/UserDataBase.cs index ff9f6df..7ce4bd4 100644 --- a/OpenSim/Data/UserDataBase.cs +++ b/OpenSim/Data/UserDataBase.cs @@ -52,6 +52,6 @@ namespace OpenSim.Data public abstract string GetVersion(); public abstract string getName(); public abstract void Initialise(); - public abstract List GeneratePickerResults(LLUUID queryID, string query); + public abstract List GeneratePickerResults(LLUUID queryID, string query); } } -- cgit v1.1