diff options
author | Sean Dague | 2007-07-16 15:40:11 +0000 |
---|---|---|
committer | Sean Dague | 2007-07-16 15:40:11 +0000 |
commit | 2a3c79df83e800d5dfe75a1a3b140ed81da2b1d6 (patch) | |
tree | e3f80ad51736cf17e856547b1bcf956010927434 /OpenSim/Framework/Communications/caches/InventoryFolder.cs | |
parent | *Trunk compiles now (diff) | |
download | opensim-SC_OLD-2a3c79df83e800d5dfe75a1a3b140ed81da2b1d6.zip opensim-SC_OLD-2a3c79df83e800d5dfe75a1a3b140ed81da2b1d6.tar.gz opensim-SC_OLD-2a3c79df83e800d5dfe75a1a3b140ed81da2b1d6.tar.bz2 opensim-SC_OLD-2a3c79df83e800d5dfe75a1a3b140ed81da2b1d6.tar.xz |
changed to native line ending encoding
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/Communications/caches/InventoryFolder.cs | 102 |
1 files changed, 51 insertions, 51 deletions
diff --git a/OpenSim/Framework/Communications/caches/InventoryFolder.cs b/OpenSim/Framework/Communications/caches/InventoryFolder.cs index eaddf19..af38b12 100644 --- a/OpenSim/Framework/Communications/caches/InventoryFolder.cs +++ b/OpenSim/Framework/Communications/caches/InventoryFolder.cs | |||
@@ -1,51 +1,51 @@ | |||
1 | using System; | 1 | using System; |
2 | using System.Collections.Generic; | 2 | using System.Collections.Generic; |
3 | using System.Text; | 3 | using System.Text; |
4 | using libsecondlife; | 4 | using libsecondlife; |
5 | using OpenSim.Framework.Data; | 5 | using OpenSim.Framework.Data; |
6 | 6 | ||
7 | namespace OpenSim.Framework.Communications.Caches | 7 | namespace OpenSim.Framework.Communications.Caches |
8 | { | 8 | { |
9 | public class InventoryFolder : InventoryFolderBase | 9 | public class InventoryFolder : InventoryFolderBase |
10 | { | 10 | { |
11 | public Dictionary<LLUUID, InventoryFolder> SubFolders = new Dictionary<LLUUID, InventoryFolder>(); | 11 | public Dictionary<LLUUID, InventoryFolder> SubFolders = new Dictionary<LLUUID, InventoryFolder>(); |
12 | public Dictionary<LLUUID, InventoryItemBase> Items = new Dictionary<LLUUID, InventoryItemBase>(); | 12 | public Dictionary<LLUUID, InventoryItemBase> Items = new Dictionary<LLUUID, InventoryItemBase>(); |
13 | 13 | ||
14 | public InventoryFolder() | 14 | public InventoryFolder() |
15 | { | 15 | { |
16 | } | 16 | } |
17 | 17 | ||
18 | public InventoryFolder HasSubFolder(LLUUID folderID) | 18 | public InventoryFolder HasSubFolder(LLUUID folderID) |
19 | { | 19 | { |
20 | InventoryFolder returnFolder = null; | 20 | InventoryFolder returnFolder = null; |
21 | if (this.SubFolders.ContainsKey(folderID)) | 21 | if (this.SubFolders.ContainsKey(folderID)) |
22 | { | 22 | { |
23 | returnFolder = this.SubFolders[folderID]; | 23 | returnFolder = this.SubFolders[folderID]; |
24 | } | 24 | } |
25 | else | 25 | else |
26 | { | 26 | { |
27 | foreach (InventoryFolder folder in this.SubFolders.Values) | 27 | foreach (InventoryFolder folder in this.SubFolders.Values) |
28 | { | 28 | { |
29 | returnFolder = folder.HasSubFolder(folderID); | 29 | returnFolder = folder.HasSubFolder(folderID); |
30 | if (returnFolder != null) | 30 | if (returnFolder != null) |
31 | { | 31 | { |
32 | break; | 32 | break; |
33 | } | 33 | } |
34 | } | 34 | } |
35 | } | 35 | } |
36 | return returnFolder; | 36 | return returnFolder; |
37 | } | 37 | } |
38 | 38 | ||
39 | public InventoryFolder CreateNewSubFolder(LLUUID folderID, string folderName, ushort type) | 39 | public InventoryFolder CreateNewSubFolder(LLUUID folderID, string folderName, ushort type) |
40 | { | 40 | { |
41 | InventoryFolder subFold = new InventoryFolder(); | 41 | InventoryFolder subFold = new InventoryFolder(); |
42 | subFold.name = folderName; | 42 | subFold.name = folderName; |
43 | subFold.folderID = folderID; | 43 | subFold.folderID = folderID; |
44 | subFold.type = type; | 44 | subFold.type = type; |
45 | subFold.parentID = this.folderID; | 45 | subFold.parentID = this.folderID; |
46 | subFold.agentID = this.agentID; | 46 | subFold.agentID = this.agentID; |
47 | this.SubFolders.Add(subFold.folderID, subFold); | 47 | this.SubFolders.Add(subFold.folderID, subFold); |
48 | return subFold; | 48 | return subFold; |
49 | } | 49 | } |
50 | } | 50 | } |
51 | } | 51 | } |