From 9b6b6d05d45cf0f754a0b26bf6240ef50be66563 Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Tue, 3 Jul 2007 14:37:29 +0000 Subject: * Optimized usings (the 'LL ate my scripts' commit) * added some licensing info --- .../Region/GridInterfaces/Local/AssemblyInfo.cs | 2 -- .../GridInterfaces/Local/LocalAssetServer.cs | 28 ++++++++++------------ .../Region/GridInterfaces/Remote/AssemblyInfo.cs | 2 -- .../GridInterfaces/Remote/RemoteAssetServer.cs | 10 ++++---- 4 files changed, 17 insertions(+), 25 deletions(-) (limited to 'OpenSim/Region/GridInterfaces') diff --git a/OpenSim/Region/GridInterfaces/Local/AssemblyInfo.cs b/OpenSim/Region/GridInterfaces/Local/AssemblyInfo.cs index 52ecd6b..b5fc1ef 100644 --- a/OpenSim/Region/GridInterfaces/Local/AssemblyInfo.cs +++ b/OpenSim/Region/GridInterfaces/Local/AssemblyInfo.cs @@ -26,9 +26,7 @@ * */ using System.Reflection; -using System.Runtime.CompilerServices; using System.Runtime.InteropServices; - // Information about this assembly is defined by the following // attributes. // diff --git a/OpenSim/Region/GridInterfaces/Local/LocalAssetServer.cs b/OpenSim/Region/GridInterfaces/Local/LocalAssetServer.cs index 95d03f1..bd303e1 100644 --- a/OpenSim/Region/GridInterfaces/Local/LocalAssetServer.cs +++ b/OpenSim/Region/GridInterfaces/Local/LocalAssetServer.cs @@ -26,17 +26,15 @@ * */ using System; -using System.Collections.Generic; -using System.Text; -using System.Threading; using System.IO; +using System.Threading; +using Db4objects.Db4o; +using Db4objects.Db4o.Query; +using libsecondlife; +using OpenSim.Framework.Console; using OpenSim.Framework.Interfaces; using OpenSim.Framework.Types; using OpenSim.Framework.Utilities; -using OpenSim.Framework.Console; -using libsecondlife; -using Db4objects.Db4o; -using Db4objects.Db4o.Query; namespace OpenSim.Region.GridInterfaces.Local { @@ -64,19 +62,19 @@ namespace OpenSim.Region.GridInterfaces.Local { bool yapfile; this._assetRequests = new BlockingQueue(); - yapfile = System.IO.File.Exists("assets.yap"); + yapfile = File.Exists("assets.yap"); - OpenSim.Framework.Console.MainLog.Instance.Verbose( "Local Asset Server class created"); + MainLog.Instance.Verbose( "Local Asset Server class created"); try { db = Db4oFactory.OpenFile("assets.yap"); - OpenSim.Framework.Console.MainLog.Instance.Verbose( "Db4 Asset database creation"); + MainLog.Instance.Verbose( "Db4 Asset database creation"); } catch (Exception e) { db.Close(); - OpenSim.Framework.Console.MainLog.Instance.WriteLine(LogPriority.MEDIUM, "Db4 Asset server :Constructor - Exception occured"); - OpenSim.Framework.Console.MainLog.Instance.Warn(e.ToString()); + MainLog.Instance.WriteLine(LogPriority.MEDIUM, "Db4 Asset server :Constructor - Exception occured"); + MainLog.Instance.Warn(e.ToString()); } if (!yapfile) { @@ -124,7 +122,7 @@ namespace OpenSim.Region.GridInterfaces.Local { if (db != null) { - OpenSim.Framework.Console.MainLog.Instance.Verbose( "Closing local asset server database"); + MainLog.Instance.Verbose( "Closing local asset server database"); db.Close(); } } @@ -168,7 +166,7 @@ namespace OpenSim.Region.GridInterfaces.Local try { - OpenSim.Framework.Console.MainLog.Instance.Verbose( "Setting up asset database"); + MainLog.Instance.Verbose( "Setting up asset database"); AssetBase Image = new AssetBase(); Image.FullID = new LLUUID("00000000-0000-0000-9999-000000000001"); @@ -281,7 +279,7 @@ namespace OpenSim.Region.GridInterfaces.Local //should request Asset from storage manager //but for now read from file - string dataPath = Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "assets"); //+ folder; + string dataPath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "assets"); //+ folder; string fileName = Path.Combine(dataPath, filename); FileInfo fInfo = new FileInfo(fileName); long numBytes = fInfo.Length; diff --git a/OpenSim/Region/GridInterfaces/Remote/AssemblyInfo.cs b/OpenSim/Region/GridInterfaces/Remote/AssemblyInfo.cs index 51596d0..1e15c5e 100644 --- a/OpenSim/Region/GridInterfaces/Remote/AssemblyInfo.cs +++ b/OpenSim/Region/GridInterfaces/Remote/AssemblyInfo.cs @@ -26,9 +26,7 @@ * */ using System.Reflection; -using System.Runtime.CompilerServices; using System.Runtime.InteropServices; - // Information about this assembly is defined by the following // attributes. // diff --git a/OpenSim/Region/GridInterfaces/Remote/RemoteAssetServer.cs b/OpenSim/Region/GridInterfaces/Remote/RemoteAssetServer.cs index 4652f70..8643736 100644 --- a/OpenSim/Region/GridInterfaces/Remote/RemoteAssetServer.cs +++ b/OpenSim/Region/GridInterfaces/Remote/RemoteAssetServer.cs @@ -25,14 +25,12 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * */ -using System; -using System.Collections.Generic; +using System.IO; +using System.Net; using System.Text; using System.Threading; -using System.Net; -using System.Net.Sockets; -using System.IO; using libsecondlife; +using OpenSim.Framework.Console; using OpenSim.Framework.Interfaces; using OpenSim.Framework.Types; using OpenSim.Framework.Utilities; @@ -53,7 +51,7 @@ namespace OpenSim.Region.GridInterfaces.Remote this._remoteAssetServerThread = new Thread(new ThreadStart(RunRequests)); this._remoteAssetServerThread.IsBackground = true; this._remoteAssetServerThread.Start(); - OpenSim.Framework.Console.MainLog.Instance.Verbose("Remote Asset Server class created"); + MainLog.Instance.Verbose("Remote Asset Server class created"); } public void SetReceiver(IAssetReceiver receiver) -- cgit v1.1