aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs')
-rw-r--r--OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs48
1 files changed, 0 insertions, 48 deletions
diff --git a/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs b/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs
index a4d03ba..dbb1a15 100644
--- a/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs
+++ b/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs
@@ -93,11 +93,6 @@ namespace OpenSim.Server.Handlers.Simulation
93 DoObjectPost(request, responsedata, regionID); 93 DoObjectPost(request, responsedata, regionID);
94 return responsedata; 94 return responsedata;
95 } 95 }
96 else if (method.Equals("PUT"))
97 {
98 DoObjectPut(request, responsedata, regionID);
99 return responsedata;
100 }
101 //else if (method.Equals("DELETE")) 96 //else if (method.Equals("DELETE"))
102 //{ 97 //{
103 // DoObjectDelete(request, responsedata, agentID, action, regionHandle); 98 // DoObjectDelete(request, responsedata, agentID, action, regionHandle);
@@ -219,48 +214,5 @@ namespace OpenSim.Server.Handlers.Simulation
219 { 214 {
220 return m_SimulationService.CreateObject(destination, newPosition, sog, false); 215 return m_SimulationService.CreateObject(destination, newPosition, sog, false);
221 } 216 }
222
223 protected virtual void DoObjectPut(Hashtable request, Hashtable responsedata, UUID regionID)
224 {
225 OSDMap args = Utils.GetOSDMap((string)request["body"]);
226 if (args == null)
227 {
228 responsedata["int_response_code"] = 400;
229 responsedata["str_response_string"] = "false";
230 return;
231 }
232
233 // retrieve the input arguments
234 int x = 0, y = 0;
235 UUID uuid = UUID.Zero;
236 string regionname = string.Empty;
237 if (args.ContainsKey("destination_x") && args["destination_x"] != null)
238 Int32.TryParse(args["destination_x"].AsString(), out x);
239 if (args.ContainsKey("destination_y") && args["destination_y"] != null)
240 Int32.TryParse(args["destination_y"].AsString(), out y);
241 if (args.ContainsKey("destination_uuid") && args["destination_uuid"] != null)
242 UUID.TryParse(args["destination_uuid"].AsString(), out uuid);
243 if (args.ContainsKey("destination_name") && args["destination_name"] != null)
244 regionname = args["destination_name"].ToString();
245
246 GridRegion destination = new GridRegion();
247 destination.RegionID = uuid;
248 destination.RegionLocX = x;
249 destination.RegionLocY = y;
250 destination.RegionName = regionname;
251
252 UUID userID = UUID.Zero, itemID = UUID.Zero;
253 if (args.ContainsKey("userid") && args["userid"] != null)
254 userID = args["userid"].AsUUID();
255 if (args.ContainsKey("itemid") && args["itemid"] != null)
256 itemID = args["itemid"].AsUUID();
257
258 // This is the meaning of PUT object
259 bool result = m_SimulationService.CreateObject(destination, userID, itemID);
260
261 responsedata["int_response_code"] = 200;
262 responsedata["str_response_string"] = result.ToString();
263 }
264
265 } 217 }
266} 218}