diff options
author | Justin Clark-Casey (justincc) | 2009-11-24 17:28:38 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2009-11-24 17:28:38 +0000 |
commit | 88ead9ee63fe87b16d7c24b3a38bf6567f3166f6 (patch) | |
tree | 950bc1123bba17a0583076fc0c6a5009028211e9 /OpenSim/Region/CoreModules | |
parent | minor: remove experimental tags from load iar and save iar commands (diff) | |
download | opensim-SC-88ead9ee63fe87b16d7c24b3a38bf6567f3166f6.zip opensim-SC-88ead9ee63fe87b16d7c24b3a38bf6567f3166f6.tar.gz opensim-SC-88ead9ee63fe87b16d7c24b3a38bf6567f3166f6.tar.bz2 opensim-SC-88ead9ee63fe87b16d7c24b3a38bf6567f3166f6.tar.xz |
pass all command parameters to load/save oar, not just the filename
unfortunately, these commands cannot yet be properly relocated to the region modules due to deficiencies in the region module infrastructure
Diffstat (limited to 'OpenSim/Region/CoreModules')
-rw-r--r-- | OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs index 8d4f91b..181f4c6 100644 --- a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs +++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs | |||
@@ -45,6 +45,11 @@ namespace OpenSim.Region.CoreModules.World.Archiver | |||
45 | 45 | ||
46 | private Scene m_scene; | 46 | private Scene m_scene; |
47 | 47 | ||
48 | /// <value> | ||
49 | /// The file used to load and save an opensimulator archive if no filename has been specified | ||
50 | /// </value> | ||
51 | protected const string DEFAULT_OAR_BACKUP_FILENAME = "region.oar"; | ||
52 | |||
48 | public string Name | 53 | public string Name |
49 | { | 54 | { |
50 | get { return "RegionArchiverModule"; } | 55 | get { return "RegionArchiverModule"; } |
@@ -80,6 +85,38 @@ namespace OpenSim.Region.CoreModules.World.Archiver | |||
80 | { | 85 | { |
81 | } | 86 | } |
82 | 87 | ||
88 | /// <summary> | ||
89 | /// Load a whole region from an opensimulator archive. | ||
90 | /// </summary> | ||
91 | /// <param name="cmdparams"></param> | ||
92 | public void HandleLoadOarConsoleCommand(string module, string[] cmdparams) | ||
93 | { | ||
94 | if (cmdparams.Length > 2) | ||
95 | { | ||
96 | DearchiveRegion(cmdparams[2]); | ||
97 | } | ||
98 | else | ||
99 | { | ||
100 | DearchiveRegion(DEFAULT_OAR_BACKUP_FILENAME); | ||
101 | } | ||
102 | } | ||
103 | |||
104 | /// <summary> | ||
105 | /// Save a region to a file, including all the assets needed to restore it. | ||
106 | /// </summary> | ||
107 | /// <param name="cmdparams"></param> | ||
108 | public void HandleSaveOarConsoleCommand(string module, string[] cmdparams) | ||
109 | { | ||
110 | if (cmdparams.Length > 2) | ||
111 | { | ||
112 | ArchiveRegion(cmdparams[2]); | ||
113 | } | ||
114 | else | ||
115 | { | ||
116 | ArchiveRegion(DEFAULT_OAR_BACKUP_FILENAME); | ||
117 | } | ||
118 | } | ||
119 | |||
83 | public void ArchiveRegion(string savePath) | 120 | public void ArchiveRegion(string savePath) |
84 | { | 121 | { |
85 | ArchiveRegion(savePath, Guid.Empty); | 122 | ArchiveRegion(savePath, Guid.Empty); |