aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications/caches/InventoryFolder.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Communications/caches/InventoryFolder.cs')
-rw-r--r--OpenSim/Framework/Communications/caches/InventoryFolder.cs61
1 files changed, 0 insertions, 61 deletions
diff --git a/OpenSim/Framework/Communications/caches/InventoryFolder.cs b/OpenSim/Framework/Communications/caches/InventoryFolder.cs
deleted file mode 100644
index 8978cee..0000000
--- a/OpenSim/Framework/Communications/caches/InventoryFolder.cs
+++ /dev/null
@@ -1,61 +0,0 @@
1using System;
2using System.Collections.Generic;
3using System.Text;
4using libsecondlife;
5using OpenSim.Framework.Data;
6
7namespace OpenSim.Framework.Communications.Caches
8{
9 public class InventoryFolder : InventoryFolderBase
10 {
11 public Dictionary<LLUUID, InventoryFolder> SubFolders = new Dictionary<LLUUID, InventoryFolder>();
12 public Dictionary<LLUUID, InventoryItemBase> Items = new Dictionary<LLUUID, InventoryItemBase>();
13
14 public InventoryFolder()
15 {
16 }
17
18 public InventoryFolder HasSubFolder(LLUUID folderID)
19 {
20 InventoryFolder returnFolder = null;
21 if (this.SubFolders.ContainsKey(folderID))
22 {
23 returnFolder = this.SubFolders[folderID];
24 }
25 else
26 {
27 foreach (InventoryFolder folder in this.SubFolders.Values)
28 {
29 returnFolder = folder.HasSubFolder(folderID);
30 if (returnFolder != null)
31 {
32 break;
33 }
34 }
35 }
36 return returnFolder;
37 }
38
39 public InventoryFolder CreateNewSubFolder(LLUUID folderID, string folderName, ushort type )
40 {
41 InventoryFolder subFold = new InventoryFolder();
42 subFold.name = folderName;
43 subFold.folderID = folderID;
44 subFold.type = type;
45 subFold.parentID = this.folderID;
46 subFold.agentID = this.agentID;
47 this.SubFolders.Add(subFold.folderID, subFold);
48 return subFold;
49 }
50
51 public List<InventoryItemBase> RequestListOfItems()
52 {
53 List<InventoryItemBase> itemList = new List<InventoryItemBase>();
54 foreach (InventoryItemBase item in this.Items.Values)
55 {
56 itemList.Add(item);
57 }
58 return itemList;
59 }
60 }
61}