diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AgentAssetsTransactions.cs | 34 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetTransactionModule.cs | 24 |
2 files changed, 29 insertions, 29 deletions
diff --git a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AgentAssetsTransactions.cs b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AgentAssetsTransactions.cs index bc1d710..c46c4a4 100644 --- a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AgentAssetsTransactions.cs +++ b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AgentAssetsTransactions.cs | |||
@@ -28,8 +28,8 @@ | |||
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.IO; | 30 | using System.IO; |
31 | using libsecondlife; | 31 | using OpenMetaverse; |
32 | using libsecondlife.Packets; | 32 | using OpenMetaverse.Packets; |
33 | using OpenSim.Framework; | 33 | using OpenSim.Framework; |
34 | using OpenSim.Framework.Communications.Cache; | 34 | using OpenSim.Framework.Communications.Cache; |
35 | 35 | ||
@@ -46,18 +46,18 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
46 | // Fields | 46 | // Fields |
47 | private bool m_dumpAssetsToFile; | 47 | private bool m_dumpAssetsToFile; |
48 | public AgentAssetTransactionsManager Manager; | 48 | public AgentAssetTransactionsManager Manager; |
49 | public LLUUID UserID; | 49 | public UUID UserID; |
50 | public Dictionary<LLUUID, AssetXferUploader> XferUploaders = new Dictionary<LLUUID, AssetXferUploader>(); | 50 | public Dictionary<UUID, AssetXferUploader> XferUploaders = new Dictionary<UUID, AssetXferUploader>(); |
51 | 51 | ||
52 | // Methods | 52 | // Methods |
53 | public AgentAssetTransactions(LLUUID agentID, AgentAssetTransactionsManager manager, bool dumpAssetsToFile) | 53 | public AgentAssetTransactions(UUID agentID, AgentAssetTransactionsManager manager, bool dumpAssetsToFile) |
54 | { | 54 | { |
55 | UserID = agentID; | 55 | UserID = agentID; |
56 | Manager = manager; | 56 | Manager = manager; |
57 | m_dumpAssetsToFile = dumpAssetsToFile; | 57 | m_dumpAssetsToFile = dumpAssetsToFile; |
58 | } | 58 | } |
59 | 59 | ||
60 | public AssetXferUploader RequestXferUploader(LLUUID transactionID) | 60 | public AssetXferUploader RequestXferUploader(UUID transactionID) |
61 | { | 61 | { |
62 | if (!XferUploaders.ContainsKey(transactionID)) | 62 | if (!XferUploaders.ContainsKey(transactionID)) |
63 | { | 63 | { |
@@ -90,7 +90,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
90 | } | 90 | } |
91 | } | 91 | } |
92 | 92 | ||
93 | public void RequestCreateInventoryItem(IClientAPI remoteClient, LLUUID transactionID, LLUUID folderID, | 93 | public void RequestCreateInventoryItem(IClientAPI remoteClient, UUID transactionID, UUID folderID, |
94 | uint callbackID, string description, string name, sbyte invType, | 94 | uint callbackID, string description, string name, sbyte invType, |
95 | sbyte type, byte wearableType, uint nextOwnerMask) | 95 | sbyte type, byte wearableType, uint nextOwnerMask) |
96 | { | 96 | { |
@@ -102,7 +102,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
102 | } | 102 | } |
103 | } | 103 | } |
104 | 104 | ||
105 | public void RequestUpdateInventoryItem(IClientAPI remoteClient, LLUUID transactionID, | 105 | public void RequestUpdateInventoryItem(IClientAPI remoteClient, UUID transactionID, |
106 | InventoryItemBase item) | 106 | InventoryItemBase item) |
107 | { | 107 | { |
108 | if (XferUploaders.ContainsKey(transactionID)) | 108 | if (XferUploaders.ContainsKey(transactionID)) |
@@ -116,7 +116,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
116 | /// </summary> | 116 | /// </summary> |
117 | /// <param name="transactionID"></param> | 117 | /// <param name="transactionID"></param> |
118 | /// <returns>The asset if the upload has completed, null if it has not.</returns> | 118 | /// <returns>The asset if the upload has completed, null if it has not.</returns> |
119 | public AssetBase GetTransactionAsset(LLUUID transactionID) | 119 | public AssetBase GetTransactionAsset(UUID transactionID) |
120 | { | 120 | { |
121 | if (XferUploaders.ContainsKey(transactionID)) | 121 | if (XferUploaders.ContainsKey(transactionID)) |
122 | { | 122 | { |
@@ -143,7 +143,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
143 | // Fields | 143 | // Fields |
144 | public bool AddToInventory; | 144 | public bool AddToInventory; |
145 | public AssetBase Asset; | 145 | public AssetBase Asset; |
146 | public LLUUID InventFolder = LLUUID.Zero; | 146 | public UUID InventFolder = UUID.Zero; |
147 | private sbyte invType = 0; | 147 | private sbyte invType = 0; |
148 | private bool m_createItem = false; | 148 | private bool m_createItem = false; |
149 | private string m_description = String.Empty; | 149 | private string m_description = String.Empty; |
@@ -154,7 +154,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
154 | private AgentAssetTransactions m_userTransactions; | 154 | private AgentAssetTransactions m_userTransactions; |
155 | private uint nextPerm = 0; | 155 | private uint nextPerm = 0; |
156 | private IClientAPI ourClient; | 156 | private IClientAPI ourClient; |
157 | public LLUUID TransactionID = LLUUID.Zero; | 157 | public UUID TransactionID = UUID.Zero; |
158 | private sbyte type = 0; | 158 | private sbyte type = 0; |
159 | public bool UploadComplete; | 159 | public bool UploadComplete; |
160 | private byte wearableType = 0; | 160 | private byte wearableType = 0; |
@@ -210,7 +210,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
210 | /// <param name="packetID"></param> | 210 | /// <param name="packetID"></param> |
211 | /// <param name="data"></param> | 211 | /// <param name="data"></param> |
212 | /// <returns>True if the transfer is complete, false otherwise</returns> | 212 | /// <returns>True if the transfer is complete, false otherwise</returns> |
213 | public bool Initialise(IClientAPI remoteClient, LLUUID assetID, LLUUID transaction, sbyte type, byte[] data, | 213 | public bool Initialise(IClientAPI remoteClient, UUID assetID, UUID transaction, sbyte type, byte[] data, |
214 | bool storeLocal, bool tempFile) | 214 | bool storeLocal, bool tempFile) |
215 | { | 215 | { |
216 | ourClient = remoteClient; | 216 | ourClient = remoteClient; |
@@ -297,7 +297,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
297 | fs.Close(); | 297 | fs.Close(); |
298 | } | 298 | } |
299 | 299 | ||
300 | public void RequestCreateInventoryItem(IClientAPI remoteClient, LLUUID transactionID, LLUUID folderID, | 300 | public void RequestCreateInventoryItem(IClientAPI remoteClient, UUID transactionID, UUID folderID, |
301 | uint callbackID, string description, string name, sbyte invType, | 301 | uint callbackID, string description, string name, sbyte invType, |
302 | sbyte type, byte wearableType, uint nextOwnerMask) | 302 | sbyte type, byte wearableType, uint nextOwnerMask) |
303 | { | 303 | { |
@@ -321,7 +321,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
321 | } | 321 | } |
322 | } | 322 | } |
323 | 323 | ||
324 | public void RequestUpdateInventoryItem(IClientAPI remoteClient, LLUUID transactionID, | 324 | public void RequestUpdateInventoryItem(IClientAPI remoteClient, UUID transactionID, |
325 | InventoryItemBase item) | 325 | InventoryItemBase item) |
326 | { | 326 | { |
327 | if (TransactionID == transactionID) | 327 | if (TransactionID == transactionID) |
@@ -332,7 +332,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
332 | 332 | ||
333 | if (userInfo != null) | 333 | if (userInfo != null) |
334 | { | 334 | { |
335 | LLUUID assetID = LLUUID.Combine(transactionID, remoteClient.SecureSessionId); | 335 | UUID assetID = UUID.Combine(transactionID, remoteClient.SecureSessionId); |
336 | 336 | ||
337 | AssetBase asset | 337 | AssetBase asset |
338 | = m_userTransactions.Manager.MyScene.CommsManager.AssetCache.GetAsset( | 338 | = m_userTransactions.Manager.MyScene.CommsManager.AssetCache.GetAsset( |
@@ -346,7 +346,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
346 | if (asset != null && asset.FullID == assetID) | 346 | if (asset != null && asset.FullID == assetID) |
347 | { | 347 | { |
348 | // Assets never get updated, new ones get created | 348 | // Assets never get updated, new ones get created |
349 | asset.FullID = LLUUID.Random(); | 349 | asset.FullID = UUID.Random(); |
350 | asset.Name = item.Name; | 350 | asset.Name = item.Name; |
351 | asset.Description = item.Description; | 351 | asset.Description = item.Description; |
352 | asset.Type = (sbyte) item.AssetType; | 352 | asset.Type = (sbyte) item.AssetType; |
@@ -371,7 +371,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
371 | InventoryItemBase item = new InventoryItemBase(); | 371 | InventoryItemBase item = new InventoryItemBase(); |
372 | item.Owner = ourClient.AgentId; | 372 | item.Owner = ourClient.AgentId; |
373 | item.Creator = ourClient.AgentId; | 373 | item.Creator = ourClient.AgentId; |
374 | item.ID = LLUUID.Random(); | 374 | item.ID = UUID.Random(); |
375 | item.AssetID = Asset.FullID; | 375 | item.AssetID = Asset.FullID; |
376 | item.Description = m_description; | 376 | item.Description = m_description; |
377 | item.Name = m_name; | 377 | item.Name = m_name; |
diff --git a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetTransactionModule.cs b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetTransactionModule.cs index b1cbdcc..e6e27be 100644 --- a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetTransactionModule.cs +++ b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetTransactionModule.cs | |||
@@ -28,7 +28,7 @@ | |||
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Reflection; | 30 | using System.Reflection; |
31 | using libsecondlife; | 31 | using OpenMetaverse; |
32 | using log4net; | 32 | using log4net; |
33 | using Nini.Config; | 33 | using Nini.Config; |
34 | using OpenSim.Framework; | 34 | using OpenSim.Framework; |
@@ -40,7 +40,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
40 | { | 40 | { |
41 | public class AssetTransactionModule : IRegionModule, IAgentAssetTransactions | 41 | public class AssetTransactionModule : IRegionModule, IAgentAssetTransactions |
42 | { | 42 | { |
43 | private readonly Dictionary<LLUUID, Scene> RegisteredScenes = new Dictionary<LLUUID, Scene>(); | 43 | private readonly Dictionary<UUID, Scene> RegisteredScenes = new Dictionary<UUID, Scene>(); |
44 | private bool m_dumpAssetsToFile = false; | 44 | private bool m_dumpAssetsToFile = false; |
45 | private Scene m_scene = null; | 45 | private Scene m_scene = null; |
46 | 46 | ||
@@ -53,7 +53,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
53 | 53 | ||
54 | #region IAgentAssetTransactions Members | 54 | #region IAgentAssetTransactions Members |
55 | 55 | ||
56 | public void HandleItemCreationFromTransaction(IClientAPI remoteClient, LLUUID transactionID, LLUUID folderID, | 56 | public void HandleItemCreationFromTransaction(IClientAPI remoteClient, UUID transactionID, UUID folderID, |
57 | uint callbackID, string description, string name, sbyte invType, | 57 | uint callbackID, string description, string name, sbyte invType, |
58 | sbyte type, byte wearableType, uint nextOwnerMask) | 58 | sbyte type, byte wearableType, uint nextOwnerMask) |
59 | { | 59 | { |
@@ -61,13 +61,13 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
61 | wearableType, nextOwnerMask); | 61 | wearableType, nextOwnerMask); |
62 | } | 62 | } |
63 | 63 | ||
64 | public void HandleItemUpdateFromTransaction(IClientAPI remoteClient, LLUUID transactionID, | 64 | public void HandleItemUpdateFromTransaction(IClientAPI remoteClient, UUID transactionID, |
65 | InventoryItemBase item) | 65 | InventoryItemBase item) |
66 | { | 66 | { |
67 | m_transactionManager.HandleItemUpdateFromTransaction(remoteClient, transactionID, item); | 67 | m_transactionManager.HandleItemUpdateFromTransaction(remoteClient, transactionID, item); |
68 | } | 68 | } |
69 | 69 | ||
70 | public void RemoveAgentAssetTransactions(LLUUID userID) | 70 | public void RemoveAgentAssetTransactions(UUID userID) |
71 | { | 71 | { |
72 | m_transactionManager.RemoveAgentAssetTransactions(userID); | 72 | m_transactionManager.RemoveAgentAssetTransactions(userID); |
73 | } | 73 | } |
@@ -146,8 +146,8 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
146 | /// <summary> | 146 | /// <summary> |
147 | /// Each agent has its own singleton collection of transactions | 147 | /// Each agent has its own singleton collection of transactions |
148 | /// </summary> | 148 | /// </summary> |
149 | private Dictionary<LLUUID, AgentAssetTransactions> AgentTransactions = | 149 | private Dictionary<UUID, AgentAssetTransactions> AgentTransactions = |
150 | new Dictionary<LLUUID, AgentAssetTransactions>(); | 150 | new Dictionary<UUID, AgentAssetTransactions>(); |
151 | 151 | ||
152 | /// <summary> | 152 | /// <summary> |
153 | /// Should we dump uploaded assets to the filesystem? | 153 | /// Should we dump uploaded assets to the filesystem? |
@@ -168,7 +168,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
168 | /// </summary> | 168 | /// </summary> |
169 | /// <param name="userID"></param> | 169 | /// <param name="userID"></param> |
170 | /// <returns></returns> | 170 | /// <returns></returns> |
171 | private AgentAssetTransactions GetUserTransactions(LLUUID userID) | 171 | private AgentAssetTransactions GetUserTransactions(UUID userID) |
172 | { | 172 | { |
173 | lock (AgentTransactions) | 173 | lock (AgentTransactions) |
174 | { | 174 | { |
@@ -188,7 +188,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
188 | /// from a scene (and hence won't be making any more transactions here). | 188 | /// from a scene (and hence won't be making any more transactions here). |
189 | /// </summary> | 189 | /// </summary> |
190 | /// <param name="userID"></param> | 190 | /// <param name="userID"></param> |
191 | public void RemoveAgentAssetTransactions(LLUUID userID) | 191 | public void RemoveAgentAssetTransactions(UUID userID) |
192 | { | 192 | { |
193 | // m_log.DebugFormat("Removing agent asset transactions structure for agent {0}", userID); | 193 | // m_log.DebugFormat("Removing agent asset transactions structure for agent {0}", userID); |
194 | 194 | ||
@@ -214,7 +214,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
214 | /// <param name="type"></param> | 214 | /// <param name="type"></param> |
215 | /// <param name="wearableType"></param> | 215 | /// <param name="wearableType"></param> |
216 | /// <param name="nextOwnerMask"></param> | 216 | /// <param name="nextOwnerMask"></param> |
217 | public void HandleItemCreationFromTransaction(IClientAPI remoteClient, LLUUID transactionID, LLUUID folderID, | 217 | public void HandleItemCreationFromTransaction(IClientAPI remoteClient, UUID transactionID, UUID folderID, |
218 | uint callbackID, string description, string name, sbyte invType, | 218 | uint callbackID, string description, string name, sbyte invType, |
219 | sbyte type, byte wearableType, uint nextOwnerMask) | 219 | sbyte type, byte wearableType, uint nextOwnerMask) |
220 | { | 220 | { |
@@ -237,7 +237,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
237 | /// <param name="remoteClient"></param> | 237 | /// <param name="remoteClient"></param> |
238 | /// <param name="transactionID"></param> | 238 | /// <param name="transactionID"></param> |
239 | /// <param name="item"></param> | 239 | /// <param name="item"></param> |
240 | public void HandleItemUpdateFromTransaction(IClientAPI remoteClient, LLUUID transactionID, | 240 | public void HandleItemUpdateFromTransaction(IClientAPI remoteClient, UUID transactionID, |
241 | InventoryItemBase item) | 241 | InventoryItemBase item) |
242 | { | 242 | { |
243 | m_log.DebugFormat( | 243 | m_log.DebugFormat( |
@@ -259,7 +259,7 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction | |||
259 | /// <param name="type"></param> | 259 | /// <param name="type"></param> |
260 | /// <param name="data"></param></param> | 260 | /// <param name="data"></param></param> |
261 | /// <param name="tempFile"></param> | 261 | /// <param name="tempFile"></param> |
262 | public void HandleUDPUploadRequest(IClientAPI remoteClient, LLUUID assetID, LLUUID transaction, sbyte type, | 262 | public void HandleUDPUploadRequest(IClientAPI remoteClient, UUID assetID, UUID transaction, sbyte type, |
263 | byte[] data, bool storeLocal, bool tempFile) | 263 | byte[] data, bool storeLocal, bool tempFile) |
264 | { | 264 | { |
265 | if (((AssetType)type == AssetType.Texture || | 265 | if (((AssetType)type == AssetType.Texture || |