aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules/World/Serialiser
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-06-21 21:20:59 +0000
committerJustin Clarke Casey2008-06-21 21:20:59 +0000
commit908d91be78038832945eec5c4d05c71ab64e3680 (patch)
treed7274271c36fa557c0b22833e614e2e122922d6c /OpenSim/Region/Environment/Modules/World/Serialiser
parent* Remove redundant <scene> tag from individual object xml representation (diff)
downloadopensim-SC-908d91be78038832945eec5c4d05c71ab64e3680.zip
opensim-SC-908d91be78038832945eec5c4d05c71ab64e3680.tar.gz
opensim-SC-908d91be78038832945eec5c4d05c71ab64e3680.tar.bz2
opensim-SC-908d91be78038832945eec5c4d05c71ab64e3680.tar.xz
* refactor: Making some of the serialization names consistent, both within their pairings and with the others
* This does make some of the names less ideal than others - this should change in the future
Diffstat (limited to 'OpenSim/Region/Environment/Modules/World/Serialiser')
-rw-r--r--OpenSim/Region/Environment/Modules/World/Serialiser/IRegionSerialiser.cs31
-rw-r--r--OpenSim/Region/Environment/Modules/World/Serialiser/SceneXmlLoader.cs4
-rw-r--r--OpenSim/Region/Environment/Modules/World/Serialiser/SerialiserModule.cs8
3 files changed, 35 insertions, 8 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Serialiser/IRegionSerialiser.cs b/OpenSim/Region/Environment/Modules/World/Serialiser/IRegionSerialiser.cs
index e0d2add..e6090a7 100644
--- a/OpenSim/Region/Environment/Modules/World/Serialiser/IRegionSerialiser.cs
+++ b/OpenSim/Region/Environment/Modules/World/Serialiser/IRegionSerialiser.cs
@@ -36,8 +36,20 @@ namespace OpenSim.Region.Environment.Modules.World.Serialiser
36 { 36 {
37 List<string> SerialiseRegion(Scene scene, string saveDir); 37 List<string> SerialiseRegion(Scene scene, string saveDir);
38 38
39 /// <summary>
40 /// Load prims from the xml format
41 /// </summary>
42 /// <param name="scene"></param>
43 /// <param name="fileName"></param>
44 /// <param name="newIDS"></param>
45 /// <param name="loadOffset"></param>
39 void LoadPrimsFromXml(Scene scene, string fileName, bool newIDS, LLVector3 loadOffset); 46 void LoadPrimsFromXml(Scene scene, string fileName, bool newIDS, LLVector3 loadOffset);
40 47
48 /// <summary>
49 /// Save prims in the xml format
50 /// </summary>
51 /// <param name="scene"> </param>
52 /// <param name="fileName"></param>
41 void SavePrimsToXml(Scene scene, string fileName); 53 void SavePrimsToXml(Scene scene, string fileName);
42 54
43 /// <summary> 55 /// <summary>
@@ -54,10 +66,25 @@ namespace OpenSim.Region.Environment.Modules.World.Serialiser
54 /// <param name="reader"></param> 66 /// <param name="reader"></param>
55 void LoadPrimsFromXml2(Scene scene, TextReader reader); 67 void LoadPrimsFromXml2(Scene scene, TextReader reader);
56 68
69 /// <summary>
70 /// Save prims in the xml2 format
71 /// </summary>
72 /// <param name="scene"></param>
73 /// <param name="fileName"></param>
57 void SavePrimsToXml2(Scene scene, string fileName); 74 void SavePrimsToXml2(Scene scene, string fileName);
58 75
59 void LoadGroupFromXml2String(Scene scene, string xmlString); 76 /// <summary>
77 /// Load an individual scene object from the xml2 format
78 /// </summary>
79 /// <param name="scene"></param>
80 /// <param name="xmlString"></param>
81 void LoadGroupFromXml2(Scene scene, string xmlString);
60 82
61 string SavePrimGroupToXML2String(SceneObjectGroup grp); 83 /// <summary>
84 /// Serialize an individual scene object into the xml2 format
85 /// </summary>
86 /// <param name="grp"></param>
87 /// <returns></returns>
88 string SaveGroupToXml2(SceneObjectGroup grp);
62 } 89 }
63} 90}
diff --git a/OpenSim/Region/Environment/Modules/World/Serialiser/SceneXmlLoader.cs b/OpenSim/Region/Environment/Modules/World/Serialiser/SceneXmlLoader.cs
index 7cc2459..1945fac 100644
--- a/OpenSim/Region/Environment/Modules/World/Serialiser/SceneXmlLoader.cs
+++ b/OpenSim/Region/Environment/Modules/World/Serialiser/SceneXmlLoader.cs
@@ -99,12 +99,12 @@ namespace OpenSim.Region.Environment.Scenes
99 file.Close(); 99 file.Close();
100 } 100 }
101 101
102 public static string SavePrimGroupToXML2String(SceneObjectGroup grp) 102 public static string SaveGroupToXml2(SceneObjectGroup grp)
103 { 103 {
104 return grp.ToXmlString2(); 104 return grp.ToXmlString2();
105 } 105 }
106 106
107 public static void LoadGroupFromXml2String(Scene scene, string xmlString) 107 public static void LoadGroupFromXml2(Scene scene, string xmlString)
108 { 108 {
109 XmlDocument doc = new XmlDocument(); 109 XmlDocument doc = new XmlDocument();
110 XmlNode rootNode; 110 XmlNode rootNode;
diff --git a/OpenSim/Region/Environment/Modules/World/Serialiser/SerialiserModule.cs b/OpenSim/Region/Environment/Modules/World/Serialiser/SerialiserModule.cs
index c7c8e39..01f6301 100644
--- a/OpenSim/Region/Environment/Modules/World/Serialiser/SerialiserModule.cs
+++ b/OpenSim/Region/Environment/Modules/World/Serialiser/SerialiserModule.cs
@@ -112,14 +112,14 @@ namespace OpenSim.Region.Environment.Modules.World.Serialiser
112 SceneXmlLoader.SavePrimsToXml2(scene, fileName); 112 SceneXmlLoader.SavePrimsToXml2(scene, fileName);
113 } 113 }
114 114
115 public void LoadGroupFromXml2String(Scene scene, string xmlString) 115 public void LoadGroupFromXml2(Scene scene, string xmlString)
116 { 116 {
117 SceneXmlLoader.LoadGroupFromXml2String(scene, xmlString); 117 SceneXmlLoader.LoadGroupFromXml2(scene, xmlString);
118 } 118 }
119 119
120 public string SavePrimGroupToXML2String(SceneObjectGroup grp) 120 public string SaveGroupToXml2(SceneObjectGroup grp)
121 { 121 {
122 return SceneXmlLoader.SavePrimGroupToXML2String(grp); 122 return SceneXmlLoader.SaveGroupToXml2(grp);
123 } 123 }
124 124
125 public List<string> SerialiseRegion(Scene scene, string saveDir) 125 public List<string> SerialiseRegion(Scene scene, string saveDir)