Formatting cleanup.

0.6.0-stable
Jeff Ames 2008-08-18 00:39:10 +00:00
parent 531f6c01eb
commit 6ef9d4da90
208 changed files with 2980 additions and 3163 deletions

View File

@ -23,7 +23,6 @@
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/ */
using System; using System;
@ -654,7 +653,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
/// does not supply an open password, the hashed passwords cannot /// does not supply an open password, the hashed passwords cannot
/// be used unless the cliemt has used the same salting mechanism /// be used unless the cliemt has used the same salting mechanism
/// to has the password before using it in the authentication /// to has the password before using it in the authentication
/// algorithn. This is not inconceivable... /// algorithm. This is not inconceivable...
/// </summary> /// </summary>
private string getPassword(string user) private string getPassword(string user)

View File

@ -23,7 +23,6 @@
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/ */
using libsecondlife; using libsecondlife;
@ -40,10 +39,8 @@ using OpenSim.Framework.Communications.Cache;
namespace OpenSim.ApplicationPlugins.Rest.Inventory namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
public class RestAssetServices : IRest public class RestAssetServices : IRest
{ {
private bool enabled = false; private bool enabled = false;
private string qPrefix = "assets"; private string qPrefix = "assets";
@ -52,7 +49,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
public RestAssetServices() public RestAssetServices()
{ {
Rest.Log.InfoFormat("{0} Asset services initializing", MsgId); Rest.Log.InfoFormat("{0} Asset services initializing", MsgId);
Rest.Log.InfoFormat("{0} Using REST Implementation Version {1}", MsgId, Rest.Version); Rest.Log.InfoFormat("{0} Using REST Implementation Version {1}", MsgId, Rest.Version);
@ -73,7 +69,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
enabled = true; enabled = true;
Rest.Log.InfoFormat("{0} Asset services initialization complete", MsgId); Rest.Log.InfoFormat("{0} Asset services initialization complete", MsgId);
} }
// Post-construction, pre-enabled initialization opportunity // Post-construction, pre-enabled initialization opportunity
@ -111,8 +106,8 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoAsset(RequestData rparm) private void DoAsset(RequestData rparm)
{ {
if (!enabled)
if (!enabled) return; return;
AssetRequestData rdata = (AssetRequestData) rparm; AssetRequestData rdata = (AssetRequestData) rparm;
@ -194,7 +189,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoGet(AssetRequestData rdata) private void DoGet(AssetRequestData rdata)
{ {
bool istexture = false; bool istexture = false;
Rest.Log.DebugFormat("{0} REST Asset handler, Method = <{1}> ENTRY", MsgId, rdata.method); Rest.Log.DebugFormat("{0} REST Asset handler, Method = <{1}> ENTRY", MsgId, rdata.method);
@ -204,13 +198,11 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (rdata.parameters.Length == 1) if (rdata.parameters.Length == 1)
{ {
LLUUID uuid = new LLUUID(rdata.parameters[0]); LLUUID uuid = new LLUUID(rdata.parameters[0]);
AssetBase asset = Rest.AssetServices.GetAsset(uuid, istexture); AssetBase asset = Rest.AssetServices.GetAsset(uuid, istexture);
if (asset != null) if (asset != null)
{ {
Rest.Log.DebugFormat("{0} Asset located <{1}>", MsgId, rdata.parameters[0]); Rest.Log.DebugFormat("{0} Asset located <{1}>", MsgId, rdata.parameters[0]);
rdata.initXmlWriter(); rdata.initXmlWriter();
@ -227,7 +219,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.writer.WriteBase64(asset.Data,0,asset.Data.Length); rdata.writer.WriteBase64(asset.Data,0,asset.Data.Length);
rdata.writer.WriteFullEndElement(); rdata.writer.WriteFullEndElement();
} }
else else
{ {
@ -239,7 +230,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Complete(); rdata.Complete();
rdata.Respond("Asset " + rdata.method + ": Normal completion"); rdata.Respond("Asset " + rdata.method + ": Normal completion");
} }
private void DoPut(AssetRequestData rdata) private void DoPut(AssetRequestData rdata)
@ -281,7 +271,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Complete(); rdata.Complete();
rdata.Respond("Asset " + rdata.method + ": Normal completion"); rdata.Respond("Asset " + rdata.method + ": Normal completion");
} }
internal class AssetRequestData : RequestData internal class AssetRequestData : RequestData
@ -291,6 +280,5 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
} }
} }
} }
} }

View File

@ -23,7 +23,6 @@
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/ */
using System; using System;
@ -37,7 +36,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
public class RestHandler : RestPlugin, IHttpAgentHandler public class RestHandler : RestPlugin, IHttpAgentHandler
{ {
/// <remarks> /// <remarks>
/// The handler delegates are not noteworthy. The allocator allows /// The handler delegates are not noteworthy. The allocator allows
/// a given handler to optionally subclass the base RequestData /// a given handler to optionally subclass the base RequestData
@ -78,7 +76,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
static RestHandler() static RestHandler()
{ {
Module[] mods = Assembly.GetExecutingAssembly().GetModules(); Module[] mods = Assembly.GetExecutingAssembly().GetModules();
foreach (Module m in mods) foreach (Module m in mods)
@ -100,7 +97,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
} }
} }
} }
#endregion local static state #endregion local static state
@ -128,7 +124,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
if (!handlersLoaded) if (!handlersLoaded)
{ {
ConstructorInfo ci; ConstructorInfo ci;
Object ht; Object ht;
@ -203,7 +198,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
try try
{ {
// This plugin will only be enabled if the broader // This plugin will only be enabled if the broader
// REST plugin mechanism is enabled. // REST plugin mechanism is enabled.
@ -314,7 +308,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.Log.ErrorFormat("{0} Plugin initialization has failed: {1}", MsgId, e.Message); Rest.Log.ErrorFormat("{0} Plugin initialization has failed: {1}", MsgId, e.Message);
} }
} }
/// <summary> /// <summary>
@ -329,7 +322,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
public override void Close() public override void Close()
{ {
Rest.Log.InfoFormat("{0} Plugin is terminating", MsgId); Rest.Log.InfoFormat("{0} Plugin is terminating", MsgId);
try try
@ -342,7 +334,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
handler.Close(); handler.Close();
} }
} }
#endregion overriding methods #endregion overriding methods
@ -380,7 +371,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
return true; return true;
} }
} }
} }
catch (Exception e) catch (Exception e)
{ {
@ -425,8 +415,8 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
try try
{ {
handled = ( FindPathHandler(request, response) || handled = FindPathHandler(request, response) ||
FindStreamHandler(request, response) ); FindStreamHandler(request, response);
} }
catch (Exception e) catch (Exception e)
{ {
@ -440,7 +430,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Rest.Log.DebugFormat("{0} EXIT", MsgId); Rest.Log.DebugFormat("{0} EXIT", MsgId);
return handled; return handled;
} }
#endregion interface methods #endregion interface methods
@ -488,7 +477,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
return rdata.handled; return rdata.handled;
} }
/// <summary> /// <summary>
@ -501,7 +489,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
public void AddStreamHandler(string httpMethod, string path, RestMethod method) public void AddStreamHandler(string httpMethod, string path, RestMethod method)
{ {
if (!IsEnabled) if (!IsEnabled)
{ {
return; return;
@ -525,7 +512,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.Log.WarnFormat("{0} Ignoring duplicate handler for {1}", MsgId, path); Rest.Log.WarnFormat("{0} Ignoring duplicate handler for {1}", MsgId, path);
} }
} }
/// <summary> /// <summary>
@ -540,7 +526,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
internal bool FindPathHandler(OSHttpRequest request, OSHttpResponse response) internal bool FindPathHandler(OSHttpRequest request, OSHttpResponse response)
{ {
RequestData rdata = null; RequestData rdata = null;
string bestMatch = null; string bestMatch = null;
@ -566,7 +551,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (!String.IsNullOrEmpty(bestMatch)) if (!String.IsNullOrEmpty(bestMatch))
{ {
rdata = pathAllocators[bestMatch](request, response); rdata = pathAllocators[bestMatch](request, response);
Rest.Log.DebugFormat("{0} Path based REST handler matched with <{1}>", MsgId, bestMatch); Rest.Log.DebugFormat("{0} Path based REST handler matched with <{1}>", MsgId, bestMatch);
@ -583,11 +567,9 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.Log.WarnFormat("{0} Request failed: {1}", MsgId, r.Message); Rest.Log.WarnFormat("{0} Request failed: {1}", MsgId, r.Message);
} }
} }
return (rdata == null) ? false : rdata.handled; return (rdata == null) ? false : rdata.handled;
} }
/// <summary> /// <summary>
@ -597,7 +579,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
internal void AddPathHandler(RestMethodHandler mh, string path, RestMethodAllocator ra) internal void AddPathHandler(RestMethodHandler mh, string path, RestMethodAllocator ra)
{ {
if (!IsEnabled) if (!IsEnabled)
{ {
return; return;
@ -619,8 +600,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
pathHandlers.Add(path, mh); pathHandlers.Add(path, mh);
pathAllocators.Add(path, ra); pathAllocators.Add(path, ra);
} }
} }
} }

View File

