* refactor: remove xml serialization wrappers from Scene
parent
eb6cca4750
commit
667a935fff
|
@ -42,8 +42,6 @@ using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Framework.Servers;
|
using OpenSim.Framework.Servers;
|
||||||
using OpenSim.Region.Environment.Interfaces;
|
using OpenSim.Region.Environment.Interfaces;
|
||||||
using OpenSim.Region.Interfaces;
|
using OpenSim.Region.Interfaces;
|
||||||
using OpenSim.Region.Environment.Modules.World.Archiver;
|
|
||||||
using OpenSim.Region.Environment.Modules.World.Serialiser;
|
|
||||||
using OpenSim.Region.Environment.Modules.World.Terrain;
|
using OpenSim.Region.Environment.Modules.World.Terrain;
|
||||||
using OpenSim.Region.Environment.Scenes.Scripting;
|
using OpenSim.Region.Environment.Scenes.Scripting;
|
||||||
using OpenSim.Region.Physics.Manager;
|
using OpenSim.Region.Physics.Manager;
|
||||||
|
@ -1882,20 +1880,6 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void LoadPrimsFromXml(string fileName, bool newIdsFlag, Vector3 loadOffset)
|
|
||||||
{
|
|
||||||
m_log.InfoFormat("[SCENE]: Loading prims in xml format to region {0} from {1}", RegionInfo.RegionName, fileName);
|
|
||||||
|
|
||||||
m_serialiser.LoadPrimsFromXml(this, fileName, newIdsFlag, loadOffset);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void SavePrimsToXml(string fileName)
|
|
||||||
{
|
|
||||||
m_log.InfoFormat("[SCENE]: Saving prims in xml format for region {0} to {1}", RegionInfo.RegionName, fileName);
|
|
||||||
|
|
||||||
m_serialiser.SavePrimsToXml(this, fileName);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void LoadPrimsFromXml2(string fileName)
|
public void LoadPrimsFromXml2(string fileName)
|
||||||
{
|
{
|
||||||
m_log.InfoFormat("[SCENE]: Loading prims in xml2 format to region {0} from {1}", RegionInfo.RegionName, fileName);
|
m_log.InfoFormat("[SCENE]: Loading prims in xml2 format to region {0} from {1}", RegionInfo.RegionName, fileName);
|
||||||
|
|
|
@ -184,7 +184,9 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
/// <param name="filename"></param>
|
/// <param name="filename"></param>
|
||||||
public void SaveCurrentSceneToXml(string filename)
|
public void SaveCurrentSceneToXml(string filename)
|
||||||
{
|
{
|
||||||
CurrentOrFirstScene.SavePrimsToXml(filename);
|
IRegionSerialiserModule serialiser = CurrentOrFirstScene.RequestModuleInterface<IRegionSerialiserModule>();
|
||||||
|
if (serialiser != null)
|
||||||
|
serialiser.SavePrimsToXml(CurrentOrFirstScene, filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -195,7 +197,9 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
/// <param name="loadOffset"></param>
|
/// <param name="loadOffset"></param>
|
||||||
public void LoadCurrentSceneFromXml(string filename, bool generateNewIDs, Vector3 loadOffset)
|
public void LoadCurrentSceneFromXml(string filename, bool generateNewIDs, Vector3 loadOffset)
|
||||||
{
|
{
|
||||||
CurrentOrFirstScene.LoadPrimsFromXml(filename, generateNewIDs, loadOffset);
|
IRegionSerialiserModule serialiser = CurrentOrFirstScene.RequestModuleInterface<IRegionSerialiserModule>();
|
||||||
|
if (serialiser != null)
|
||||||
|
serialiser.LoadPrimsFromXml(CurrentOrFirstScene, filename, generateNewIDs, loadOffset);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
Loading…
Reference in New Issue