private bool doExport(string filePath, DataSetType data_type )
{
// Initial stage for the export/import functionality is the ability to export/import
// the data correctly for the current city, uses OSDMap. For now the GTAIV flag is
// ignored, this needs to be changed to allow for internal, GTA and GIS data sets to
// be used for cities.
if (filePath == null || data_type == DataSetType.DATASET_TYPE_NULL)
{
return (false);
}
// Make sure the file is not present on the destination.
// ???
// First stage use a TarArchiveWriter in conjunction with OSDMap to write a file
// containing all the information needed about the city and regions to be able to
// import it in when the server is shutdown and restarted.
System.IO.MemoryStream data = new System.IO.MemoryStream(1024);
TarArchiveWriter tarArchive = null;
// Construct the archive before writing it to the destination.
tarArchive = new TarArchiveWriter(data);
tarArchive.WriteDir("citybuilder/");
tarArchive.WriteFile(filePath, data.GetBuffer());
return (false);
}