aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications/ISecureInventoryService.cs
diff options
context:
space:
mode:
authorJohan Berntsson2008-07-23 07:27:11 +0000
committerJohan Berntsson2008-07-23 07:27:11 +0000
commit3b35332957e0d122cdd063ad14d3795856bcd8e5 (patch)
tree8fbabfa0cdb049fd9151f6cd887c6897e8d89604 /OpenSim/Framework/Communications/ISecureInventoryService.cs
parentthanks lulurun for a security patch that blocks unathorized access to the inv... (diff)
downloadopensim-SC_OLD-3b35332957e0d122cdd063ad14d3795856bcd8e5.zip
opensim-SC_OLD-3b35332957e0d122cdd063ad14d3795856bcd8e5.tar.gz
opensim-SC_OLD-3b35332957e0d122cdd063ad14d3795856bcd8e5.tar.bz2
opensim-SC_OLD-3b35332957e0d122cdd063ad14d3795856bcd8e5.tar.xz
adding files that were not included in r5589
Diffstat (limited to 'OpenSim/Framework/Communications/ISecureInventoryService.cs')
-rw-r--r--OpenSim/Framework/Communications/ISecureInventoryService.cs125
1 files changed, 125 insertions, 0 deletions
diff --git a/OpenSim/Framework/Communications/ISecureInventoryService.cs b/OpenSim/Framework/Communications/ISecureInventoryService.cs
new file mode 100644
index 0000000..0e7861a
--- /dev/null
+++ b/OpenSim/Framework/Communications/ISecureInventoryService.cs
@@ -0,0 +1,125 @@
1/*
2 * Copyright (c) Contributors, http://opensimulator.org/
3 * See CONTRIBUTORS.TXT for a full list of copyright holders.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met:
7 * * Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer.
9 * * Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the
11 * documentation and/or other materials provided with the distribution.
12 * * Neither the name of the OpenSim Project nor the
13 * names of its contributors may be used to endorse or promote products
14 * derived from this software without specific prior written permission.
15 *
16 * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
17 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19 * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
20 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */
27
28using System.Collections.Generic;
29using libsecondlife;
30using OpenSim.Framework.Communications.Cache;
31
32namespace OpenSim.Framework.Communications
33{
34
35 /// <summary>
36 /// Defines all the operations one can perform on a user's inventory.
37 /// </summary>
38 public interface ISecureInventoryService
39 {
40 string Host
41 {
42 get;
43 }
44 /// <summary>
45 /// Request the inventory for a user. This is an asynchronous operation that will call the callback when the
46 /// inventory has been received
47 /// </summary>
48 /// <param name="userID"></param>
49 /// <param name="callback"></param>
50 void RequestInventoryForUser(LLUUID userID, LLUUID session_id, InventoryReceiptCallback callback);
51
52 /// <summary>
53 /// Add a new folder to the user's inventory
54 /// </summary>
55 /// <param name="folder"></param>
56 /// <returns>true if the folder was successfully added</returns>
57 bool AddFolder(InventoryFolderBase folder, LLUUID session_id);
58
59 /// <summary>
60 /// Update a folder in the user's inventory
61 /// </summary>
62 /// <param name="folder"></param>
63 /// <returns>true if the folder was successfully updated</returns>
64 bool UpdateFolder(InventoryFolderBase folder, LLUUID session_id);
65
66 /// <summary>
67 /// Move an inventory folder to a new location
68 /// </summary>
69 /// <param name="folder">A folder containing the details of the new location</param>
70 /// <returns>true if the folder was successfully moved</returns>
71 bool MoveFolder(InventoryFolderBase folder, LLUUID session_id);
72
73 /// <summary>
74 /// Purge an inventory folder of all its items and subfolders.
75 /// </summary>
76 /// <param name="folder"></param>
77 /// <returns>true if the folder was successfully purged</returns>
78 bool PurgeFolder(InventoryFolderBase folder, LLUUID session_id);
79
80 /// <summary>
81 /// Add a new item to the user's inventory
82 /// </summary>
83 /// <param name="item"></param>
84 /// <returns>true if the item was successfully added</returns>
85 bool AddItem(InventoryItemBase item, LLUUID session_id);
86
87 /// <summary>
88 /// Update an item in the user's inventory
89 /// </summary>
90 /// <param name="item"></param>
91 /// <returns>true if the item was successfully updated</returns>
92 bool UpdateItem(InventoryItemBase item, LLUUID session_id);
93
94 /// <summary>
95 /// Delete an item from the user's inventory
96 /// </summary>
97 /// <param name="item"></param>
98 /// <returns>true if the item was successfully deleted</returns>
99 bool DeleteItem(InventoryItemBase item, LLUUID session_id);
100
101 /// <summary>
102 /// Create a new inventory for the given user.
103 /// </summary>
104 /// <param name="user"></param>
105 /// <returns>true if the inventory was successfully created, false otherwise</returns>
106 bool CreateNewUserInventory(LLUUID user);
107
108 bool HasInventoryForUser(LLUUID userID);
109
110 /// <summary>
111 /// Retrieve the root inventory folder for the given user.
112 /// </summary>
113 /// <param name="userID"></param>
114 /// <returns>null if no root folder was found</returns>
115 InventoryFolderBase RequestRootFolder(LLUUID userID);
116
117 /// <summary>
118 /// Returns a list of all the folders in a given user's inventory.
119 /// </summary>
120 /// <param name="userId"></param>
121 /// <returns>A flat list of the user's inventory folder tree,
122 /// null if there is no inventory for this user</returns>
123 List<InventoryFolderBase> GetInventorySkeleton(LLUUID userId);
124 }
125}