@ -23,7 +23,6 @@
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/ */
using System; using System;
@ -42,10 +41,8 @@ using Nini.Config;
namespace OpenSim.ApplicationPlugins.Rest.Inventory namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
public class RestInventoryServices : IRest public class RestInventoryServices : IRest
{ {
private bool enabled = false; private bool enabled = false;
private string qPrefix = "inventory"; private string qPrefix = "inventory";
@ -56,7 +53,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
public RestInventoryServices() public RestInventoryServices()
{ {
Rest.Log.InfoFormat("{0} Inventory services initializing", MsgId); Rest.Log.InfoFormat("{0} Inventory services initializing", MsgId);
Rest.Log.InfoFormat("{0} Using REST Implementation Version {1}", MsgId, Rest.Version); Rest.Log.InfoFormat("{0} Using REST Implementation Version {1}", MsgId, Rest.Version);
@ -77,7 +73,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
enabled = true; enabled = true;
Rest.Log.InfoFormat("{0} Inventory services initialization complete", MsgId); Rest.Log.InfoFormat("{0} Inventory services initialization complete", MsgId);
} }
/// <summary> /// <summary>
@ -134,7 +129,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoInventory(RequestData hdata) private void DoInventory(RequestData hdata)
{ {
InventoryRequestData rdata = (InventoryRequestData) hdata; InventoryRequestData rdata = (InventoryRequestData) hdata;
Rest.Log.DebugFormat("{0} DoInventory ENTRY", MsgId); Rest.Log.DebugFormat("{0} DoInventory ENTRY", MsgId);
@ -288,7 +282,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
MsgId, rdata.userProfile.FirstName, rdata.userProfile.SurName); MsgId, rdata.userProfile.FirstName, rdata.userProfile.SurName);
rdata.Fail(Rest.HttpStatusCodeServerError,Rest.HttpStatusDescServerError+": inventory retrieval failed"); rdata.Fail(Rest.HttpStatusCodeServerError,Rest.HttpStatusDescServerError+": inventory retrieval failed");
} }
} }
else else
{ {
@ -302,7 +295,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
switch (rdata.method) switch (rdata.method)
{ {
case Rest.HEAD : // Do the processing, set the status code, suppress entity case Rest.HEAD : // Do the processing, set the status code, suppress entity
DoGet(rdata); DoGet(rdata);
rdata.buffer = null; rdata.buffer = null;
@ -331,7 +323,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Rest.HttpStatusDescMethodNotAllowed+": "+rdata.method+" not supported"); Rest.HttpStatusDescMethodNotAllowed+": "+rdata.method+" not supported");
break; break;
} }
} }
#endregion Interface #endregion Interface
@ -346,7 +337,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoGet(InventoryRequestData rdata) private void DoGet(InventoryRequestData rdata)
{ {
rdata.initXmlWriter(); rdata.initXmlWriter();
rdata.writer.WriteStartElement(String.Empty,"Inventory",String.Empty); rdata.writer.WriteStartElement(String.Empty,"Inventory",String.Empty);
@ -373,7 +363,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Complete(); rdata.Complete();
rdata.Respond("Inventory " + rdata.method + ": Normal completion"); rdata.Respond("Inventory " + rdata.method + ": Normal completion");
} }
/// <summary> /// <summary>
@ -411,7 +400,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoPut(InventoryRequestData rdata) private void DoPut(InventoryRequestData rdata)
{ {
// Resolve the context node specified in the URI. Entity // Resolve the context node specified in the URI. Entity
// data will be ADDED beneath this node. // data will be ADDED beneath this node.
@ -453,7 +441,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (entity.Assets.Count > 0) if (entity.Assets.Count > 0)
{ {
Rest.Log.DebugFormat("{0} Adding {1} assets to server", Rest.Log.DebugFormat("{0} Adding {1} assets to server",
MsgId, entity.Assets.Count); MsgId, entity.Assets.Count);
@ -467,9 +454,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.Dump(asset.Data); Rest.Dump(asset.Data);
} }
} }
} }
// Modify the context using the collection of folders and items // Modify the context using the collection of folders and items
@ -477,7 +462,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
foreach (InventoryFolderBase folder in entity.Folders) foreach (InventoryFolderBase folder in entity.Folders)
{ {
InventoryFolderBase found; InventoryFolderBase found;
// If the parentID is zero, then this folder is going // If the parentID is zero, then this folder is going
@ -519,7 +503,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Rest.Log.DebugFormat("{0} Adding new folder", MsgId); Rest.Log.DebugFormat("{0} Adding new folder", MsgId);
Rest.InventoryServices.AddFolder(folder); Rest.InventoryServices.AddFolder(folder);
} }
} }
// Now we repeat a similar process for the items included // Now we repeat a similar process for the items included
@ -527,7 +510,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
foreach (InventoryItemBase item in entity.Items) foreach (InventoryItemBase item in entity.Items)
{ {
InventoryItemBase found = null; InventoryItemBase found = null;
// If the parentID is zero, then this is going // If the parentID is zero, then this is going
@ -563,9 +545,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
MsgId, item.ID, item.AssetID, item.InvType, item.AssetType, item.Name); MsgId, item.ID, item.AssetID, item.InvType, item.AssetType, item.Name);
Rest.InventoryServices.AddItem(item); Rest.InventoryServices.AddItem(item);
} }
} }
} }
else else
{ {
@ -577,7 +557,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Complete(); rdata.Complete();
rdata.Respond("Inventory " + rdata.method + ": Normal completion"); rdata.Respond("Inventory " + rdata.method + ": Normal completion");
} }
/// <summary> /// <summary>
@ -604,7 +583,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoPost(InventoryRequestData rdata) private void DoPost(InventoryRequestData rdata)
{ {
int count = 0; int count = 0;
// Resolve the inventory node that is to be modified. // Resolve the inventory node that is to be modified.
@ -639,7 +617,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.Dump(asset.Data); Rest.Dump(asset.Data);
} }
} }
} }
@ -664,7 +641,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (typeof(InventoryFolderBase) == InventoryNode.GetType() || if (typeof(InventoryFolderBase) == InventoryNode.GetType() ||
typeof(InventoryFolderImpl) == InventoryNode.GetType()) typeof(InventoryFolderImpl) == InventoryNode.GetType())
{ {
InventoryFolderBase uri = (InventoryFolderBase) InventoryNode; InventoryFolderBase uri = (InventoryFolderBase) InventoryNode;
InventoryFolderBase xml = null; InventoryFolderBase xml = null;
@ -714,13 +690,11 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (count == 1) if (count == 1)
{ {
InventoryFolderBase TrashCan = GetTrashCan(rdata); InventoryFolderBase TrashCan = GetTrashCan(rdata);
uri.ParentID = TrashCan.ID; uri.ParentID = TrashCan.ID;
Rest.InventoryServices.MoveFolder(uri); Rest.InventoryServices.MoveFolder(uri);
Rest.InventoryServices.PurgeFolder(TrashCan); Rest.InventoryServices.PurgeFolder(TrashCan);
} }
// Now, regardelss of what they represent, we // Now, regardelss of what they represent, we
@ -735,7 +709,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
Rest.InventoryServices.AddItem(it); Rest.InventoryServices.AddItem(it);
} }
} }
/// <summary> /// <summary>
@ -748,7 +721,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
else else
{ {
InventoryItemBase uri = (InventoryItemBase) InventoryNode; InventoryItemBase uri = (InventoryItemBase) InventoryNode;
InventoryItemBase xml = null; InventoryItemBase xml = null;
@ -786,12 +758,10 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
// Add the new item to the inventory // Add the new item to the inventory
Rest.InventoryServices.AddItem(xml); Rest.InventoryServices.AddItem(xml);
} }
rdata.Complete(); rdata.Complete();
rdata.Respond("Inventory " + rdata.method + ": Normal completion"); rdata.Respond("Inventory " + rdata.method + ": Normal completion");
} }
/// <summary> /// <summary>
@ -816,13 +786,11 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void DoDelete(InventoryRequestData rdata) private void DoDelete(InventoryRequestData rdata)
{ {
Object InventoryNode = getInventoryNode(rdata, rdata.root, 1); Object InventoryNode = getInventoryNode(rdata, rdata.root, 1);
if (typeof(InventoryFolderBase) == InventoryNode.GetType() || if (typeof(InventoryFolderBase) == InventoryNode.GetType() ||
typeof(InventoryFolderImpl) == InventoryNode.GetType()) typeof(InventoryFolderImpl) == InventoryNode.GetType())
{ {
InventoryFolderBase TrashCan = GetTrashCan(rdata); InventoryFolderBase TrashCan = GetTrashCan(rdata);
InventoryFolderBase folder = (InventoryFolderBase) InventoryNode; InventoryFolderBase folder = (InventoryFolderBase) InventoryNode;
@ -831,7 +799,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
folder.ParentID = TrashCan.ID; folder.ParentID = TrashCan.ID;
Rest.InventoryServices.MoveFolder(folder); Rest.InventoryServices.MoveFolder(folder);
Rest.InventoryServices.PurgeFolder(TrashCan); Rest.InventoryServices.PurgeFolder(TrashCan);
} }
// Deleting items is much more straight forward. // Deleting items is much more straight forward.
@ -846,10 +813,9 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Complete(); rdata.Complete();
rdata.Respond("Inventory " + rdata.method + ": Normal completion"); rdata.Respond("Inventory " + rdata.method + ": Normal completion");
} }
#endregion method-specific processing #endregion method-specific processing
/// <summary> /// <summary>
/// This method is called to obtain the OpenSim inventory object identified /// This method is called to obtain the OpenSim inventory object identified
@ -880,7 +846,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private Object getInventoryNode(InventoryRequestData rdata, InventoryFolderBase folder, int pi) private Object getInventoryNode(InventoryRequestData rdata, InventoryFolderBase folder, int pi)
{ {
Rest.Log.DebugFormat("{0} Searching folder {1} {2} [{3}]", MsgId, folder.ID, folder.Name, pi); Rest.Log.DebugFormat("{0} Searching folder {1} {2} [{3}]", MsgId, folder.ID, folder.Name, pi);
// We have just run off the end of the parameter sequence // We have just run off the end of the parameter sequence
@ -894,6 +859,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
// get us there. // get us there.
if (rdata.folders != null) if (rdata.folders != null)
{
foreach (InventoryFolderBase f in rdata.folders) foreach (InventoryFolderBase f in rdata.folders)
{ {
// Look for the present node in the directory list // Look for the present node in the directory list
@ -904,6 +870,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
return getInventoryNode(rdata, f, pi+1); return getInventoryNode(rdata, f, pi+1);
} }
} }
}
// No folders that match. Perhaps this parameter identifies an item? If // No folders that match. Perhaps this parameter identifies an item? If
// it does, then it MUST also be the last name in the sequence. // it does, then it MUST also be the last name in the sequence.
@ -944,7 +911,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.Fail(Rest.HttpStatusCodeNotFound, Rest.HttpStatusDescNotFound+": resource "+rdata.path+" not found"); rdata.Fail(Rest.HttpStatusCodeNotFound, Rest.HttpStatusDescNotFound+": resource "+rdata.path+" not found");
return null; /* Never reached */ return null; /* Never reached */
} }
/// <summary> /// <summary>
@ -961,7 +927,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void traverseInventory(InventoryRequestData rdata, InventoryFolderBase folder, int pi) private void traverseInventory(InventoryRequestData rdata, InventoryFolderBase folder, int pi)
{ {
Rest.Log.DebugFormat("{0} Folder : {1} {2} [{3}]", MsgId, folder.ID, folder.Name, pi); Rest.Log.DebugFormat("{0} Folder : {1} {2} [{3}]", MsgId, folder.ID, folder.Name, pi);
if (rdata.folders != null) if (rdata.folders != null)
@ -1010,7 +975,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Rest.Log.DebugFormat("{0} Inventory does not contain item/folder: <{1}>", Rest.Log.DebugFormat("{0} Inventory does not contain item/folder: <{1}>",
MsgId, rdata.path); MsgId, rdata.path);
rdata.Fail(Rest.HttpStatusCodeNotFound,Rest.HttpStatusDescNotFound+": no such item/folder"); rdata.Fail(Rest.HttpStatusCodeNotFound,Rest.HttpStatusDescNotFound+": no such item/folder");
} }
/// <summary> /// <summary>
@ -1023,7 +987,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void formatInventory(InventoryRequestData rdata, InventoryFolderBase folder, string indent) private void formatInventory(InventoryRequestData rdata, InventoryFolderBase folder, string indent)
{ {
if (Rest.DEBUG) if (Rest.DEBUG)
{ {
Rest.Log.DebugFormat("{0} Folder : {1} {2} {3}", MsgId, folder.ID, indent, folder.Name); Rest.Log.DebugFormat("{0} Folder : {1} {2} {3}", MsgId, folder.ID, indent, folder.Name);
@ -1064,7 +1027,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
// End folder item // End folder item
rdata.writer.WriteEndElement(); rdata.writer.WriteEndElement();
} }
/// <summary> /// <summary>
@ -1073,7 +1035,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void formatItem(InventoryRequestData rdata, InventoryItemBase i, string indent) private void formatItem(InventoryRequestData rdata, InventoryItemBase i, string indent)
{ {
Rest.Log.DebugFormat("{0} Item : {1} {2} {3}", MsgId, i.ID, indent, i.Name); Rest.Log.DebugFormat("{0} Item : {1} {2} {3}", MsgId, i.ID, indent, i.Name);
rdata.writer.WriteStartElement(String.Empty,"Item",String.Empty); rdata.writer.WriteStartElement(String.Empty,"Item",String.Empty);
@ -1102,7 +1063,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
rdata.writer.WriteElementString("Asset",i.AssetID.ToString()); rdata.writer.WriteElementString("Asset",i.AssetID.ToString());
rdata.writer.WriteEndElement(); rdata.writer.WriteEndElement();
} }
/// <summary> /// <summary>
@ -1117,7 +1077,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private InventoryFolderBase GetTrashCan(InventoryRequestData rdata) private InventoryFolderBase GetTrashCan(InventoryRequestData rdata)
{ {
InventoryFolderBase TrashCan = null; InventoryFolderBase TrashCan = null;
foreach (InventoryFolderBase f in rdata.folders) foreach (InventoryFolderBase f in rdata.folders)
@ -1153,7 +1112,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
return TrashCan; return TrashCan;
} }
/// <summary> /// <summary>
@ -1163,7 +1121,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private bool FolderHasChanged(InventoryFolderBase newf, InventoryFolderBase oldf) private bool FolderHasChanged(InventoryFolderBase newf, InventoryFolderBase oldf)
{ {
return ( newf.Name != oldf.Name return (newf.Name != oldf.Name
|| newf.ParentID != oldf.ParentID || newf.ParentID != oldf.ParentID
|| newf.Owner != oldf.Owner || newf.Owner != oldf.Owner
|| newf.Type != oldf.Type || newf.Type != oldf.Type
@ -1178,7 +1136,7 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private bool ItemHasChanged(InventoryItemBase newf, InventoryItemBase oldf) private bool ItemHasChanged(InventoryItemBase newf, InventoryItemBase oldf)
{ {
return ( newf.Name != oldf.Name return (newf.Name != oldf.Name
|| newf.Folder != oldf.Description || newf.Folder != oldf.Description
|| newf.Description != oldf.Description || newf.Description != oldf.Description
|| newf.Owner != oldf.Owner || newf.Owner != oldf.Owner
@ -1215,14 +1173,12 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
internal XmlInventoryCollection ReconstituteEntity(InventoryRequestData rdata) internal XmlInventoryCollection ReconstituteEntity(InventoryRequestData rdata)
{ {
Rest.Log.DebugFormat("{0} Reconstituting entity", MsgId); Rest.Log.DebugFormat("{0} Reconstituting entity", MsgId);
XmlInventoryCollection ic = new XmlInventoryCollection(); XmlInventoryCollection ic = new XmlInventoryCollection();
if (rdata.request.HasEntityBody) if (rdata.request.HasEntityBody)
{ {
Rest.Log.DebugFormat("{0} Entity present", MsgId); Rest.Log.DebugFormat("{0} Entity present", MsgId);
ic.init(rdata); ic.init(rdata);
@ -1318,7 +1274,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Rest.Log.WarnFormat("{0} Unexpected XML parsing error: {1}", MsgId, e.Message); Rest.Log.WarnFormat("{0} Unexpected XML parsing error: {1}", MsgId, e.Message);
throw e; throw e;
} }
} }
else else
{ {
@ -1334,7 +1289,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
return ic; return ic;
} }
/// <summary> /// <summary>
@ -1349,7 +1303,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void CollectFolder(XmlInventoryCollection ic) private void CollectFolder(XmlInventoryCollection ic)
{ {
Rest.Log.DebugFormat("{0} Interpret folder element", MsgId); Rest.Log.DebugFormat("{0} Interpret folder element", MsgId);
InventoryFolderBase result = new InventoryFolderBase(); InventoryFolderBase result = new InventoryFolderBase();
@ -1411,7 +1364,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
else else
{ {
bool found = false; bool found = false;
foreach (InventoryFolderBase parent in ic.rdata.folders) foreach (InventoryFolderBase parent in ic.rdata.folders)
@ -1445,7 +1397,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
// obsolete as a consequence. // obsolete as a consequence.
ic.Push(result); ic.Push(result);
} }
/// <summary> /// <summary>
@ -1463,7 +1414,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void CollectItem(XmlInventoryCollection ic) private void CollectItem(XmlInventoryCollection ic)
{ {
Rest.Log.DebugFormat("{0} Interpret item element", MsgId); Rest.Log.DebugFormat("{0} Interpret item element", MsgId);
InventoryItemBase result = new InventoryItemBase(); InventoryItemBase result = new InventoryItemBase();
@ -1484,7 +1434,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
for (int i = 0; i < ic.xml.AttributeCount; i++) for (int i = 0; i < ic.xml.AttributeCount; i++)
{ {
ic.xml.MoveToAttribute(i); ic.xml.MoveToAttribute(i);
switch (ic.xml.Name) switch (ic.xml.Name)
@ -1545,7 +1494,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
ic.xml.MoveToElement(); ic.xml.MoveToElement();
ic.Push(result); ic.Push(result);
} }
/// <summary> /// <summary>
@ -1659,7 +1607,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
else else
{ {
string b64string = null; string b64string = null;
// Generate a UUID of none were given, and generally none should // Generate a UUID of none were given, and generally none should
@ -1701,11 +1648,9 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
ic.Item.AssetID = uuid; ic.Item.AssetID = uuid;
} }
} }
ic.Push(asset); ic.Push(asset);
} }
/// <summary> /// <summary>
@ -1716,7 +1661,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void CollectPermissions(XmlInventoryCollection ic) private void CollectPermissions(XmlInventoryCollection ic)
{ {
if (ic.xml.HasAttributes) if (ic.xml.HasAttributes)
{ {
for (int i = 0; i < ic.xml.AttributeCount; i++) for (int i = 0; i < ic.xml.AttributeCount; i++)
@ -1747,7 +1691,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
ic.xml.MoveToElement(); ic.xml.MoveToElement();
} }
/// <summary> /// <summary>
@ -1762,7 +1705,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
private void Validate(XmlInventoryCollection ic) private void Validate(XmlInventoryCollection ic)
{ {
// There really should be an item present if we've // There really should be an item present if we've
// called validate. So fail if there is not. // called validate. So fail if there is not.
@ -1788,12 +1730,10 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (ic.Item.AssetID == LLUUID.Zero) if (ic.Item.AssetID == LLUUID.Zero)
{ {
Rest.Log.ErrorFormat("{0} Unable to complete request", MsgId); Rest.Log.ErrorFormat("{0} Unable to complete request", MsgId);
Rest.Log.InfoFormat("{0} Asset information is missing", MsgId); Rest.Log.InfoFormat("{0} Asset information is missing", MsgId);
ic.Fail(Rest.HttpStatusCodeBadRequest, ic.Fail(Rest.HttpStatusCodeBadRequest,
Rest.HttpStatusDescBadRequest+": asset information required"); Rest.HttpStatusDescBadRequest+": asset information required");
} }
// If the item is new, then assign it an ID // If the item is new, then assign it an ID
@ -1813,12 +1753,11 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
else else
{ {
bool found = false; bool found = false;
foreach (InventoryFolderBase parent in ic.rdata.folders) foreach (InventoryFolderBase parent in ic.rdata.folders)
{ {
if ( parent.ID == ic.Item.Folder ) if (parent.ID == ic.Item.Folder)
{ {
found = true; found = true;
break; break;
@ -1832,7 +1771,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
ic.Fail(Rest.HttpStatusCodeBadRequest, ic.Fail(Rest.HttpStatusCodeBadRequest,
Rest.HttpStatusDescBadRequest+": parent information required"); Rest.HttpStatusDescBadRequest+": parent information required");
} }
} }
// If this is an inline asset being constructed in the context // If this is an inline asset being constructed in the context
@ -1860,7 +1798,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
if (ic.Item.AssetType == (int) AssetType.Unknown || if (ic.Item.AssetType == (int) AssetType.Unknown ||
ic.Item.InvType == (int) AssetType.Unknown) ic.Item.InvType == (int) AssetType.Unknown)
{ {
Rest.Log.DebugFormat("{0} Attempting to infer item type", MsgId); Rest.Log.DebugFormat("{0} Attempting to infer item type", MsgId);
string[] parts = ic.Item.Name.Split(Rest.CA_PERIOD); string[] parts = ic.Item.Name.Split(Rest.CA_PERIOD);
@ -1940,14 +1877,12 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
} }
ic.reset(); ic.reset();
} }
#region Inventory RequestData extension #region Inventory RequestData extension
internal class InventoryRequestData : RequestData internal class InventoryRequestData : RequestData
{ {
/// <summary> /// <summary>
/// These are the inventory specific request/response state /// These are the inventory specific request/response state
/// extensions. /// extensions.
@ -1981,7 +1916,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
Monitor.Pulse(this); Monitor.Pulse(this);
} }
} }
} }
#endregion Inventory RequestData extension #endregion Inventory RequestData extension
@ -1994,7 +1928,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
internal class XmlInventoryCollection : InventoryCollection internal class XmlInventoryCollection : InventoryCollection
{ {
internal InventoryRequestData rdata; internal InventoryRequestData rdata;
private Stack<InventoryFolderBase> stk; private Stack<InventoryFolderBase> stk;
@ -2087,7 +2020,6 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory
{ {
rdata.Fail(code, desc); rdata.Fail(code, desc);
} }
} }
} }
} }

View File

@ -178,7 +178,6 @@ namespace OpenSim.Data.MySQL
SetupShapeCommands(m_shapeDataAdapter, m_connection); SetupShapeCommands(m_shapeDataAdapter, m_connection);
m_shapeDataAdapter.Fill(m_shapeTable); m_shapeDataAdapter.Fill(m_shapeTable);
m_itemsTable = createItemsTable(); m_itemsTable = createItemsTable();
m_dataSet.Tables.Add(m_itemsTable); m_dataSet.Tables.Add(m_itemsTable);
SetupItemsCommands(m_itemsDataAdapter, m_connection); SetupItemsCommands(m_itemsDataAdapter, m_connection);

View File

@ -449,7 +449,7 @@ namespace OpenSim.Data.SQLite
folderRows = inventoryFolderTable.Select(selectExp); folderRows = inventoryFolderTable.Select(selectExp);
} }
if ( folderRows!=null && folderRows.GetLength(0)>=1 ) // No result means parent folder does not exist if (folderRows != null && folderRows.GetLength(0) >= 1) // No result means parent folder does not exist
{ // or has no children { // or has no children
/* if we're querying the root folder, just return an unordered list of all folders in the user's /* if we're querying the root folder, just return an unordered list of all folders in the user's
* inventory * inventory
@ -481,16 +481,16 @@ namespace OpenSim.Data.SQLite
InventoryFolderBase curFolder = buildFolder(row); InventoryFolderBase curFolder = buildFolder(row);
if (curFolder.ParentID != LLUUID.Zero) // Discard root of tree - not needed if (curFolder.ParentID != LLUUID.Zero) // Discard root of tree - not needed
{ {
if ( hashtable.ContainsKey(curFolder.ParentID ) ) if (hashtable.ContainsKey(curFolder.ParentID))
{ {
// Current folder already has a sibling - append to sibling list // Current folder already has a sibling - append to sibling list
hashtable[curFolder.ParentID].Add( curFolder ); hashtable[curFolder.ParentID].Add(curFolder);
} }
else { else {
List<InventoryFolderBase> siblingList = new List<InventoryFolderBase>(); List<InventoryFolderBase> siblingList = new List<InventoryFolderBase>();
siblingList.Add( curFolder ); siblingList.Add(curFolder);
// Current folder has no known (yet) siblings // Current folder has no known (yet) siblings
hashtable.Add( curFolder.ParentID, siblingList ); hashtable.Add(curFolder.ParentID, siblingList);
} }
} }
} // For all inventory folders } // For all inventory folders
@ -498,11 +498,11 @@ namespace OpenSim.Data.SQLite
// Note: Could release the ds lock here - we don't access folderRows or the database anymore. // Note: Could release the ds lock here - we don't access folderRows or the database anymore.
// This is somewhat of a moot point as the callers of this function usually lock db anyways. // This is somewhat of a moot point as the callers of this function usually lock db anyways.
if ( hashtable.ContainsKey( parentID ) ) // if requested folder does have children if (hashtable.ContainsKey(parentID)) // if requested folder does have children
folders.AddRange( hashtable[parentID] ); folders.AddRange(hashtable[parentID]);
// BreadthFirstSearch build inventory tree **Note: folders.Count is *not* static // BreadthFirstSearch build inventory tree **Note: folders.Count is *not* static
for ( int i = 0; i < folders.Count; i++ ) for (int i = 0; i < folders.Count; i++)
if (hashtable.ContainsKey(folders[i].ID)) if (hashtable.ContainsKey(folders[i].ID))
folders.AddRange(hashtable[folders[i].ID]); folders.AddRange(hashtable[folders[i].ID]);

View File

@ -212,7 +212,6 @@ namespace OpenSim.Framework.Communications
// Reject the login // Reject the login
m_log.InfoFormat( m_log.InfoFormat(
"[LOGIN END]: XMLRPC Notifying user {0} {1} that they are already logged in", "[LOGIN END]: XMLRPC Notifying user {0} {1} that they are already logged in",
firstname, lastname); firstname, lastname);

View File

@ -457,12 +457,11 @@ namespace OpenSim.Framework
configMember.addConfigurationOption("lastmap_refresh", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, configMember.addConfigurationOption("lastmap_refresh", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
"Last Map Refresh", Util.UnixTimeSinceEpoch().ToString(), true); "Last Map Refresh", Util.UnixTimeSinceEpoch().ToString(), true);
} }
public bool shouldMasterAvatarDetailsBeAsked(string configuration_key) public bool shouldMasterAvatarDetailsBeAsked(string configuration_key)
{ {
if (MasterAvatarAssignedUUID == LLUUID.Zero) return MasterAvatarAssignedUUID == LLUUID.Zero;
{ {
return true; return true;
} }

View File

@ -38,42 +38,35 @@ namespace OpenSim.Framework.Servers
{ {
public class OSHttpRequest public class OSHttpRequest
{ {
public string[] AcceptTypes public string[] AcceptTypes
{ {
get { return _acceptTypes; } get { return _acceptTypes; }
} }
private string[] _acceptTypes; private string[] _acceptTypes;
public Encoding ContentEncoding public Encoding ContentEncoding
{ {
get { return _contentEncoding; } get { return _contentEncoding; }
} }
private Encoding _contentEncoding; private Encoding _contentEncoding;
public long ContentLength public long ContentLength
{ {
get { return _contentLength64; } get { return _contentLength64; }
} }
private long _contentLength64; private long _contentLength64;
public long ContentLength64 public long ContentLength64
{ {
get { return ContentLength; } get { return ContentLength; }
} }
public string ContentType public string ContentType
{ {
get { return _contentType; } get { return _contentType; }
} }
private string _contentType; private string _contentType;
// public CookieCollection Cookies // public CookieCollection Cookies
// { // {
// get { return _cookies; } // get { return _cookies; }
@ -92,63 +85,54 @@ namespace OpenSim.Framework.Servers
} }
private string _httpMethod; private string _httpMethod;
public Stream InputStream public Stream InputStream
{ {
get { return _inputStream; } get { return _inputStream; }
} }
private Stream _inputStream; private Stream _inputStream;
// public bool IsSecureConnection // public bool IsSecureConnection
// { // {
// get { return _isSecureConnection; } // get { return _isSecureConnection; }
// } // }
// private bool _isSecureConnection; // private bool _isSecureConnection;
// public bool IsAuthenticated // public bool IsAuthenticated
// { // {
// get { return _isAuthenticated; } // get { return _isAuthenticated; }
// } // }
// private bool _isAuthenticated; // private bool _isAuthenticated;
public bool HasEntityBody public bool HasEntityBody
{ {
get { return _hasbody; } get { return _hasbody; }
} }
private bool _hasbody; private bool _hasbody;
public bool KeepAlive public bool KeepAlive
{ {
get { return _keepAlive; } get { return _keepAlive; }
} }
private bool _keepAlive; private bool _keepAlive;
public string RawUrl public string RawUrl
{ {
get { return _rawUrl; } get { return _rawUrl; }
} }
private string _rawUrl; private string _rawUrl;
public Uri Url public Uri Url
{ {
get { return _url; } get { return _url; }
} }
private Uri _url; private Uri _url;
public string UserAgent public string UserAgent
{ {
get { return _userAgent; } get { return _userAgent; }
} }
private string _userAgent; private string _userAgent;
public NameValueCollection QueryString public NameValueCollection QueryString
{ {
get { return _queryString; } get { return _queryString; }
@ -161,28 +145,24 @@ namespace OpenSim.Framework.Servers
} }
private Hashtable _query; private Hashtable _query;
public IPEndPoint RemoteIPEndPoint public IPEndPoint RemoteIPEndPoint
{ {
get { return _ipEndPoint; } get { return _ipEndPoint; }
} }
private IPEndPoint _ipEndPoint; private IPEndPoint _ipEndPoint;
internal HttpRequest HttpRequest internal HttpRequest HttpRequest
{ {
get { return _request; } get { return _request; }
} }
private HttpRequest _request; private HttpRequest _request;
internal HttpClientContext HttpClientContext internal HttpClientContext HttpClientContext
{ {
get { return _context; } get { return _context; }
} }
private HttpClientContext _context; private HttpClientContext _context;
/// <summary> /// <summary>
/// Internal whiteboard for handlers to store temporary stuff /// Internal whiteboard for handlers to store temporary stuff
/// into. /// into.
@ -193,12 +173,10 @@ namespace OpenSim.Framework.Servers
} }
private Dictionary<string, object> _whiteboard = new Dictionary<string, object>(); private Dictionary<string, object> _whiteboard = new Dictionary<string, object>();
public OSHttpRequest() public OSHttpRequest()
{ {
} }
public OSHttpRequest(HttpListenerRequest req) public OSHttpRequest(HttpListenerRequest req)
{ {
_acceptTypes = req.AcceptTypes; _acceptTypes = req.AcceptTypes;

View File

@ -39,7 +39,6 @@ using System.Threading;
using log4net; using log4net;
using HttpServer; using HttpServer;
namespace OpenSim.Framework.Servers namespace OpenSim.Framework.Servers
{ {
/// <summary> /// <summary>
@ -64,7 +63,6 @@ namespace OpenSim.Framework.Servers
get { return String.Format("{0} pump {1}", _server.EngineID, _id); } get { return String.Format("{0} pump {1}", _server.EngineID, _id); }
} }
public OSHttpRequestPump(OSHttpServer server, OSHttpRequestQueue queue, int id) public OSHttpRequestPump(OSHttpServer server, OSHttpRequestQueue queue, int id)
{ {
_server = server; _server = server;
@ -77,7 +75,6 @@ namespace OpenSim.Framework.Servers
_engine.Start(); _engine.Start();
ThreadTracker.Add(_engine); ThreadTracker.Add(_engine);
} }
public static OSHttpRequestPump[] Pumps(OSHttpServer server, OSHttpRequestQueue queue, int poolSize) public static OSHttpRequestPump[] Pumps(OSHttpServer server, OSHttpRequestQueue queue, int poolSize)
@ -107,7 +104,8 @@ namespace OpenSim.Framework.Servers
while (true) while (true)
{ {
try { try
{
// dequeue an OSHttpRequest from OSHttpServer's // dequeue an OSHttpRequest from OSHttpServer's
// request queue // request queue
req = _queue.Dequeue(); req = _queue.Dequeue();
@ -276,7 +274,8 @@ namespace OpenSim.Framework.Servers
// does the content of collection[tag] match // does the content of collection[tag] match
// the supplied regex? // the supplied regex?
Match cm = regexs[tag].Match(collection[tag]); Match cm = regexs[tag].Match(collection[tag]);
if (!cm.Success) { if (!cm.Success)
{
return 0; return 0;
} }

View File

@ -89,8 +89,6 @@ namespace OpenSim.Grid.MessagingServer
m_log.Info("[REGION]: Starting HTTP process"); m_log.Info("[REGION]: Starting HTTP process");
m_httpServer = new BaseHttpServer(Cfg.HttpPort); m_httpServer = new BaseHttpServer(Cfg.HttpPort);
msgsvc = new MessageService(Cfg); msgsvc = new MessageService(Cfg);
if (msgsvc.registerWithUserServer()) if (msgsvc.registerWithUserServer())
@ -123,7 +121,6 @@ namespace OpenSim.Grid.MessagingServer
switch (what) switch (what)
{ {
case "user": case "user":
try try
{ {
//userID = //userID =
@ -161,8 +158,6 @@ namespace OpenSim.Grid.MessagingServer
m_console.Notice("Region cache cleared! Cleared " + entries.ToString() + " entries"); m_console.Notice("Region cache cleared! Cleared " + entries.ToString() + " entries");
break; break;
} }
} }
public override void Shutdown() public override void Shutdown()

View File

@ -45,7 +45,6 @@ namespace OpenSim.Grid.ScriptServer
regInfo, authen, commsMan, sceneGridService, assetCach, storeManager, httpServer, regInfo, authen, commsMan, sceneGridService, assetCach, storeManager, httpServer,
moduleLoader, dumpAssetsToFile, physicalPrim, sendTasksToChild, config, "") moduleLoader, dumpAssetsToFile, physicalPrim, sendTasksToChild, config, "")
{ {
} }
// What does a scene have to do? :P // What does a scene have to do? :P

View File

@ -69,7 +69,6 @@ namespace OpenSim.Grid.ScriptServer
Engine.InitializeEngine(null, null, false, Engine.GetScriptManager()); Engine.InitializeEngine(null, null, false, Engine.GetScriptManager());
// Set up server // Set up server
//m_RemotingServer = new RemotingServer(listenPort, "DotNetEngine"); //m_RemotingServer = new RemotingServer(listenPort, "DotNetEngine");
m_TCPServer = new TCPServer(listenPort); m_TCPServer = new TCPServer(listenPort);

View File

@ -152,7 +152,6 @@ namespace OpenSim.Grid.UserServer
m_httpServer.AddStreamHandler(new RestStreamHandler("GET", "/get_grid_info", m_gridInfoService.RestGetGridInfoMethod)); m_httpServer.AddStreamHandler(new RestStreamHandler("GET", "/get_grid_info", m_gridInfoService.RestGetGridInfoMethod));
m_httpServer.AddXmlRPCHandler("get_grid_info", m_gridInfoService.XmlRpcGridInfoMethod); m_httpServer.AddXmlRPCHandler("get_grid_info", m_gridInfoService.XmlRpcGridInfoMethod);
m_httpServer.AddStreamHandler( m_httpServer.AddStreamHandler(
new RestStreamHandler("DELETE", "/usersessions/", m_userManager.RestDeleteUserSessionMethod)); new RestStreamHandler("DELETE", "/usersessions/", m_userManager.RestDeleteUserSessionMethod));

View File

@ -306,8 +306,6 @@ namespace OpenSim.Grid.UserServer
theUser.FirstName, theUser.SurName); theUser.FirstName, theUser.SurName);
} }
} }
} }
} }
catch (Exception) catch (Exception)

View File

@ -27,8 +27,6 @@
namespace OpenSim.Region.Environment.Interfaces namespace OpenSim.Region.Environment.Interfaces
{ {
public interface ICommander public interface ICommander
{ {
void ProcessConsoleCommand(string function, string[] args); void ProcessConsoleCommand(string function, string[] args);

View File

@ -159,8 +159,6 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Groups
updateGroups[0] = OpenSimulatorGroup; updateGroups[0] = OpenSimulatorGroup;
client.SendGroupMembership(updateGroups); client.SendGroupMembership(updateGroups);
} }
private void OnAgentDataUpdateRequest(IClientAPI remoteClient, LLUUID AgentID, LLUUID SessionID) private void OnAgentDataUpdateRequest(IClientAPI remoteClient, LLUUID AgentID, LLUUID SessionID)
@ -275,6 +273,4 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Groups
GC.Collect(); GC.Collect();
} }
} }
} }

View File

@ -408,7 +408,6 @@ namespace OpenSim.Region.Environment.Modules.World.Estate
args.waterHeight = (float)m_scene.RegionInfo.RegionSettings.WaterHeight; args.waterHeight = (float)m_scene.RegionInfo.RegionSettings.WaterHeight;
args.simName = m_scene.RegionInfo.RegionName; args.simName = m_scene.RegionInfo.RegionName;
remote_client.SendRegionInfoToEstateMenu(args); remote_client.SendRegionInfoToEstateMenu(args);
} }
@ -416,6 +415,7 @@ namespace OpenSim.Region.Environment.Modules.World.Estate
{ {
remote_client.SendEstateCovenantInformation(m_scene.RegionInfo.RegionSettings.Covenant); remote_client.SendEstateCovenantInformation(m_scene.RegionInfo.RegionSettings.Covenant);
} }
private void HandleLandStatRequest(int parcelID, uint reportType, uint requestFlags, string filter, IClientAPI remoteClient) private void HandleLandStatRequest(int parcelID, uint reportType, uint requestFlags, string filter, IClientAPI remoteClient)
{ {
Dictionary<uint, float> SceneData = new Dictionary<uint,float>(); Dictionary<uint, float> SceneData = new Dictionary<uint,float>();

View File

@ -53,8 +53,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
private LandChannel landChannel; private LandChannel landChannel;
private Scene m_scene; private Scene m_scene;
private readonly int[,] landIDList = new int[64, 64]; private readonly int[,] landIDList = new int[64, 64];
private readonly Dictionary<int, ILandObject> landList = new Dictionary<int, ILandObject>(); private readonly Dictionary<int, ILandObject> landList = new Dictionary<int, ILandObject>();
@ -115,8 +113,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
} }
} }
public void PostInitialise() public void PostInitialise()
{ {
} }
@ -153,8 +149,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
} }
} }
public bool AllowedForcefulBans public bool AllowedForcefulBans
{ {
get { return m_allowedForcefulBans; } get { return m_allowedForcefulBans; }
@ -185,11 +179,9 @@ namespace OpenSim.Region.Environment.Modules.World.Land
public List<ILandObject> ParcelsNearPoint(LLVector3 position) public List<ILandObject> ParcelsNearPoint(LLVector3 position)
{ {
List<ILandObject> parcelsNear = new List<ILandObject>(); List<ILandObject> parcelsNear = new List<ILandObject>();
int x; for (int x = -4; x <= 4; x += 4)
for (x = -4; x <= 4; x += 4)
{ {
int y; for (int y = -4; y <= 4; y += 4)
for (y = -4; y <= 4; y += 4)
{ {
ILandObject check = GetLandObject(position.X + x, position.Y + y); ILandObject check = GetLandObject(position.X + x, position.Y + y);
if (check != null) if (check != null)
@ -286,7 +278,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
ILandObject over = GetLandObject((int)Math.Min(255, Math.Max(0, Math.Round(avatar.AbsolutePosition.X))), ILandObject over = GetLandObject((int)Math.Min(255, Math.Max(0, Math.Round(avatar.AbsolutePosition.X))),
(int)Math.Min(255, Math.Max(0, Math.Round(avatar.AbsolutePosition.Y)))); (int)Math.Min(255, Math.Max(0, Math.Round(avatar.AbsolutePosition.Y))));
if (over != null) if (over != null)
{ {
if (force) if (force)
@ -387,6 +378,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land
Console.WriteLine("INVALID LOCAL LAND ID"); Console.WriteLine("INVALID LOCAL LAND ID");
} }
} }
/// <summary> /// <summary>
/// Creates a basic Parcel object without an owner (a zeroed key) /// Creates a basic Parcel object without an owner (a zeroed key)
/// </summary> /// </summary>
@ -406,13 +398,10 @@ namespace OpenSim.Region.Environment.Modules.World.Land
new_land.landData.LocalID = lastLandLocalID; new_land.landData.LocalID = lastLandLocalID;
landList.Add(lastLandLocalID, new_land.Copy()); landList.Add(lastLandLocalID, new_land.Copy());
bool[,] landBitmap = new_land.getLandBitmap(); bool[,] landBitmap = new_land.getLandBitmap();
int x; for (int x = 0; x < 64; x++)
for (x = 0; x < 64; x++)
{ {
int y; for (int y = 0; y < 64; y++)
for (y = 0; y < 64; y++)
{ {
if (landBitmap[x, y]) if (landBitmap[x, y])
{ {
@ -431,11 +420,9 @@ namespace OpenSim.Region.Environment.Modules.World.Land
/// <param name="local_id">Land.localID of the peice of land to remove.</param> /// <param name="local_id">Land.localID of the peice of land to remove.</param>
public void removeLandObject(int local_id) public void removeLandObject(int local_id)
{ {
int x; for (int x = 0; x < 64; x++)
for (x = 0; x < 64; x++)
{ {
int y; for (int y = 0; y < 64; y++)
for (y = 0; y < 64; y++)
{ {
if (landIDList[x, y] == local_id) if (landIDList[x, y] == local_id)
{ {
@ -451,12 +438,10 @@ namespace OpenSim.Region.Environment.Modules.World.Land
private void performFinalLandJoin(ILandObject master, ILandObject slave) private void performFinalLandJoin(ILandObject master, ILandObject slave)
{ {
int x;
bool[,] landBitmapSlave = slave.getLandBitmap(); bool[,] landBitmapSlave = slave.getLandBitmap();
for (x = 0; x < 64; x++) for (int x = 0; x < 64; x++)
{ {
int y; for (int y = 0; y < 64; y++)
for (y = 0; y < 64; y++)
{ {
if (landBitmapSlave[x, y]) if (landBitmapSlave[x, y])
{ {
@ -519,6 +504,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land
} }
return landList[landIDList[x / 4, y / 4]]; return landList[landIDList[x / 4, y / 4]];
} }
#endregion #endregion
#region Parcel Modification #region Parcel Modification
@ -647,11 +633,9 @@ namespace OpenSim.Region.Environment.Modules.World.Land
{ {
int totalX = end_x - start_x; int totalX = end_x - start_x;
int totalY = end_y - start_y; int totalY = end_y - start_y;
int y; for (int y = 0; y < totalY; y++)
for (y = 0; y < totalY; y++)
{ {
int x; for (int x = 0; x < totalX; x++)
for (x = 0; x < totalX; x++)
{ {
ILandObject tempLandObject = GetLandObject(start_x + x, start_y + y); ILandObject tempLandObject = GetLandObject(start_x + x, start_y + y);
if (tempLandObject == null) return; if (tempLandObject == null) return;
@ -690,9 +674,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
ILandObject result = AddLandObject(newLand); ILandObject result = AddLandObject(newLand);
UpdateLandObject(startLandObject.landData.LocalID, startLandObject.landData); UpdateLandObject(startLandObject.landData.LocalID, startLandObject.landData);
result.sendLandUpdateToAvatarsOverMe(); result.sendLandUpdateToAvatarsOverMe();
return;
} }
/// <summary> /// <summary>
@ -730,7 +711,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
ILandObject masterLandObject = selectedLandObjects[0]; ILandObject masterLandObject = selectedLandObjects[0];
selectedLandObjects.RemoveAt(0); selectedLandObjects.RemoveAt(0);
if (selectedLandObjects.Count < 1) if (selectedLandObjects.Count < 1)
{ {
return; return;
@ -753,12 +733,9 @@ namespace OpenSim.Region.Environment.Modules.World.Land
performFinalLandJoin(masterLandObject, slaveLandObject); performFinalLandJoin(masterLandObject, slaveLandObject);
} }
SetPrimsTainted(); SetPrimsTainted();
masterLandObject.sendLandUpdateToAvatarsOverMe(); masterLandObject.sendLandUpdateToAvatarsOverMe();
return;
} }
#endregion #endregion
@ -777,17 +754,14 @@ namespace OpenSim.Region.Environment.Modules.World.Land
int byteArrayCount = 0; int byteArrayCount = 0;
int sequenceID = 0; int sequenceID = 0;
int y; for (int y = 0; y < 64; y++)
for (y = 0; y < 64; y++)
{ {
int x; for (int x = 0; x < 64; x++)
for (x = 0; x < 64; x++)
{ {
byte tempByte = 0; //This represents the byte for the current 4x4 byte tempByte = 0; //This represents the byte for the current 4x4
ILandObject currentParcelBlock = GetLandObject(x * 4, y * 4); ILandObject currentParcelBlock = GetLandObject(x * 4, y * 4);
if (currentParcelBlock != null) if (currentParcelBlock != null)
{ {
if (currentParcelBlock.landData.OwnerID == remote_client.AgentId) if (currentParcelBlock.landData.OwnerID == remote_client.AgentId)
@ -813,7 +787,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
tempByte = Convert.ToByte(tempByte | LandChannel.LAND_TYPE_OWNED_BY_OTHER); tempByte = Convert.ToByte(tempByte | LandChannel.LAND_TYPE_OWNED_BY_OTHER);
} }
//Now for border control //Now for border control
ILandObject westParcel = null; ILandObject westParcel = null;
@ -864,14 +837,11 @@ namespace OpenSim.Region.Environment.Modules.World.Land
{ {
//Get the land objects within the bounds //Get the land objects within the bounds
List<ILandObject> temp = new List<ILandObject>(); List<ILandObject> temp = new List<ILandObject>();
int x;
int i;
int inc_x = end_x - start_x; int inc_x = end_x - start_x;
int inc_y = end_y - start_y; int inc_y = end_y - start_y;
for (x = 0; x < inc_x; x++) for (int x = 0; x < inc_x; x++)
{ {
int y; for (int y = 0; y < inc_y; y++)
for (y = 0; y < inc_y; y++)
{ {
ILandObject currentParcel = GetLandObject(start_x + x, start_y + y); ILandObject currentParcel = GetLandObject(start_x + x, start_y + y);
@ -892,12 +862,11 @@ namespace OpenSim.Region.Environment.Modules.World.Land
requestResult = LandChannel.LAND_RESULT_MULTIPLE; requestResult = LandChannel.LAND_RESULT_MULTIPLE;
} }
for (i = 0; i < temp.Count; i++) for (int i = 0; i < temp.Count; i++)
{ {
temp[i].sendLandProperties(sequence_id, snap_selection, requestResult, remote_client); temp[i].sendLandProperties(sequence_id, snap_selection, requestResult, remote_client);
} }
SendParcelOverlay(remote_client); SendParcelOverlay(remote_client);
} }
@ -921,7 +890,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
public void handleParcelSelectObjectsRequest(int local_id, int request_type, IClientAPI remote_client) public void handleParcelSelectObjectsRequest(int local_id, int request_type, IClientAPI remote_client)
{ {
landList[local_id].sendForceObjectSelect(local_id, request_type, remote_client); landList[local_id].sendForceObjectSelect(local_id, request_type, remote_client);
} }
@ -954,7 +922,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
landList[local_id].sendLandUpdateToClient(remote_client); landList[local_id].sendLandUpdateToClient(remote_client);
} }
} }
} }
public void handleParcelReclaim(int local_id, IClientAPI remote_client) public void handleParcelReclaim(int local_id, IClientAPI remote_client)
@ -972,7 +939,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
landList[local_id].sendLandUpdateToClient(remote_client); landList[local_id].sendLandUpdateToClient(remote_client);
} }
} }
} }
#endregion #endregion
@ -1076,7 +1042,6 @@ namespace OpenSim.Region.Environment.Modules.World.Land
{ {
selectedParcel.returnLandObjects(returnType, agentIDs, remoteClient); selectedParcel.returnLandObjects(returnType, agentIDs, remoteClient);
} }
} }
public void NoLandDataFromStorage() public void NoLandDataFromStorage()
@ -1093,11 +1058,13 @@ namespace OpenSim.Region.Environment.Modules.World.Land
obj.setParcelObjectMaxOverride(overrideDel); obj.setParcelObjectMaxOverride(overrideDel);
} }
} }
public void setSimulatorObjectMaxOverride(overrideSimulatorMaxPrimCountDelegate overrideDel) public void setSimulatorObjectMaxOverride(overrideSimulatorMaxPrimCountDelegate overrideDel)
{ {
} }
#region CAPS handler #region CAPS handler
private void OnRegisterCaps(LLUUID agentID, Caps caps) private void OnRegisterCaps(LLUUID agentID, Caps caps)
{ {
string capsBase = "/CAPS/" + caps.CapsObjectPath; string capsBase = "/CAPS/" + caps.CapsObjectPath;

View File

@ -103,10 +103,6 @@ namespace OpenSim.Region.Environment.Modules.World.WorldMap
#endregion #endregion
public void OnRegisterCaps(LLUUID agentID, Caps caps) public void OnRegisterCaps(LLUUID agentID, Caps caps)
{ {
m_log.DebugFormat("[VOICE] OnRegisterCaps: agentID {0} caps {1}", agentID, caps); m_log.DebugFormat("[VOICE] OnRegisterCaps: agentID {0} caps {1}", agentID, caps);
@ -119,7 +115,6 @@ namespace OpenSim.Region.Environment.Modules.World.WorldMap
return MapLayerRequest(request, path, param, return MapLayerRequest(request, path, param,
agentID, caps); agentID, caps);
})); }));
} }
/// <summary> /// <summary>
@ -263,12 +258,10 @@ namespace OpenSim.Region.Environment.Modules.World.WorldMap
Bitmap mapTexture = new Bitmap(1,1); Bitmap mapTexture = new Bitmap(1,1);
System.Drawing.Image image = (System.Drawing.Image)mapTexture; System.Drawing.Image image = (System.Drawing.Image)mapTexture;
try try
{ {
// Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular jpeg data // Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular jpeg data
imgstream = new MemoryStream(); imgstream = new MemoryStream();
// non-async because we know we have the asset immediately. // non-async because we know we have the asset immediately.
@ -332,16 +325,14 @@ namespace OpenSim.Region.Environment.Modules.World.WorldMap
// From msdn // From msdn
private static ImageCodecInfo GetEncoderInfo(String mimeType) private static ImageCodecInfo GetEncoderInfo(String mimeType)
{ {
int j;
ImageCodecInfo[] encoders; ImageCodecInfo[] encoders;
encoders = ImageCodecInfo.GetImageEncoders(); encoders = ImageCodecInfo.GetImageEncoders();
for (j = 0; j < encoders.Length; ++j) for (int j = 0; j < encoders.Length; ++j)
{ {
if (encoders[j].MimeType == mimeType) if (encoders[j].MimeType == mimeType)
return encoders[j]; return encoders[j];
} }
return null; return null;
} }
} }
} }

View File

@ -131,13 +131,10 @@ namespace OpenSim.Region.Environment.Scenes
public event AvatarEnteringNewParcel OnAvatarEnteringNewParcel; public event AvatarEnteringNewParcel OnAvatarEnteringNewParcel;
public delegate void SignificantClientMovement(IClientAPI remote_client); public delegate void SignificantClientMovement(IClientAPI remote_client);
public event SignificantClientMovement OnSignificantClientMovement; public event SignificantClientMovement OnSignificantClientMovement;
public delegate void NewGridInstantMessage(GridInstantMessage message); public delegate void NewGridInstantMessage(GridInstantMessage message);
public event NewGridInstantMessage OnGridInstantMessageToIMModule; public event NewGridInstantMessage OnGridInstantMessageToIMModule;
@ -172,8 +169,6 @@ namespace OpenSim.Region.Environment.Scenes
public event ScriptColliding OnScriptColliding; public event ScriptColliding OnScriptColliding;
public event ScriptColliding OnScriptCollidingEnd; public event ScriptColliding OnScriptCollidingEnd;
public delegate void OnMakeChildAgentDelegate(ScenePresence presence); public delegate void OnMakeChildAgentDelegate(ScenePresence presence);
public event OnMakeChildAgentDelegate OnMakeChildAgent; public event OnMakeChildAgentDelegate OnMakeChildAgent;
@ -289,7 +284,6 @@ namespace OpenSim.Region.Environment.Scenes
public int transactionID = 0; public int transactionID = 0;
public int amountDebited = 0; public int amountDebited = 0;
public LandBuyArgs(LLUUID pagentId, LLUUID pgroupId, bool pfinal, bool pgroupOwned, public LandBuyArgs(LLUUID pagentId, LLUUID pgroupId, bool pfinal, bool pgroupOwned,
bool premoveContribution, int pparcelLocalID, int pparcelArea, int pparcelPrice, bool premoveContribution, int pparcelLocalID, int pparcelArea, int pparcelPrice,
bool pauthenticated) bool pauthenticated)
@ -306,8 +300,6 @@ namespace OpenSim.Region.Environment.Scenes
} }
} }
public delegate void MoneyTransferEvent(Object sender, MoneyTransferArgs e); public delegate void MoneyTransferEvent(Object sender, MoneyTransferArgs e);
public delegate void LandBuy(Object sender, LandBuyArgs e); public delegate void LandBuy(Object sender, LandBuyArgs e);
@ -377,7 +369,6 @@ namespace OpenSim.Region.Environment.Scenes
private ScriptColliding handlerColliding = null; private ScriptColliding handlerColliding = null;
private ScriptColliding handlerCollidingEnd = null; private ScriptColliding handlerCollidingEnd = null;
private SunLindenHour handlerSunGetLindenHour = null; private SunLindenHour handlerSunGetLindenHour = null;
public void TriggerOnScriptChangedEvent(uint localID, uint change) public void TriggerOnScriptChangedEvent(uint localID, uint change)
@ -491,7 +482,6 @@ namespace OpenSim.Region.Environment.Scenes
if (handlerObjectBeingRemovedFromScene != null) if (handlerObjectBeingRemovedFromScene != null)
{ {
handlerObjectBeingRemovedFromScene(obj); handlerObjectBeingRemovedFromScene(obj);
} }
} }
@ -641,7 +631,6 @@ namespace OpenSim.Region.Environment.Scenes
{ {
handlerGridInstantMessageToFriends(message); handlerGridInstantMessageToFriends(message);
} }
} }
} }
@ -698,7 +687,8 @@ namespace OpenSim.Region.Environment.Scenes
handlerNewInventoryItemUpdateComplete(agentID, AssetID, AssetName, userlevel); handlerNewInventoryItemUpdateComplete(agentID, AssetID, AssetName, userlevel);
} }
} }
public void TriggerLandBuy (Object sender, LandBuyArgs e)
public void TriggerLandBuy(Object sender, LandBuyArgs e)
{ {
handlerLandBuy = OnLandBuy; handlerLandBuy = OnLandBuy;
if (handlerLandBuy != null) if (handlerLandBuy != null)
@ -706,6 +696,7 @@ namespace OpenSim.Region.Environment.Scenes
handlerLandBuy(sender, e); handlerLandBuy(sender, e);
} }
} }
public void TriggerValidateLandBuy(Object sender, LandBuyArgs e) public void TriggerValidateLandBuy(Object sender, LandBuyArgs e)
{ {
handlerValidateLandBuy = OnValidateLandBuy; handlerValidateLandBuy = OnValidateLandBuy;
@ -741,6 +732,7 @@ namespace OpenSim.Region.Environment.Scenes
handlerRequestChangeWaterHeight(height); handlerRequestChangeWaterHeight(height);
} }
} }
public void TriggerAvatarKill(uint KillerObjectLocalID, ScenePresence DeadAvatar) public void TriggerAvatarKill(uint KillerObjectLocalID, ScenePresence DeadAvatar)
{ {
handlerAvatarKill = OnAvatarKilled; handlerAvatarKill = OnAvatarKilled;
@ -756,7 +748,6 @@ namespace OpenSim.Region.Environment.Scenes
if (handlerSignificantClientMovement != null) if (handlerSignificantClientMovement != null)
{ {
handlerSignificantClientMovement(client); handlerSignificantClientMovement(client);
} }
} }
@ -787,7 +778,6 @@ namespace OpenSim.Region.Environment.Scenes
} }
} }
public void TriggerNoticeNoLandDataFromStorage() public void TriggerNoticeNoLandDataFromStorage()
{ {
handlerNoticeNoLandDataFromStorage = OnNoticeNoLandDataFromStorage; handlerNoticeNoLandDataFromStorage = OnNoticeNoLandDataFromStorage;
@ -818,26 +808,24 @@ namespace OpenSim.Region.Environment.Scenes
} }
} }
public void TriggerRequestParcelPrimCountUpdate() public void TriggerRequestParcelPrimCountUpdate()
{ {
handlerRequestParcelPrimCountUpdate = OnRequestParcelPrimCountUpdate; handlerRequestParcelPrimCountUpdate = OnRequestParcelPrimCountUpdate;
if (handlerRequestParcelPrimCountUpdate != null) if (handlerRequestParcelPrimCountUpdate != null)
{ {
handlerRequestParcelPrimCountUpdate(); handlerRequestParcelPrimCountUpdate();
}
}
}
}
public void TriggerParcelPrimCountTainted() public void TriggerParcelPrimCountTainted()
{ {
handlerParcelPrimCountTainted = OnParcelPrimCountTainted; handlerParcelPrimCountTainted = OnParcelPrimCountTainted;
if (handlerParcelPrimCountTainted != null) if (handlerParcelPrimCountTainted != null)
{ {
handlerParcelPrimCountTainted(); handlerParcelPrimCountTainted();
}
}
}
}
// this lets us keep track of nasty script events like timer, etc. // this lets us keep track of nasty script events like timer, etc.
public void TriggerTimerEvent(uint objLocalID, double Interval) public void TriggerTimerEvent(uint objLocalID, double Interval)
{ {
@ -845,9 +833,7 @@ namespace OpenSim.Region.Environment.Scenes
if (handlerScriptTimerEvent != null) if (handlerScriptTimerEvent != null)
{ {
handlerScriptTimerEvent(objLocalID, Interval); handlerScriptTimerEvent(objLocalID, Interval);
} }
} }
public void TriggerEstateToolsTimeUpdate(ulong regionHandle, bool FixedTime, bool useEstateTime, float LindenHour) public void TriggerEstateToolsTimeUpdate(ulong regionHandle, bool FixedTime, bool useEstateTime, float LindenHour)
@ -875,19 +861,19 @@ namespace OpenSim.Region.Environment.Scenes
if (handlerCollidingStart != null) if (handlerCollidingStart != null)
handlerCollidingStart(localId, colliders); handlerCollidingStart(localId, colliders);
} }
public void TriggerScriptColliding(uint localId, ColliderArgs colliders) public void TriggerScriptColliding(uint localId, ColliderArgs colliders)
{ {
handlerColliding = OnScriptColliding; handlerColliding = OnScriptColliding;
if (handlerColliding != null) if (handlerColliding != null)
handlerColliding(localId, colliders); handlerColliding(localId, colliders);
} }
public void TriggerScriptCollidingEnd(uint localId, ColliderArgs colliders) public void TriggerScriptCollidingEnd(uint localId, ColliderArgs colliders)
{ {
handlerCollidingEnd = OnScriptCollidingEnd; handlerCollidingEnd = OnScriptCollidingEnd;
if (handlerCollidingEnd != null) if (handlerCollidingEnd != null)
handlerCollidingEnd(localId, colliders); handlerCollidingEnd(localId, colliders);
} }
} }
} }

View File

@ -339,7 +339,6 @@ namespace OpenSim.Region.Environment.Scenes
else else
item.CreationDate = itemUpd.CreationDate; item.CreationDate = itemUpd.CreationDate;
// TODO: Check if folder changed and move item // TODO: Check if folder changed and move item
//item.NextPermissions = itemUpd.Folder; //item.NextPermissions = itemUpd.Folder;
item.InvType = itemUpd.InvType; item.InvType = itemUpd.InvType;

View File

@ -1,4 +1,4 @@
/* /*
* Copyright (c) Contributors, http://opensimulator.org/ * Copyright (c) Contributors, http://opensimulator.org/
* See CONTRIBUTORS.TXT for a full list of copyright holders. * See CONTRIBUTORS.TXT for a full list of copyright holders.
* *
@ -53,6 +53,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!GenerateClientFlagsCheckFunctions.Contains(delegateFunc)) if (!GenerateClientFlagsCheckFunctions.Contains(delegateFunc))
GenerateClientFlagsCheckFunctions.Add(delegateFunc); GenerateClientFlagsCheckFunctions.Add(delegateFunc);
} }
public void removeGenerateClientFlags(GenerateClientFlags delegateFunc) public void removeGenerateClientFlags(GenerateClientFlags delegateFunc)
{ {
if (GenerateClientFlagsCheckFunctions.Contains(delegateFunc)) if (GenerateClientFlagsCheckFunctions.Contains(delegateFunc))
@ -91,6 +92,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!SetBypassPermissionsCheckFunctions.Contains(delegateFunc)) if (!SetBypassPermissionsCheckFunctions.Contains(delegateFunc))
SetBypassPermissionsCheckFunctions.Add(delegateFunc); SetBypassPermissionsCheckFunctions.Add(delegateFunc);
} }
public void removeSetBypassPermissions(SetBypassPermissions delegateFunc) public void removeSetBypassPermissions(SetBypassPermissions delegateFunc)
{ {
if (SetBypassPermissionsCheckFunctions.Contains(delegateFunc)) if (SetBypassPermissionsCheckFunctions.Contains(delegateFunc))
@ -113,6 +115,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!BypassPermissionsCheckFunctions.Contains(delegateFunc)) if (!BypassPermissionsCheckFunctions.Contains(delegateFunc))
BypassPermissionsCheckFunctions.Add(delegateFunc); BypassPermissionsCheckFunctions.Add(delegateFunc);
} }
public void removeBypassPermissions(BypassPermissions delegateFunc) public void removeBypassPermissions(BypassPermissions delegateFunc)
{ {
if (BypassPermissionsCheckFunctions.Contains(delegateFunc)) if (BypassPermissionsCheckFunctions.Contains(delegateFunc))
@ -139,6 +142,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!PropagatePermissionsCheckFunctions.Contains(delegateFunc)) if (!PropagatePermissionsCheckFunctions.Contains(delegateFunc))
PropagatePermissionsCheckFunctions.Add(delegateFunc); PropagatePermissionsCheckFunctions.Add(delegateFunc);
} }
public void removePropagatePermissions(PropagatePermissions delegateFunc) public void removePropagatePermissions(PropagatePermissions delegateFunc)
{ {
if (PropagatePermissionsCheckFunctions.Contains(delegateFunc)) if (PropagatePermissionsCheckFunctions.Contains(delegateFunc))
@ -166,6 +170,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanRezObjectCheckFunctions.Contains(delegateFunc)) if (!CanRezObjectCheckFunctions.Contains(delegateFunc))
CanRezObjectCheckFunctions.Add(delegateFunc); CanRezObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckRezObject(CanRezObject delegateFunc) public void removeCheckRezObject(CanRezObject delegateFunc)
{ {
if (CanRezObjectCheckFunctions.Contains(delegateFunc)) if (CanRezObjectCheckFunctions.Contains(delegateFunc))
@ -195,6 +200,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanDeleteObjectCheckFunctions.Contains(delegateFunc)) if (!CanDeleteObjectCheckFunctions.Contains(delegateFunc))
CanDeleteObjectCheckFunctions.Add(delegateFunc); CanDeleteObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckDeleteObject(CanDeleteObject delegateFunc) public void removeCheckDeleteObject(CanDeleteObject delegateFunc)
{ {
if (CanDeleteObjectCheckFunctions.Contains(delegateFunc)) if (CanDeleteObjectCheckFunctions.Contains(delegateFunc))
@ -224,6 +230,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanTakeObjectCheckFunctions.Contains(delegateFunc)) if (!CanTakeObjectCheckFunctions.Contains(delegateFunc))
CanTakeObjectCheckFunctions.Add(delegateFunc); CanTakeObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckTakeObject(CanTakeObject delegateFunc) public void removeCheckTakeObject(CanTakeObject delegateFunc)
{ {
if (CanTakeObjectCheckFunctions.Contains(delegateFunc)) if (CanTakeObjectCheckFunctions.Contains(delegateFunc))
@ -253,6 +260,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanTakeCopyObjectCheckFunctions.Contains(delegateFunc)) if (!CanTakeCopyObjectCheckFunctions.Contains(delegateFunc))
CanTakeCopyObjectCheckFunctions.Add(delegateFunc); CanTakeCopyObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckTakeCopyObject(CanTakeCopyObject delegateFunc) public void removeCheckTakeCopyObject(CanTakeCopyObject delegateFunc)
{ {
if (CanTakeCopyObjectCheckFunctions.Contains(delegateFunc)) if (CanTakeCopyObjectCheckFunctions.Contains(delegateFunc))
@ -282,6 +290,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanDuplicateObjectCheckFunctions.Contains(delegateFunc)) if (!CanDuplicateObjectCheckFunctions.Contains(delegateFunc))
CanDuplicateObjectCheckFunctions.Add(delegateFunc); CanDuplicateObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckDuplicateObject(CanDuplicateObject delegateFunc) public void removeCheckDuplicateObject(CanDuplicateObject delegateFunc)
{ {
if (CanDuplicateObjectCheckFunctions.Contains(delegateFunc)) if (CanDuplicateObjectCheckFunctions.Contains(delegateFunc))
@ -311,6 +320,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanEditObjectCheckFunctions.Contains(delegateFunc)) if (!CanEditObjectCheckFunctions.Contains(delegateFunc))
CanEditObjectCheckFunctions.Add(delegateFunc); CanEditObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckEditObject(CanEditObject delegateFunc) public void removeCheckEditObject(CanEditObject delegateFunc)
{ {
if (CanEditObjectCheckFunctions.Contains(delegateFunc)) if (CanEditObjectCheckFunctions.Contains(delegateFunc))
@ -340,6 +350,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanMoveObjectCheckFunctions.Contains(delegateFunc)) if (!CanMoveObjectCheckFunctions.Contains(delegateFunc))
CanMoveObjectCheckFunctions.Add(delegateFunc); CanMoveObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckMoveObject(CanMoveObject delegateFunc) public void removeCheckMoveObject(CanMoveObject delegateFunc)
{ {
if (CanMoveObjectCheckFunctions.Contains(delegateFunc)) if (CanMoveObjectCheckFunctions.Contains(delegateFunc))
@ -369,6 +380,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanObjectEntryCheckFunctions.Contains(delegateFunc)) if (!CanObjectEntryCheckFunctions.Contains(delegateFunc))
CanObjectEntryCheckFunctions.Add(delegateFunc); CanObjectEntryCheckFunctions.Add(delegateFunc);
} }
public void removeCheckObjectEntry(CanObjectEntry delegateFunc) public void removeCheckObjectEntry(CanObjectEntry delegateFunc)
{ {
if (CanObjectEntryCheckFunctions.Contains(delegateFunc)) if (CanObjectEntryCheckFunctions.Contains(delegateFunc))
@ -398,6 +410,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanReturnObjectCheckFunctions.Contains(delegateFunc)) if (!CanReturnObjectCheckFunctions.Contains(delegateFunc))
CanReturnObjectCheckFunctions.Add(delegateFunc); CanReturnObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckReturnObject(CanReturnObject delegateFunc) public void removeCheckReturnObject(CanReturnObject delegateFunc)
{ {
if (CanReturnObjectCheckFunctions.Contains(delegateFunc)) if (CanReturnObjectCheckFunctions.Contains(delegateFunc))
@ -427,6 +440,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanInstantMessageCheckFunctions.Contains(delegateFunc)) if (!CanInstantMessageCheckFunctions.Contains(delegateFunc))
CanInstantMessageCheckFunctions.Add(delegateFunc); CanInstantMessageCheckFunctions.Add(delegateFunc);
} }
public void removeCheckInstantMessage(CanInstantMessage delegateFunc) public void removeCheckInstantMessage(CanInstantMessage delegateFunc)
{ {
if (CanInstantMessageCheckFunctions.Contains(delegateFunc)) if (CanInstantMessageCheckFunctions.Contains(delegateFunc))
@ -456,6 +470,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanInventoryTransferCheckFunctions.Contains(delegateFunc)) if (!CanInventoryTransferCheckFunctions.Contains(delegateFunc))
CanInventoryTransferCheckFunctions.Add(delegateFunc); CanInventoryTransferCheckFunctions.Add(delegateFunc);
} }
public void removeCheckInventoryTransfer(CanInventoryTransfer delegateFunc) public void removeCheckInventoryTransfer(CanInventoryTransfer delegateFunc)
{ {
if (CanInventoryTransferCheckFunctions.Contains(delegateFunc)) if (CanInventoryTransferCheckFunctions.Contains(delegateFunc))
@ -485,6 +500,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanViewScriptCheckFunctions.Contains(delegateFunc)) if (!CanViewScriptCheckFunctions.Contains(delegateFunc))
CanViewScriptCheckFunctions.Add(delegateFunc); CanViewScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckViewScript(CanViewScript delegateFunc) public void removeCheckViewScript(CanViewScript delegateFunc)
{ {
if (CanViewScriptCheckFunctions.Contains(delegateFunc)) if (CanViewScriptCheckFunctions.Contains(delegateFunc))
@ -511,6 +527,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanViewNotecardCheckFunctions.Contains(delegateFunc)) if (!CanViewNotecardCheckFunctions.Contains(delegateFunc))
CanViewNotecardCheckFunctions.Add(delegateFunc); CanViewNotecardCheckFunctions.Add(delegateFunc);
} }
public void removeCheckViewNotecard(CanViewNotecard delegateFunc) public void removeCheckViewNotecard(CanViewNotecard delegateFunc)
{ {
if (CanViewNotecardCheckFunctions.Contains(delegateFunc)) if (CanViewNotecardCheckFunctions.Contains(delegateFunc))
@ -540,6 +557,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanEditScriptCheckFunctions.Contains(delegateFunc)) if (!CanEditScriptCheckFunctions.Contains(delegateFunc))
CanEditScriptCheckFunctions.Add(delegateFunc); CanEditScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckEditScript(CanEditScript delegateFunc) public void removeCheckEditScript(CanEditScript delegateFunc)
{ {
if (CanEditScriptCheckFunctions.Contains(delegateFunc)) if (CanEditScriptCheckFunctions.Contains(delegateFunc))
@ -566,6 +584,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanEditNotecardCheckFunctions.Contains(delegateFunc)) if (!CanEditNotecardCheckFunctions.Contains(delegateFunc))
CanEditNotecardCheckFunctions.Add(delegateFunc); CanEditNotecardCheckFunctions.Add(delegateFunc);
} }
public void removeCheckEditNotecard(CanEditNotecard delegateFunc) public void removeCheckEditNotecard(CanEditNotecard delegateFunc)
{ {
if (CanEditNotecardCheckFunctions.Contains(delegateFunc)) if (CanEditNotecardCheckFunctions.Contains(delegateFunc))
@ -595,6 +614,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanRunScriptCheckFunctions.Contains(delegateFunc)) if (!CanRunScriptCheckFunctions.Contains(delegateFunc))
CanRunScriptCheckFunctions.Add(delegateFunc); CanRunScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckRunScript(CanRunScript delegateFunc) public void removeCheckRunScript(CanRunScript delegateFunc)
{ {
if (CanRunScriptCheckFunctions.Contains(delegateFunc)) if (CanRunScriptCheckFunctions.Contains(delegateFunc))
@ -624,6 +644,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanStartScriptCheckFunctions.Contains(delegateFunc)) if (!CanStartScriptCheckFunctions.Contains(delegateFunc))
CanStartScriptCheckFunctions.Add(delegateFunc); CanStartScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckStartScript(CanStartScript delegateFunc) public void removeCheckStartScript(CanStartScript delegateFunc)
{ {
if (CanStartScriptCheckFunctions.Contains(delegateFunc)) if (CanStartScriptCheckFunctions.Contains(delegateFunc))
@ -653,6 +674,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanStopScriptCheckFunctions.Contains(delegateFunc)) if (!CanStopScriptCheckFunctions.Contains(delegateFunc))
CanStopScriptCheckFunctions.Add(delegateFunc); CanStopScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckStopScript(CanStopScript delegateFunc) public void removeCheckStopScript(CanStopScript delegateFunc)
{ {
if (CanStopScriptCheckFunctions.Contains(delegateFunc)) if (CanStopScriptCheckFunctions.Contains(delegateFunc))
@ -682,6 +704,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanResetScriptCheckFunctions.Contains(delegateFunc)) if (!CanResetScriptCheckFunctions.Contains(delegateFunc))
CanResetScriptCheckFunctions.Add(delegateFunc); CanResetScriptCheckFunctions.Add(delegateFunc);
} }
public void removeCheckResetScript(CanResetScript delegateFunc) public void removeCheckResetScript(CanResetScript delegateFunc)
{ {
if (CanResetScriptCheckFunctions.Contains(delegateFunc)) if (CanResetScriptCheckFunctions.Contains(delegateFunc))
@ -711,6 +734,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanTerraformLandCheckFunctions.Contains(delegateFunc)) if (!CanTerraformLandCheckFunctions.Contains(delegateFunc))
CanTerraformLandCheckFunctions.Add(delegateFunc); CanTerraformLandCheckFunctions.Add(delegateFunc);
} }
public void removeCheckTerraformLand(CanTerraformLand delegateFunc) public void removeCheckTerraformLand(CanTerraformLand delegateFunc)
{ {
if (CanTerraformLandCheckFunctions.Contains(delegateFunc)) if (CanTerraformLandCheckFunctions.Contains(delegateFunc))
@ -740,6 +764,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanRunConsoleCommandCheckFunctions.Contains(delegateFunc)) if (!CanRunConsoleCommandCheckFunctions.Contains(delegateFunc))
CanRunConsoleCommandCheckFunctions.Add(delegateFunc); CanRunConsoleCommandCheckFunctions.Add(delegateFunc);
} }
public void removeCheckRunConsoleCommand(CanRunConsoleCommand delegateFunc) public void removeCheckRunConsoleCommand(CanRunConsoleCommand delegateFunc)
{ {
if (CanRunConsoleCommandCheckFunctions.Contains(delegateFunc)) if (CanRunConsoleCommandCheckFunctions.Contains(delegateFunc))
@ -769,6 +794,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanIssueEstateCommandCheckFunctions.Contains(delegateFunc)) if (!CanIssueEstateCommandCheckFunctions.Contains(delegateFunc))
CanIssueEstateCommandCheckFunctions.Add(delegateFunc); CanIssueEstateCommandCheckFunctions.Add(delegateFunc);
} }
public void removeCheckIssueEstateCommand(CanIssueEstateCommand delegateFunc) public void removeCheckIssueEstateCommand(CanIssueEstateCommand delegateFunc)
{ {
if (CanIssueEstateCommandCheckFunctions.Contains(delegateFunc)) if (CanIssueEstateCommandCheckFunctions.Contains(delegateFunc))
@ -797,6 +823,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanBeGodLikeCheckFunctions.Contains(delegateFunc)) if (!CanBeGodLikeCheckFunctions.Contains(delegateFunc))
CanBeGodLikeCheckFunctions.Add(delegateFunc); CanBeGodLikeCheckFunctions.Add(delegateFunc);
} }
public void removeCheckBeGodLike(CanBeGodLike delegateFunc) public void removeCheckBeGodLike(CanBeGodLike delegateFunc)
{ {
if (CanBeGodLikeCheckFunctions.Contains(delegateFunc)) if (CanBeGodLikeCheckFunctions.Contains(delegateFunc))
@ -825,6 +852,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanEditParcelCheckFunctions.Contains(delegateFunc)) if (!CanEditParcelCheckFunctions.Contains(delegateFunc))
CanEditParcelCheckFunctions.Add(delegateFunc); CanEditParcelCheckFunctions.Add(delegateFunc);
} }
public void removeCheckEditParcel(CanEditParcel delegateFunc) public void removeCheckEditParcel(CanEditParcel delegateFunc)
{ {
if (CanEditParcelCheckFunctions.Contains(delegateFunc)) if (CanEditParcelCheckFunctions.Contains(delegateFunc))
@ -853,6 +881,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanSellParcelCheckFunctions.Contains(delegateFunc)) if (!CanSellParcelCheckFunctions.Contains(delegateFunc))
CanSellParcelCheckFunctions.Add(delegateFunc); CanSellParcelCheckFunctions.Add(delegateFunc);
} }
public void removeCheckSellParcel(CanSellParcel delegateFunc) public void removeCheckSellParcel(CanSellParcel delegateFunc)
{ {
if (CanSellParcelCheckFunctions.Contains(delegateFunc)) if (CanSellParcelCheckFunctions.Contains(delegateFunc))
@ -881,6 +910,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanAbandonParcelCheckFunctions.Contains(delegateFunc)) if (!CanAbandonParcelCheckFunctions.Contains(delegateFunc))
CanAbandonParcelCheckFunctions.Add(delegateFunc); CanAbandonParcelCheckFunctions.Add(delegateFunc);
} }
public void removeCheckAbandonParcel(CanAbandonParcel delegateFunc) public void removeCheckAbandonParcel(CanAbandonParcel delegateFunc)
{ {
if (CanAbandonParcelCheckFunctions.Contains(delegateFunc)) if (CanAbandonParcelCheckFunctions.Contains(delegateFunc))
@ -908,6 +938,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanReclaimParcelCheckFunctions.Contains(delegateFunc)) if (!CanReclaimParcelCheckFunctions.Contains(delegateFunc))
CanReclaimParcelCheckFunctions.Add(delegateFunc); CanReclaimParcelCheckFunctions.Add(delegateFunc);
} }
public void removeCheckReclaimParcel(CanReclaimParcel delegateFunc) public void removeCheckReclaimParcel(CanReclaimParcel delegateFunc)
{ {
if (CanReclaimParcelCheckFunctions.Contains(delegateFunc)) if (CanReclaimParcelCheckFunctions.Contains(delegateFunc))
@ -933,6 +964,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanBuyLandCheckFunctions.Contains(delegateFunc)) if (!CanBuyLandCheckFunctions.Contains(delegateFunc))
CanBuyLandCheckFunctions.Add(delegateFunc); CanBuyLandCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanBuyLand(CanBuyLand delegateFunc) public void removeCheckCanBuyLand(CanBuyLand delegateFunc)
{ {
if (CanBuyLandCheckFunctions.Contains(delegateFunc)) if (CanBuyLandCheckFunctions.Contains(delegateFunc))
@ -959,6 +991,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanLinkObjectCheckFunctions.Contains(delegateFunc)) if (!CanLinkObjectCheckFunctions.Contains(delegateFunc))
CanLinkObjectCheckFunctions.Add(delegateFunc); CanLinkObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanLinkObject(CanLinkObject delegateFunc) public void removeCheckCanLinkObject(CanLinkObject delegateFunc)
{ {
if (CanLinkObjectCheckFunctions.Contains(delegateFunc)) if (CanLinkObjectCheckFunctions.Contains(delegateFunc))
@ -985,6 +1018,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanDelinkObjectCheckFunctions.Contains(delegateFunc)) if (!CanDelinkObjectCheckFunctions.Contains(delegateFunc))
CanDelinkObjectCheckFunctions.Add(delegateFunc); CanDelinkObjectCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanDelinkObject(CanDelinkObject delegateFunc) public void removeCheckCanDelinkObject(CanDelinkObject delegateFunc)
{ {
if (CanDelinkObjectCheckFunctions.Contains(delegateFunc)) if (CanDelinkObjectCheckFunctions.Contains(delegateFunc))
@ -1013,6 +1047,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanCreateInventoryCheckFunctions.Contains(delegateFunc)) if (!CanCreateInventoryCheckFunctions.Contains(delegateFunc))
CanCreateInventoryCheckFunctions.Add(delegateFunc); CanCreateInventoryCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanCreateInventory(CanCreateInventory delegateFunc) public void removeCheckCanCreateInventory(CanCreateInventory delegateFunc)
{ {
if (CanCreateInventoryCheckFunctions.Contains(delegateFunc)) if (CanCreateInventoryCheckFunctions.Contains(delegateFunc))
@ -1039,6 +1074,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanCopyInventoryCheckFunctions.Contains(delegateFunc)) if (!CanCopyInventoryCheckFunctions.Contains(delegateFunc))
CanCopyInventoryCheckFunctions.Add(delegateFunc); CanCopyInventoryCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanCopyInventory(CanCopyInventory delegateFunc) public void removeCheckCanCopyInventory(CanCopyInventory delegateFunc)
{ {
if (CanCopyInventoryCheckFunctions.Contains(delegateFunc)) if (CanCopyInventoryCheckFunctions.Contains(delegateFunc))
@ -1065,6 +1101,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanDeleteInventoryCheckFunctions.Contains(delegateFunc)) if (!CanDeleteInventoryCheckFunctions.Contains(delegateFunc))
CanDeleteInventoryCheckFunctions.Add(delegateFunc); CanDeleteInventoryCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanDeleteInventory(CanDeleteInventory delegateFunc) public void removeCheckCanDeleteInventory(CanDeleteInventory delegateFunc)
{ {
if (CanDeleteInventoryCheckFunctions.Contains(delegateFunc)) if (CanDeleteInventoryCheckFunctions.Contains(delegateFunc))
@ -1091,6 +1128,7 @@ namespace OpenSim.Region.Environment.Scenes
if (!CanTeleportCheckFunctions.Contains(delegateFunc)) if (!CanTeleportCheckFunctions.Contains(delegateFunc))
CanTeleportCheckFunctions.Add(delegateFunc); CanTeleportCheckFunctions.Add(delegateFunc);
} }
public void removeCheckCanTeleport(CanTeleport delegateFunc) public void removeCheckCanTeleport(CanTeleport delegateFunc)
{ {
if (CanTeleportCheckFunctions.Contains(delegateFunc)) if (CanTeleportCheckFunctions.Contains(delegateFunc))
@ -1110,4 +1148,3 @@ namespace OpenSim.Region.Environment.Scenes
} }
} }
} }

View File

@ -49,7 +49,6 @@ namespace OpenSim.Region.Examples.SimpleModule
public RotatingWheel() public RotatingWheel()
{ {
} }
public RotatingWheel(ulong regionHandle, SceneObjectGroup parent, LLUUID ownerID, uint localID, public RotatingWheel(ulong regionHandle, SceneObjectGroup parent, LLUUID ownerID, uint localID,
@ -78,7 +77,6 @@ namespace OpenSim.Region.Examples.SimpleModule
public ComplexObject() public ComplexObject()
{ {
} }
public ComplexObject(Scene scene, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos) public ComplexObject(Scene scene, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos)

View File

@ -48,6 +48,5 @@ namespace OpenSim.Region.Physics.Manager
int[] getIndexListAsIntLocked(); int[] getIndexListAsIntLocked();
float[] getVertexListAsFloatLocked(); float[] getVertexListAsFloatLocked();
void releasePinned(); void releasePinned();
} }
} }

View File

@ -209,10 +209,8 @@ namespace OpenSim.Region.Physics.Manager
public override bool Stopped public override bool Stopped
{ {
get{ return false; } get{ return false; }
} }
public override PhysicsVector Position public override PhysicsVector Position
{ {
get { return PhysicsVector.Zero; } get { return PhysicsVector.Zero; }

View File

@ -369,13 +369,11 @@ namespace OpenSim.Region.Physics.Meshing
float yOffset; float yOffset;
float zOffset; float zOffset;
xOffset = 0.5f * (skewStart + totalSkew * (float)percentOfPath); xOffset = 0.5f * (skewStart + totalSkew * (float)percentOfPath);
xOffset += (float) System.Math.Sin(angle) * pushX * 0.45f; xOffset += (float) System.Math.Sin(angle) * pushX * 0.45f;
yOffset = (float)(System.Math.Cos(angle) * (0.5f - yPathScale)) * radiusScale; yOffset = (float)(System.Math.Cos(angle) * (0.5f - yPathScale)) * radiusScale;
zOffset = (float)(System.Math.Sin(angle + pushY * 0.9f) * (0.5f - yPathScale)) * radiusScale; zOffset = (float)(System.Math.Sin(angle + pushY * 0.9f) * (0.5f - yPathScale)) * radiusScale;
// next apply twist rotation to the profile layer // next apply twist rotation to the profile layer
if (twistTotal != 0.0f || twistBot != 0.0f) if (twistTotal != 0.0f || twistBot != 0.0f)
{ {

View File

@ -252,7 +252,6 @@ namespace OpenSim.Region.Physics.OdePlugin
public int physics_logging_interval = 0; public int physics_logging_interval = 0;
public bool physics_logging_append_existing_logfile = false; public bool physics_logging_append_existing_logfile = false;
/// <summary> /// <summary>
/// Initiailizes the scene /// Initiailizes the scene
/// Sets many properties that ODE requires to be stable /// Sets many properties that ODE requires to be stable
@ -360,14 +359,12 @@ namespace OpenSim.Region.Physics.OdePlugin
meshSculptLOD = physicsconfig.GetFloat("mesh_lod", 32f); meshSculptLOD = physicsconfig.GetFloat("mesh_lod", 32f);
MeshSculptphysicalLOD = physicsconfig.GetFloat("mesh_physical_lod", 16f); MeshSculptphysicalLOD = physicsconfig.GetFloat("mesh_physical_lod", 16f);
if (Environment.OSVersion.Platform == PlatformID.Unix) if (Environment.OSVersion.Platform == PlatformID.Unix)
{ {
avPIDD = physicsconfig.GetFloat("av_pid_derivative_linux", 3200.0f); avPIDD = physicsconfig.GetFloat("av_pid_derivative_linux", 3200.0f);
avPIDP = physicsconfig.GetFloat("av_pid_proportional_linux", 1400.0f); avPIDP = physicsconfig.GetFloat("av_pid_proportional_linux", 1400.0f);
avStandupTensor = physicsconfig.GetFloat("av_capsule_standup_tensor_linux", 2000000f); avStandupTensor = physicsconfig.GetFloat("av_capsule_standup_tensor_linux", 2000000f);
bodyMotorJointMaxforceTensor = physicsconfig.GetFloat("body_motor_joint_maxforce_tensor_linux", 2f); bodyMotorJointMaxforceTensor = physicsconfig.GetFloat("body_motor_joint_maxforce_tensor_linux", 2f);
} }
else else
{ {
@ -547,7 +544,6 @@ namespace OpenSim.Region.Physics.OdePlugin
} }
catch (AccessViolationException) catch (AccessViolationException)
{ {
m_log.Warn("[PHYSICS]: Unable to collide test an object"); m_log.Warn("[PHYSICS]: Unable to collide test an object");
return; return;
} }
@ -604,7 +600,6 @@ namespace OpenSim.Region.Physics.OdePlugin
break; break;
} }
// we don't want prim or avatar to explode // we don't want prim or avatar to explode
#region InterPenetration Handling - Unintended physics explosions #region InterPenetration Handling - Unintended physics explosions
@ -1015,7 +1010,6 @@ namespace OpenSim.Region.Physics.OdePlugin
/// <param name="timeStep"></param> /// <param name="timeStep"></param>
private void collision_optimized(float timeStep) private void collision_optimized(float timeStep)
{ {
foreach (OdeCharacter chr in _characters) foreach (OdeCharacter chr in _characters)
{ {
// Reset the collision values to false // Reset the collision values to false
@ -1625,7 +1619,6 @@ namespace OpenSim.Region.Physics.OdePlugin
//m_log.Info(timeStep.ToString()); //m_log.Info(timeStep.ToString());
step_time += timeStep; step_time += timeStep;
// If We're loaded down by something else, // If We're loaded down by something else,
// or debugging with the Visual Studio project on pause // or debugging with the Visual Studio project on pause
// skip a few frames to catch up gracefully. // skip a few frames to catch up gracefully.
@ -1739,7 +1732,6 @@ namespace OpenSim.Region.Physics.OdePlugin
} }
d.WorldQuickStep(world, ODE_STEPSIZE); d.WorldQuickStep(world, ODE_STEPSIZE);
d.JointGroupEmpty(contactgroup); d.JointGroupEmpty(contactgroup);
//ode.dunlock(world); //ode.dunlock(world);
} }

View File

@ -355,8 +355,6 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL
private static string CreateYPCompilerScript(string compileScript) private static string CreateYPCompilerScript(string compileScript)
{ {
compileScript = String.Empty + compileScript = String.Empty +
"using OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.YieldProlog; " + "using OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.YieldProlog; " +
"using OpenSim.Region.ScriptEngine.Common; using System.Collections.Generic;\r\n" + "using OpenSim.Region.ScriptEngine.Common; using System.Collections.Generic;\r\n" +

View File

@ -412,8 +412,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
private static string CreateYPCompilerScript(string compileScript) private static string CreateYPCompilerScript(string compileScript)
{ {
compileScript = String.Empty + compileScript = String.Empty +
"using OpenSim.Region.ScriptEngine.Shared.YieldProlog; " + "using OpenSim.Region.ScriptEngine.Shared.YieldProlog; " +
"using OpenSim.Region.ScriptEngine.Shared; using System.Collections.Generic;\r\n" + "using OpenSim.Region.ScriptEngine.Shared; using System.Collections.Generic;\r\n" +