aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-07-08 22:28:17 +0100
committerJustin Clark-Casey (justincc)2011-07-08 22:28:17 +0100
commit5700c582ba3727678dfd87f80dab8d09da88df63 (patch)
treeda69097f1d0b11ffc9bb4db0f4ac5b5a567259b0 /OpenSim/Region
parentrefactor: eliminate redundant return statement (diff)
downloadopensim-SC_OLD-5700c582ba3727678dfd87f80dab8d09da88df63.zip
opensim-SC_OLD-5700c582ba3727678dfd87f80dab8d09da88df63.tar.gz
opensim-SC_OLD-5700c582ba3727678dfd87f80dab8d09da88df63.tar.bz2
opensim-SC_OLD-5700c582ba3727678dfd87f80dab8d09da88df63.tar.xz
refactor: rename bool returning GetAgentInventoryItem() to CanGetAgentInventoryItem() to improve code readability
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs7
-rw-r--r--OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs2
-rw-r--r--OpenSim/Region/Framework/Interfaces/IInventoryAccessModule.cs10
3 files changed, 13 insertions, 6 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index f53e236..c176c2b 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -7548,13 +7548,13 @@ namespace OpenSim.Region.ClientStack.LindenUDP
7548 IInventoryAccessModule invAccess = m_scene.RequestModuleInterface<IInventoryAccessModule>(); 7548 IInventoryAccessModule invAccess = m_scene.RequestModuleInterface<IInventoryAccessModule>();
7549 if (invAccess != null) 7549 if (invAccess != null)
7550 { 7550 {
7551 if (!invAccess.GetAgentInventoryItem(this, itemID, requestID)) 7551 if (!invAccess.CanGetAgentInventoryItem(this, itemID, requestID))
7552 return false; 7552 return false;
7553
7554 } 7553 }
7555 else 7554 else
7555 {
7556 return false; 7556 return false;
7557 7557 }
7558 } 7558 }
7559 } 7559 }
7560 } 7560 }
@@ -7568,7 +7568,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
7568 { 7568 {
7569 AssetUploadRequestPacket request = (AssetUploadRequestPacket)Pack; 7569 AssetUploadRequestPacket request = (AssetUploadRequestPacket)Pack;
7570 7570
7571
7572 // m_log.Debug("upload request " + request.ToString()); 7571 // m_log.Debug("upload request " + request.ToString());
7573 // m_log.Debug("upload request was for assetid: " + request.AssetBlock.TransactionID.Combine(this.SecureSessionId).ToString()); 7572 // m_log.Debug("upload request was for assetid: " + request.AssetBlock.TransactionID.Combine(this.SecureSessionId).ToString());
7574 UUID temp = UUID.Combine(request.AssetBlock.TransactionID, SecureSessionId); 7573 UUID temp = UUID.Combine(request.AssetBlock.TransactionID, SecureSessionId);
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
index 2930303..f7d187d 100644
--- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
@@ -978,7 +978,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
978 { 978 {
979 } 979 }
980 980
981 public virtual bool GetAgentInventoryItem(IClientAPI remoteClient, UUID itemID, UUID requestID) 981 public virtual bool CanGetAgentInventoryItem(IClientAPI remoteClient, UUID itemID, UUID requestID)
982 { 982 {
983 InventoryItemBase assetRequestItem = GetItem(remoteClient.AgentId, itemID); 983 InventoryItemBase assetRequestItem = GetItem(remoteClient.AgentId, itemID);
984 if (assetRequestItem == null) 984 if (assetRequestItem == null)
diff --git a/OpenSim/Region/Framework/Interfaces/IInventoryAccessModule.cs b/OpenSim/Region/Framework/Interfaces/IInventoryAccessModule.cs
index 305975e..da11e61 100644
--- a/OpenSim/Region/Framework/Interfaces/IInventoryAccessModule.cs
+++ b/OpenSim/Region/Framework/Interfaces/IInventoryAccessModule.cs
@@ -59,7 +59,15 @@ namespace OpenSim.Region.Framework.Interfaces
59 UUID RayTargetID, byte BypassRayCast, bool RayEndIsIntersection, 59 UUID RayTargetID, byte BypassRayCast, bool RayEndIsIntersection,
60 bool RezSelected, bool RemoveItem, UUID fromTaskID, bool attachment); 60 bool RezSelected, bool RemoveItem, UUID fromTaskID, bool attachment);
61 void TransferInventoryAssets(InventoryItemBase item, UUID sender, UUID receiver); 61 void TransferInventoryAssets(InventoryItemBase item, UUID sender, UUID receiver);
62 bool GetAgentInventoryItem(IClientAPI remoteClient, UUID itemID, UUID requestID); 62
63 /// <summary>
64 /// Does the client have sufficient permissions to retrieve the inventory item?
65 /// </summary>
66 /// <param name="remoteClient"></param>
67 /// <param name="itemID"></param>
68 /// <param name="requestID"></param>
69 /// <returns></returns>
70 bool CanGetAgentInventoryItem(IClientAPI remoteClient, UUID itemID, UUID requestID);
63 71
64 // Must be here because of textures in user's inventory 72 // Must be here because of textures in user's inventory
65 bool IsForeignUser(UUID userID, out string assetServerURL); 73 bool IsForeignUser(UUID userID, out string assetServerURL);