aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications
diff options
context:
space:
mode:
authorSean Dague2008-04-07 23:27:05 +0000
committerSean Dague2008-04-07 23:27:05 +0000
commit5ee75998ce4d941efd937848d28f3a4dac6ba6cc (patch)
treef29a100cb8ab3715c82f0aec4fee9f968f210405 /OpenSim/Framework/Communications
parentRefactor InventoryItemBase to do the following: (diff)
downloadopensim-SC_OLD-5ee75998ce4d941efd937848d28f3a4dac6ba6cc.zip
opensim-SC_OLD-5ee75998ce4d941efd937848d28f3a4dac6ba6cc.tar.gz
opensim-SC_OLD-5ee75998ce4d941efd937848d28f3a4dac6ba6cc.tar.bz2
opensim-SC_OLD-5ee75998ce4d941efd937848d28f3a4dac6ba6cc.tar.xz
more refactoring, this time on InventoryFolderBase
* wrap attributes in properties * clean up names a little bit * clean up name styles
Diffstat (limited to 'OpenSim/Framework/Communications')
-rw-r--r--OpenSim/Framework/Communications/Cache/CachedUserInfo.cs26
-rw-r--r--OpenSim/Framework/Communications/Cache/InventoryFolderImpl.cs24
-rw-r--r--OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs40
-rw-r--r--OpenSim/Framework/Communications/Cache/UserProfileCacheService.cs46
-rw-r--r--OpenSim/Framework/Communications/CommunicationsManager.cs2
-rw-r--r--OpenSim/Framework/Communications/InventoryServiceBase.cs216
-rw-r--r--OpenSim/Framework/Communications/LoginService.cs10
7 files changed, 182 insertions, 182 deletions
diff --git a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
index cb1eb5a..e39333b 100644
--- a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
+++ b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
@@ -60,7 +60,7 @@ namespace OpenSim.Framework.Communications.Cache
60 /// <param name="folder"></param> 60 /// <param name="folder"></param>
61 private void AddPendingFolder(InventoryFolderImpl folder) 61 private void AddPendingFolder(InventoryFolderImpl folder)
62 { 62 {
63 LLUUID parentFolderId = folder.parentID; 63 LLUUID parentFolderId = folder.ParentID;
64 64
65 if (pendingCategorizationFolders.ContainsKey(parentFolderId)) 65 if (pendingCategorizationFolders.ContainsKey(parentFolderId))
66 { 66 {
@@ -83,17 +83,17 @@ namespace OpenSim.Framework.Communications.Cache
83 /// </param> 83 /// </param>
84 private void ResolvePendingFolders(InventoryFolderImpl parent) 84 private void ResolvePendingFolders(InventoryFolderImpl parent)
85 { 85 {
86 if (pendingCategorizationFolders.ContainsKey(parent.folderID)) 86 if (pendingCategorizationFolders.ContainsKey(parent.ID))
87 { 87 {
88 foreach (InventoryFolderImpl folder in pendingCategorizationFolders[parent.folderID]) 88 foreach (InventoryFolderImpl folder in pendingCategorizationFolders[parent.ID])
89 { 89 {
90// m_log.DebugFormat( 90// m_log.DebugFormat(
91// "[INVENTORY CACHE]: Resolving pending received folder {0} {1} into {2} {3}", 91// "[INVENTORY CACHE]: Resolving pending received folder {0} {1} into {2} {3}",
92// folder.name, folder.folderID, parent.name, parent.folderID); 92// folder.name, folder.folderID, parent.name, parent.folderID);
93 93
94 if (!parent.SubFolders.ContainsKey(folder.folderID)) 94 if (!parent.SubFolders.ContainsKey(folder.ID))
95 { 95 {
96 parent.SubFolders.Add(folder.folderID, folder); 96 parent.SubFolders.Add(folder.ID, folder);
97 } 97 }
98 } 98 }
99 } 99 }
@@ -118,16 +118,16 @@ namespace OpenSim.Framework.Communications.Cache
118 { 118 {
119 if (RootFolder == null) 119 if (RootFolder == null)
120 { 120 {
121 if (folderInfo.parentID == LLUUID.Zero) 121 if (folderInfo.ParentID == LLUUID.Zero)
122 { 122 {
123 RootFolder = folderInfo; 123 RootFolder = folderInfo;
124 } 124 }
125 } 125 }
126 else if (RootFolder.folderID == folderInfo.parentID) 126 else if (RootFolder.ID == folderInfo.ParentID)
127 { 127 {
128 if (!RootFolder.SubFolders.ContainsKey(folderInfo.folderID)) 128 if (!RootFolder.SubFolders.ContainsKey(folderInfo.ID))
129 { 129 {
130 RootFolder.SubFolders.Add(folderInfo.folderID, folderInfo); 130 RootFolder.SubFolders.Add(folderInfo.ID, folderInfo);
131 } 131 }
132 else 132 else
133 { 133 {
@@ -136,12 +136,12 @@ namespace OpenSim.Framework.Communications.Cache
136 } 136 }
137 else 137 else
138 { 138 {
139 InventoryFolderImpl folder = RootFolder.HasSubFolder(folderInfo.parentID); 139 InventoryFolderImpl folder = RootFolder.HasSubFolder(folderInfo.ParentID);
140 if (folder != null) 140 if (folder != null)
141 { 141 {
142 if (!folder.SubFolders.ContainsKey(folderInfo.folderID)) 142 if (!folder.SubFolders.ContainsKey(folderInfo.ID))
143 { 143 {
144 folder.SubFolders.Add(folderInfo.folderID, folderInfo); 144 folder.SubFolders.Add(folderInfo.ID, folderInfo);
145 } 145 }
146 } 146 }
147 else 147 else
@@ -171,7 +171,7 @@ namespace OpenSim.Framework.Communications.Cache
171 { 171 {
172 if ((userID == UserProfile.UUID) && (RootFolder != null)) 172 if ((userID == UserProfile.UUID) && (RootFolder != null))
173 { 173 {
174 if (itemInfo.Folder == RootFolder.folderID) 174 if (itemInfo.Folder == RootFolder.ID)
175 { 175 {
176 if (!RootFolder.Items.ContainsKey(itemInfo.ID)) 176 if (!RootFolder.Items.ContainsKey(itemInfo.ID))
177 { 177 {
diff --git a/OpenSim/Framework/Communications/Cache/InventoryFolderImpl.cs b/OpenSim/Framework/Communications/Cache/InventoryFolderImpl.cs
index 20edf51..37907a0 100644
--- a/OpenSim/Framework/Communications/Cache/InventoryFolderImpl.cs
+++ b/OpenSim/Framework/Communications/Cache/InventoryFolderImpl.cs
@@ -45,12 +45,12 @@ namespace OpenSim.Framework.Communications.Cache
45 // Constructors 45 // Constructors
46 public InventoryFolderImpl(InventoryFolderBase folderbase) 46 public InventoryFolderImpl(InventoryFolderBase folderbase)
47 { 47 {
48 agentID = folderbase.agentID; 48 AgentID = folderbase.AgentID;
49 folderID = folderbase.folderID; 49 ID = folderbase.ID;
50 name = folderbase.name; 50 Name = folderbase.Name;
51 parentID = folderbase.parentID; 51 ParentID = folderbase.ParentID;
52 type = folderbase.type; 52 Type = folderbase.Type;
53 version = folderbase.version; 53 Version = folderbase.Version;
54 } 54 }
55 55
56 public InventoryFolderImpl() 56 public InventoryFolderImpl()
@@ -63,12 +63,12 @@ namespace OpenSim.Framework.Communications.Cache
63 if (!SubFolders.ContainsKey(folderID)) 63 if (!SubFolders.ContainsKey(folderID))
64 { 64 {
65 InventoryFolderImpl subFold = new InventoryFolderImpl(); 65 InventoryFolderImpl subFold = new InventoryFolderImpl();
66 subFold.name = folderName; 66 subFold.Name = folderName;
67 subFold.folderID = folderID; 67 subFold.ID = folderID;
68 subFold.type = (short) type; 68 subFold.Type = (short) type;
69 subFold.parentID = this.folderID; 69 subFold.ParentID = this.ID;
70 subFold.agentID = agentID; 70 subFold.AgentID = AgentID;
71 SubFolders.Add(subFold.folderID, subFold); 71 SubFolders.Add(subFold.ID, subFold);
72 return subFold; 72 return subFold;
73 } 73 }
74 return null; 74 return null;
diff --git a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
index 12a07eb..cb82850 100644
--- a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
+++ b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
@@ -56,14 +56,14 @@ namespace OpenSim.Framework.Communications.Cache
56 { 56 {
57 m_log.Info("[LIBRARY INVENTORY]: Loading library inventory"); 57 m_log.Info("[LIBRARY INVENTORY]: Loading library inventory");
58 58
59 agentID = libOwner; 59 AgentID = libOwner;
60 folderID = new LLUUID("00000112-000f-0000-0000-000100bba000"); 60 ID = new LLUUID("00000112-000f-0000-0000-000100bba000");
61 name = "OpenSim Library"; 61 Name = "OpenSim Library";
62 parentID = LLUUID.Zero; 62 ParentID = LLUUID.Zero;
63 type = (short) 8; 63 Type = (short) 8;
64 version = (ushort) 1; 64 Version = (ushort) 1;
65 65
66 libraryFolders.Add(folderID, this); 66 libraryFolders.Add(ID, this);
67 67
68 LoadLibraries(Path.Combine(Util.inventoryDir(), "Libraries.xml")); 68 LoadLibraries(Path.Combine(Util.inventoryDir(), "Libraries.xml"));
69 69
@@ -172,20 +172,20 @@ namespace OpenSim.Framework.Communications.Cache
172 { 172 {
173 InventoryFolderImpl folderInfo = new InventoryFolderImpl(); 173 InventoryFolderImpl folderInfo = new InventoryFolderImpl();
174 174
175 folderInfo.folderID = new LLUUID(config.GetString("folderID", folderID.ToString())); 175 folderInfo.ID = new LLUUID(config.GetString("folderID", ID.ToString()));
176 folderInfo.name = config.GetString("name", "unknown"); 176 folderInfo.Name = config.GetString("name", "unknown");
177 folderInfo.parentID = new LLUUID(config.GetString("parentFolderID", folderID.ToString())); 177 folderInfo.ParentID = new LLUUID(config.GetString("parentFolderID", ID.ToString()));
178 folderInfo.type = (short)config.GetInt("type", 8); 178 folderInfo.Type = (short)config.GetInt("type", 8);
179 179
180 folderInfo.agentID = libOwner; 180 folderInfo.AgentID = libOwner;
181 folderInfo.version = 1; 181 folderInfo.Version = 1;
182 182
183 if (libraryFolders.ContainsKey(folderInfo.parentID)) 183 if (libraryFolders.ContainsKey(folderInfo.ParentID))
184 { 184 {
185 InventoryFolderImpl parentFolder = libraryFolders[folderInfo.parentID]; 185 InventoryFolderImpl parentFolder = libraryFolders[folderInfo.ParentID];
186 186
187 libraryFolders.Add(folderInfo.folderID, folderInfo); 187 libraryFolders.Add(folderInfo.ID, folderInfo);
188 parentFolder.SubFolders.Add(folderInfo.folderID, folderInfo); 188 parentFolder.SubFolders.Add(folderInfo.ID, folderInfo);
189 189
190// m_log.InfoFormat("[LIBRARY INVENTORY]: Adding folder {0} ({1})", folderInfo.name, folderInfo.folderID); 190// m_log.InfoFormat("[LIBRARY INVENTORY]: Adding folder {0} ({1})", folderInfo.name, folderInfo.folderID);
191 } 191 }
@@ -193,7 +193,7 @@ namespace OpenSim.Framework.Communications.Cache
193 { 193 {
194 m_log.WarnFormat( 194 m_log.WarnFormat(
195 "[LIBRARY INVENTORY]: Couldn't add folder {0} ({1}) since parent folder with ID {2} does not exist!", 195 "[LIBRARY INVENTORY]: Couldn't add folder {0} ({1}) since parent folder with ID {2} does not exist!",
196 folderInfo.name, folderInfo.folderID, folderInfo.parentID); 196 folderInfo.Name, folderInfo.ID, folderInfo.ParentID);
197 } 197 }
198 } 198 }
199 199
@@ -206,9 +206,9 @@ namespace OpenSim.Framework.Communications.Cache
206 InventoryItemBase item = new InventoryItemBase(); 206 InventoryItemBase item = new InventoryItemBase();
207 item.Owner = libOwner; 207 item.Owner = libOwner;
208 item.Creator = libOwner; 208 item.Creator = libOwner;
209 item.ID = new LLUUID(config.GetString("inventoryID", folderID.ToString())); 209 item.ID = new LLUUID(config.GetString("inventoryID", ID.ToString()));
210 item.AssetID = new LLUUID(config.GetString("assetID", LLUUID.Random().ToString())); 210 item.AssetID = new LLUUID(config.GetString("assetID", LLUUID.Random().ToString()));
211 item.Folder = new LLUUID(config.GetString("folderID", folderID.ToString())); 211 item.Folder = new LLUUID(config.GetString("folderID", ID.ToString()));
212 item.Description = config.GetString("description", System.String.Empty); 212 item.Description = config.GetString("description", System.String.Empty);
213 item.Name = config.GetString("name", System.String.Empty); 213 item.Name = config.GetString("name", System.String.Empty);
214 item.AssetType = config.GetInt("assetType", 0); 214 item.AssetType = config.GetInt("assetType", 0);
diff --git a/OpenSim/Framework/Communications/Cache/UserProfileCacheService.cs b/OpenSim/Framework/Communications/Cache/UserProfileCacheService.cs
index c3f51da..6f11d60 100644
--- a/OpenSim/Framework/Communications/Cache/UserProfileCacheService.cs
+++ b/OpenSim/Framework/Communications/Cache/UserProfileCacheService.cs
@@ -105,7 +105,7 @@ namespace OpenSim.Framework.Communications.Cache
105 { 105 {
106 if (userProfile.RootFolder != null) 106 if (userProfile.RootFolder != null)
107 { 107 {
108 if (userProfile.RootFolder.folderID == parentID) 108 if (userProfile.RootFolder.ID == parentID)
109 { 109 {
110 InventoryFolderImpl createdFolder = 110 InventoryFolderImpl createdFolder =
111 userProfile.RootFolder.CreateNewSubFolder(folderID, folderName, folderType); 111 userProfile.RootFolder.CreateNewSubFolder(folderID, folderName, folderType);
@@ -113,12 +113,12 @@ namespace OpenSim.Framework.Communications.Cache
113 if (createdFolder != null) 113 if (createdFolder != null)
114 { 114 {
115 InventoryFolderBase createdBaseFolder = new InventoryFolderBase(); 115 InventoryFolderBase createdBaseFolder = new InventoryFolderBase();
116 createdBaseFolder.agentID = createdFolder.agentID; 116 createdBaseFolder.AgentID = createdFolder.AgentID;
117 createdBaseFolder.folderID = createdFolder.folderID; 117 createdBaseFolder.ID = createdFolder.ID;
118 createdBaseFolder.name = createdFolder.name; 118 createdBaseFolder.Name = createdFolder.Name;
119 createdBaseFolder.parentID = createdFolder.parentID; 119 createdBaseFolder.ParentID = createdFolder.ParentID;
120 createdBaseFolder.type = createdFolder.type; 120 createdBaseFolder.Type = createdFolder.Type;
121 createdBaseFolder.version = createdFolder.version; 121 createdBaseFolder.Version = createdFolder.Version;
122 m_parent.InventoryService.AddNewInventoryFolder(remoteClient.AgentId, createdBaseFolder); 122 m_parent.InventoryService.AddNewInventoryFolder(remoteClient.AgentId, createdBaseFolder);
123 } 123 }
124 } 124 }
@@ -156,12 +156,12 @@ namespace OpenSim.Framework.Communications.Cache
156 if (userProfile.RootFolder != null) 156 if (userProfile.RootFolder != null)
157 { 157 {
158 InventoryFolderBase baseFolder = new InventoryFolderBase(); 158 InventoryFolderBase baseFolder = new InventoryFolderBase();
159 baseFolder.agentID = remoteClient.AgentId; 159 baseFolder.AgentID = remoteClient.AgentId;
160 baseFolder.folderID = folderID; 160 baseFolder.ID = folderID;
161 baseFolder.name = name; 161 baseFolder.Name = name;
162 baseFolder.parentID = parentID; 162 baseFolder.ParentID = parentID;
163 baseFolder.type = (short) type; 163 baseFolder.Type = (short) type;
164 baseFolder.version = userProfile.RootFolder.version; 164 baseFolder.Version = userProfile.RootFolder.Version;
165 m_parent.InventoryService.AddNewInventoryFolder(remoteClient.AgentId, baseFolder); 165 m_parent.InventoryService.AddNewInventoryFolder(remoteClient.AgentId, baseFolder);
166 } 166 }
167 } 167 }
@@ -176,9 +176,9 @@ namespace OpenSim.Framework.Communications.Cache
176 if (userProfile.RootFolder != null) 176 if (userProfile.RootFolder != null)
177 { 177 {
178 InventoryFolderBase baseFolder = new InventoryFolderBase(); 178 InventoryFolderBase baseFolder = new InventoryFolderBase();
179 baseFolder.agentID = remoteClient.AgentId; 179 baseFolder.AgentID = remoteClient.AgentId;
180 baseFolder.folderID = folderID; 180 baseFolder.ID = folderID;
181 baseFolder.parentID = parentID; 181 baseFolder.ParentID = parentID;
182 m_parent.InventoryService.MoveInventoryFolder(remoteClient.AgentId, baseFolder); 182 m_parent.InventoryService.MoveInventoryFolder(remoteClient.AgentId, baseFolder);
183 } 183 }
184 } 184 }
@@ -199,10 +199,10 @@ namespace OpenSim.Framework.Communications.Cache
199 // XXX We're not handling sortOrder yet! 199 // XXX We're not handling sortOrder yet!
200 200
201 InventoryFolderImpl fold = null; 201 InventoryFolderImpl fold = null;
202 if (folderID == libraryRoot.folderID) 202 if (folderID == libraryRoot.ID)
203 { 203 {
204 remoteClient.SendInventoryFolderDetails( 204 remoteClient.SendInventoryFolderDetails(
205 libraryRoot.agentID, libraryRoot.folderID, libraryRoot.RequestListOfItems(), 205 libraryRoot.AgentID, libraryRoot.ID, libraryRoot.RequestListOfItems(),
206 libraryRoot.RequestListOfFolders(), fetchFolders, fetchItems); 206 libraryRoot.RequestListOfFolders(), fetchFolders, fetchItems);
207 207
208 return; 208 return;
@@ -211,7 +211,7 @@ namespace OpenSim.Framework.Communications.Cache
211 if ((fold = libraryRoot.HasSubFolder(folderID)) != null) 211 if ((fold = libraryRoot.HasSubFolder(folderID)) != null)
212 { 212 {
213 remoteClient.SendInventoryFolderDetails( 213 remoteClient.SendInventoryFolderDetails(
214 libraryRoot.agentID, folderID, fold.RequestListOfItems(), 214 libraryRoot.AgentID, folderID, fold.RequestListOfItems(),
215 fold.RequestListOfFolders(), fetchFolders, fetchItems); 215 fold.RequestListOfFolders(), fetchFolders, fetchItems);
216 216
217 return; 217 return;
@@ -242,7 +242,7 @@ namespace OpenSim.Framework.Communications.Cache
242 242
243 if (userProfile.RootFolder != null) 243 if (userProfile.RootFolder != null)
244 { 244 {
245 if (userProfile.RootFolder.folderID == folderID) 245 if (userProfile.RootFolder.ID == folderID)
246 { 246 {
247// m_log.DebugFormat( 247// m_log.DebugFormat(
248// "[AGENT INVENTORY]: Found root folder {0} for client {1}", 248// "[AGENT INVENTORY]: Found root folder {0} for client {1}",
@@ -301,7 +301,7 @@ namespace OpenSim.Framework.Communications.Cache
301 // if (fetchItems) 301 // if (fetchItems)
302 // { 302 // {
303 InventoryFolderImpl fold = null; 303 InventoryFolderImpl fold = null;
304 if (folderID == libraryRoot.folderID) 304 if (folderID == libraryRoot.ID)
305 { 305 {
306 return libraryRoot.RequestListOfItems(); 306 return libraryRoot.RequestListOfItems();
307 } 307 }
@@ -316,7 +316,7 @@ namespace OpenSim.Framework.Communications.Cache
316 { 316 {
317 if (userProfile.RootFolder != null) 317 if (userProfile.RootFolder != null)
318 { 318 {
319 if (userProfile.RootFolder.folderID == folderID) 319 if (userProfile.RootFolder.ID == folderID)
320 { 320 {
321 return userProfile.RootFolder.RequestListOfItems(); 321 return userProfile.RootFolder.RequestListOfItems();
322 } 322 }
@@ -377,7 +377,7 @@ namespace OpenSim.Framework.Communications.Cache
377 377
378 public void HandleFetchInventory(IClientAPI remoteClient, LLUUID itemID, LLUUID ownerID) 378 public void HandleFetchInventory(IClientAPI remoteClient, LLUUID itemID, LLUUID ownerID)
379 { 379 {
380 if (ownerID == libraryRoot.agentID) 380 if (ownerID == libraryRoot.AgentID)
381 { 381 {
382 //Console.WriteLine("request info for library item"); 382 //Console.WriteLine("request info for library item");
383 383
diff --git a/OpenSim/Framework/Communications/CommunicationsManager.cs b/OpenSim/Framework/Communications/CommunicationsManager.cs
index d96709d..6b5ef1b 100644
--- a/OpenSim/Framework/Communications/CommunicationsManager.cs
+++ b/OpenSim/Framework/Communications/CommunicationsManager.cs
@@ -240,7 +240,7 @@ namespace OpenSim.Framework.Communications
240 240
241 public void HandleUUIDNameRequest(LLUUID uuid, IClientAPI remote_client) 241 public void HandleUUIDNameRequest(LLUUID uuid, IClientAPI remote_client)
242 { 242 {
243 if (uuid == m_userProfileCacheService.libraryRoot.agentID) 243 if (uuid == m_userProfileCacheService.libraryRoot.AgentID)
244 { 244 {
245 remote_client.SendNameReply(uuid, "Mr", "OpenSim"); 245 remote_client.SendNameReply(uuid, "Mr", "OpenSim");
246 } 246 }
diff --git a/OpenSim/Framework/Communications/InventoryServiceBase.cs b/OpenSim/Framework/Communications/InventoryServiceBase.cs
index f41bd27..4abfc5a 100644
--- a/OpenSim/Framework/Communications/InventoryServiceBase.cs
+++ b/OpenSim/Framework/Communications/InventoryServiceBase.cs
@@ -95,7 +95,7 @@ namespace OpenSim.Framework.Communications
95 95
96 foreach (KeyValuePair<string, IInventoryData> plugin in m_plugins) 96 foreach (KeyValuePair<string, IInventoryData> plugin in m_plugins)
97 { 97 {
98 IList<InventoryFolderBase> folders = plugin.Value.getFolderHierarchy(rootFolder.folderID); 98 IList<InventoryFolderBase> folders = plugin.Value.getFolderHierarchy(rootFolder.ID);
99 userFolders.AddRange(folders); 99 userFolders.AddRange(folders);
100 } 100 }
101 101
@@ -190,7 +190,7 @@ namespace OpenSim.Framework.Communications
190 protected void AddFolder(InventoryFolderBase folder) 190 protected void AddFolder(InventoryFolderBase folder)
191 { 191 {
192 m_log.DebugFormat( 192 m_log.DebugFormat(
193 "[INVENTORY SERVICE BASE]: Adding folder {0}, {1} to {2}", folder.name, folder.folderID, folder.parentID); 193 "[INVENTORY SERVICE BASE]: Adding folder {0}, {1} to {2}", folder.Name, folder.ID, folder.ParentID);
194 194
195 foreach (KeyValuePair<string, IInventoryData> plugin in m_plugins) 195 foreach (KeyValuePair<string, IInventoryData> plugin in m_plugins)
196 { 196 {
@@ -239,141 +239,141 @@ namespace OpenSim.Framework.Communications
239 { 239 {
240 InventoryFolderBase folder = new InventoryFolderBase(); 240 InventoryFolderBase folder = new InventoryFolderBase();
241 241
242 folder.parentID = LLUUID.Zero; 242 folder.ParentID = LLUUID.Zero;
243 folder.agentID = user; 243 folder.AgentID = user;
244 folder.folderID = LLUUID.Random(); 244 folder.ID = LLUUID.Random();
245 folder.name = "My Inventory"; 245 folder.Name = "My Inventory";
246 folder.type = (short)AssetType.Folder; 246 folder.Type = (short)AssetType.Folder;
247 folder.version = 1; 247 folder.Version = 1;
248 Folders.Add(folder.folderID, folder); 248 Folders.Add(folder.ID, folder);
249 249
250 LLUUID rootFolder = folder.folderID; 250 LLUUID rootFolder = folder.ID;
251 251
252 folder = new InventoryFolderBase(); 252 folder = new InventoryFolderBase();
253 folder.parentID = rootFolder; 253 folder.ParentID = rootFolder;
254 folder.agentID = user; 254 folder.AgentID = user;
255 folder.folderID = LLUUID.Random(); 255 folder.ID = LLUUID.Random();
256 folder.name = "Animations"; 256 folder.Name = "Animations";
257 folder.type = (short)AssetType.Animation; 257 folder.Type = (short)AssetType.Animation;
258 folder.version = 1; 258 folder.Version = 1;
259 Folders.Add(folder.folderID, folder); 259 Folders.Add(folder.ID, folder);
260 260
261 folder = new InventoryFolderBase(); 261 folder = new InventoryFolderBase();
262 folder.parentID = rootFolder; 262 folder.ParentID = rootFolder;
263 folder.agentID = user; 263 folder.AgentID = user;
264 folder.folderID = LLUUID.Random(); 264 folder.ID = LLUUID.Random();
265 folder.name = "Body Parts"; 265 folder.Name = "Body Parts";
266 folder.type = (short)AssetType.Bodypart; 266 folder.Type = (short)AssetType.Bodypart;
267 folder.version = 1; 267 folder.Version = 1;
268 Folders.Add(folder.folderID, folder); 268 Folders.Add(folder.ID, folder);
269 269
270 folder = new InventoryFolderBase(); 270 folder = new InventoryFolderBase();
271 folder.parentID = rootFolder; 271 folder.ParentID = rootFolder;
272 folder.agentID = user; 272 folder.AgentID = user;
273 folder.folderID = LLUUID.Random(); 273 folder.ID = LLUUID.Random();
274 folder.name = "Calling Cards"; 274 folder.Name = "Calling Cards";
275 folder.type = (short)AssetType.CallingCard; 275 folder.Type = (short)AssetType.CallingCard;
276 folder.version = 1; 276 folder.Version = 1;
277 Folders.Add(folder.folderID, folder); 277 Folders.Add(folder.ID, folder);
278 278
279 folder = new InventoryFolderBase(); 279 folder = new InventoryFolderBase();
280 folder.parentID = rootFolder; 280 folder.ParentID = rootFolder;
281 folder.agentID = user; 281 folder.AgentID = user;
282 folder.folderID = LLUUID.Random(); 282 folder.ID = LLUUID.Random();
283 folder.name = "Clothing"; 283 folder.Name = "Clothing";
284 folder.type = (short)AssetType.Clothing; 284 folder.Type = (short)AssetType.Clothing;
285 folder.version = 1; 285 folder.Version = 1;
286 Folders.Add(folder.folderID, folder); 286 Folders.Add(folder.ID, folder);
287 287
288 folder = new InventoryFolderBase(); 288 folder = new InventoryFolderBase();
289 folder.parentID = rootFolder; 289 folder.ParentID = rootFolder;
290 folder.agentID = user; 290 folder.AgentID = user;
291 folder.folderID = LLUUID.Random(); 291 folder.ID = LLUUID.Random();
292 folder.name = "Gestures"; 292 folder.Name = "Gestures";
293 folder.type = (short)AssetType.Gesture; 293 folder.Type = (short)AssetType.Gesture;
294 folder.version = 1; 294 folder.Version = 1;
295 Folders.Add(folder.folderID, folder); 295 Folders.Add(folder.ID, folder);
296 296
297 folder = new InventoryFolderBase(); 297 folder = new InventoryFolderBase();
298 folder.parentID = rootFolder; 298 folder.ParentID = rootFolder;
299 folder.agentID = user; 299 folder.AgentID = user;
300 folder.folderID = LLUUID.Random(); 300 folder.ID = LLUUID.Random();
301 folder.name = "Landmarks"; 301 folder.Name = "Landmarks";
302 folder.type = (short)AssetType.Landmark; 302 folder.Type = (short)AssetType.Landmark;
303 folder.version = 1; 303 folder.Version = 1;
304 Folders.Add(folder.folderID, folder); 304 Folders.Add(folder.ID, folder);
305 305
306 folder = new InventoryFolderBase(); 306 folder = new InventoryFolderBase();
307 folder.parentID = rootFolder; 307 folder.ParentID = rootFolder;
308 folder.agentID = user; 308 folder.AgentID = user;
309 folder.folderID = LLUUID.Random(); 309 folder.ID = LLUUID.Random();
310 folder.name = "Lost And Found"; 310 folder.Name = "Lost And Found";
311 folder.type = (short)AssetType.LostAndFoundFolder; 311 folder.Type = (short)AssetType.LostAndFoundFolder;
312 folder.version = 1; 312 folder.Version = 1;
313 Folders.Add(folder.folderID, folder); 313 Folders.Add(folder.ID, folder);
314 314
315 folder = new InventoryFolderBase(); 315 folder = new InventoryFolderBase();
316 folder.parentID = rootFolder; 316 folder.ParentID = rootFolder;
317 folder.agentID = user; 317 folder.AgentID = user;
318 folder.folderID = LLUUID.Random(); 318 folder.ID = LLUUID.Random();
319 folder.name = "Notecards"; 319 folder.Name = "Notecards";
320 folder.type = (short)AssetType.Notecard; 320 folder.Type = (short)AssetType.Notecard;
321 folder.version = 1; 321 folder.Version = 1;
322 Folders.Add(folder.folderID, folder); 322 Folders.Add(folder.ID, folder);
323 323
324 folder = new InventoryFolderBase(); 324 folder = new InventoryFolderBase();
325 folder.parentID = rootFolder; 325 folder.ParentID = rootFolder;
326 folder.agentID = user; 326 folder.AgentID = user;
327 folder.folderID = LLUUID.Random(); 327 folder.ID = LLUUID.Random();
328 folder.name = "Objects"; 328 folder.Name = "Objects";
329 folder.type = (short)AssetType.Primitive; 329 folder.Type = (short)AssetType.Primitive;
330 folder.version = 1; 330 folder.Version = 1;
331 Folders.Add(folder.folderID, folder); 331 Folders.Add(folder.ID, folder);
332 332
333 folder = new InventoryFolderBase(); 333 folder = new InventoryFolderBase();
334 folder.parentID = rootFolder; 334 folder.ParentID = rootFolder;
335 folder.agentID = user; 335 folder.AgentID = user;
336 folder.folderID = LLUUID.Random(); 336 folder.ID = LLUUID.Random();
337 folder.name = "Photo Album"; 337 folder.Name = "Photo Album";
338 folder.type = (short)AssetType.SnapshotFolder; 338 folder.Type = (short)AssetType.SnapshotFolder;
339 folder.version = 1; 339 folder.Version = 1;
340 Folders.Add(folder.folderID, folder); 340 Folders.Add(folder.ID, folder);
341 341
342 folder = new InventoryFolderBase(); 342 folder = new InventoryFolderBase();
343 folder.parentID = rootFolder; 343 folder.ParentID = rootFolder;
344 folder.agentID = user; 344 folder.AgentID = user;
345 folder.folderID = LLUUID.Random(); 345 folder.ID = LLUUID.Random();
346 folder.name = "Scripts"; 346 folder.Name = "Scripts";
347 folder.type = (short)AssetType.LSLText; 347 folder.Type = (short)AssetType.LSLText;
348 folder.version = 1; 348 folder.Version = 1;
349 Folders.Add(folder.folderID, folder); 349 Folders.Add(folder.ID, folder);
350 350
351 folder = new InventoryFolderBase(); 351 folder = new InventoryFolderBase();
352 folder.parentID = rootFolder; 352 folder.ParentID = rootFolder;
353 folder.agentID = user; 353 folder.AgentID = user;
354 folder.folderID = LLUUID.Random(); 354 folder.ID = LLUUID.Random();
355 folder.name = "Sounds"; 355 folder.Name = "Sounds";
356 folder.type = (short)AssetType.Sound; 356 folder.Type = (short)AssetType.Sound;
357 folder.version = 1; 357 folder.Version = 1;
358 Folders.Add(folder.folderID, folder); 358 Folders.Add(folder.ID, folder);
359 359
360 folder = new InventoryFolderBase(); 360 folder = new InventoryFolderBase();
361 folder.parentID = rootFolder; 361 folder.ParentID = rootFolder;
362 folder.agentID = user; 362 folder.AgentID = user;
363 folder.folderID = LLUUID.Random(); 363 folder.ID = LLUUID.Random();
364 folder.name = "Textures"; 364 folder.Name = "Textures";
365 folder.type = (short)AssetType.Texture; 365 folder.Type = (short)AssetType.Texture;
366 folder.version = 1; 366 folder.Version = 1;
367 Folders.Add(folder.folderID, folder); 367 Folders.Add(folder.ID, folder);
368 368
369 folder = new InventoryFolderBase(); 369 folder = new InventoryFolderBase();
370 folder.parentID = rootFolder; 370 folder.ParentID = rootFolder;
371 folder.agentID = user; 371 folder.AgentID = user;
372 folder.folderID = LLUUID.Random(); 372 folder.ID = LLUUID.Random();
373 folder.name = "Trash"; 373 folder.Name = "Trash";
374 folder.type = (short)AssetType.TrashFolder; 374 folder.Type = (short)AssetType.TrashFolder;
375 folder.version = 1; 375 folder.Version = 1;
376 Folders.Add(folder.folderID, folder); 376 Folders.Add(folder.ID, folder);
377 } 377 }
378 } 378 }
379 } 379 }
diff --git a/OpenSim/Framework/Communications/LoginService.cs b/OpenSim/Framework/Communications/LoginService.cs
index 413a934..6f558a0 100644
--- a/OpenSim/Framework/Communications/LoginService.cs
+++ b/OpenSim/Framework/Communications/LoginService.cs
@@ -734,11 +734,11 @@ namespace OpenSim.Framework.UserManagement
734 foreach (InventoryFolderBase folder in rootFolders.Values) 734 foreach (InventoryFolderBase folder in rootFolders.Values)
735 { 735 {
736 Hashtable TempHash = new Hashtable(); 736 Hashtable TempHash = new Hashtable();
737 TempHash["name"] = folder.name; 737 TempHash["name"] = folder.Name;
738 TempHash["parent_id"] = folder.parentID.ToString(); 738 TempHash["parent_id"] = folder.ParentID.ToString();
739 TempHash["version"] = (Int32)folder.version; 739 TempHash["version"] = (Int32)folder.Version;
740 TempHash["type_default"] = (Int32)folder.type; 740 TempHash["type_default"] = (Int32)folder.Type;
741 TempHash["folder_id"] = folder.folderID.ToString(); 741 TempHash["folder_id"] = folder.ID.ToString();
742 folderHashes.Add(TempHash); 742 folderHashes.Add(TempHash);
743 } 743 }
744 744