diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs index 3b4deaf..6d911f1 100644 --- a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs +++ b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs | |||
@@ -123,6 +123,33 @@ namespace OpenSim.Region.Environment.Scenes | |||
123 | file.Close(); | 123 | file.Close(); |
124 | } | 124 | } |
125 | 125 | ||
126 | public string SavePrimGroupToXML2String(SceneObjectGroup grp) | ||
127 | { | ||
128 | string returnstring = ""; | ||
129 | returnstring += "<scene>\n"; | ||
130 | returnstring += grp.ToXmlString2(); | ||
131 | returnstring += "</scene>\n"; | ||
132 | return returnstring; | ||
133 | |||
134 | } | ||
135 | |||
136 | public void LoadGroupFromXml2String(string xmlString) | ||
137 | { | ||
138 | XmlDocument doc = new XmlDocument(); | ||
139 | XmlNode rootNode; | ||
140 | |||
141 | XmlTextReader reader = new XmlTextReader(new StringReader(xmlString)); | ||
142 | reader.WhitespaceHandling = WhitespaceHandling.None; | ||
143 | doc.Load(reader); | ||
144 | reader.Close(); | ||
145 | rootNode = doc.FirstChild; | ||
146 | foreach (XmlNode aPrimNode in rootNode.ChildNodes) | ||
147 | { | ||
148 | CreatePrimFromXml(aPrimNode.OuterXml); | ||
149 | } | ||
150 | |||
151 | } | ||
152 | |||
126 | public void LoadPrimsFromXml2(string fileName) | 153 | public void LoadPrimsFromXml2(string fileName) |
127 | { | 154 | { |
128 | XmlDocument doc = new XmlDocument(); | 155 | XmlDocument doc = new XmlDocument(); |