diff options
Diffstat (limited to 'OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs')
-rw-r--r-- | OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs b/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs index 8d104ac..30b3cae 100644 --- a/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs +++ b/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs | |||
@@ -110,11 +110,11 @@ namespace OpenSim.Server.Handlers.Inventory | |||
110 | 110 | ||
111 | m_httpServer.AddStreamHandler( | 111 | m_httpServer.AddStreamHandler( |
112 | new RestDeserialiseSecureHandler<InventoryItemBase, InventoryItemBase>( | 112 | new RestDeserialiseSecureHandler<InventoryItemBase, InventoryItemBase>( |
113 | "POST", "/QueryItem/", m_InventoryService.QueryItem, CheckAuthSession)); | 113 | "POST", "/QueryItem/", m_InventoryService.GetItem, CheckAuthSession)); |
114 | 114 | ||
115 | m_httpServer.AddStreamHandler( | 115 | m_httpServer.AddStreamHandler( |
116 | new RestDeserialiseSecureHandler<InventoryFolderBase, InventoryFolderBase>( | 116 | new RestDeserialiseSecureHandler<InventoryFolderBase, InventoryFolderBase>( |
117 | "POST", "/QueryFolder/", m_InventoryService.QueryFolder, CheckAuthSession)); | 117 | "POST", "/QueryFolder/", m_InventoryService.GetFolder, CheckAuthSession)); |
118 | 118 | ||
119 | m_httpServer.AddStreamHandler( | 119 | m_httpServer.AddStreamHandler( |
120 | new RestDeserialiseTrustedHandler<Guid, bool>( | 120 | new RestDeserialiseTrustedHandler<Guid, bool>( |
@@ -153,6 +153,11 @@ namespace OpenSim.Server.Handlers.Inventory | |||
153 | m_httpServer.AddStreamHandler( | 153 | m_httpServer.AddStreamHandler( |
154 | new RestDeserialiseTrustedHandler<Guid, List<InventoryFolderBase>> | 154 | new RestDeserialiseTrustedHandler<Guid, List<InventoryFolderBase>> |
155 | ("POST", "/RootFolders/", GetInventorySkeleton, CheckTrustSource)); | 155 | ("POST", "/RootFolders/", GetInventorySkeleton, CheckTrustSource)); |
156 | |||
157 | m_httpServer.AddStreamHandler( | ||
158 | new RestDeserialiseTrustedHandler<InventoryItemBase, int> | ||
159 | ("POST", "/AssetPermissions/", GetAssetPermissions, CheckTrustSource)); | ||
160 | |||
156 | } | 161 | } |
157 | 162 | ||
158 | #region Wrappers for converting the Guid parameter | 163 | #region Wrappers for converting the Guid parameter |
@@ -185,6 +190,8 @@ namespace OpenSim.Server.Handlers.Inventory | |||
185 | if ((folder.Type != (short)AssetType.Folder) && (folder.Type != (short)AssetType.Unknown)) | 190 | if ((folder.Type != (short)AssetType.Folder) && (folder.Type != (short)AssetType.Unknown)) |
186 | folders[(AssetType)folder.Type] = folder; | 191 | folders[(AssetType)folder.Type] = folder; |
187 | } | 192 | } |
193 | // Put the root folder there, as type Folder | ||
194 | folders[AssetType.Folder] = root; | ||
188 | return folders; | 195 | return folders; |
189 | } | 196 | } |
190 | } | 197 | } |
@@ -235,6 +242,11 @@ namespace OpenSim.Server.Handlers.Inventory | |||
235 | return m_InventoryService.GetInventorySkeleton(userID); | 242 | return m_InventoryService.GetInventorySkeleton(userID); |
236 | } | 243 | } |
237 | 244 | ||
245 | public int GetAssetPermissions(InventoryItemBase item) | ||
246 | { | ||
247 | return m_InventoryService.GetAssetPermissions(item.Owner, item.AssetID); | ||
248 | } | ||
249 | |||
238 | #endregion | 250 | #endregion |
239 | 251 | ||
240 | /// <summary> | 252 | /// <summary> |