Mapper  0.9.0
API documentation
Public Member Functions | Protected Member Functions | List of all members
OpenOrienteering::XMLFileExporter Class Reference

Map exporter for the xml based map format. More...

#include <xml_file_format_p.h>

Inheritance diagram for OpenOrienteering::XMLFileExporter:
Inheritance graph
[legend]
Collaboration diagram for OpenOrienteering::XMLFileExporter:
Collaboration graph
[legend]

Public Member Functions

 XMLFileExporter (const QString &path, const Map *map, const MapView *view)
 
 XMLFileExporter ()=delete
 
 XMLFileExporter (const XMLFileExporter &)=delete
 
 XMLFileExporter (XMLFileExporter &&)=delete
 
 ~XMLFileExporter () override
 
XMLFileExporteroperator= (const XMLFileExporter &)=delete
 
XMLFileExporteroperator= (XMLFileExporter &&)=delete
 
- Public Member Functions inherited from OpenOrienteering::Exporter
 Exporter (const QString &path, const Map *map, const MapView *view)
 Creates a new Exporter with the given path, map, and view. More...
 
 ~Exporter () override
 Destroys the current Exporter. More...
 
bool doExport ()
 Exports the map and view. More...
 
- Public Member Functions inherited from OpenOrienteering::ImportExport
 ImportExport (QIODevice *device=nullptr)
 Creates a new importer or exporter with the given IO device. More...
 
 ImportExport (const ImportExport &)=delete
 
 ImportExport (ImportExport &&)=delete
 
virtual ~ImportExport ()
 Destroys an importer or exporter. More...
 
virtual bool supportsQIODevice () const noexcept
 Returns true when the importer/exporter supports QIODevice. More...
 
QIODevicedevice () const noexcept
 Returns the input device if it has been set or created. More...
 
void setDevice (QIODevice *device)
 Sets a custom input device to be used for import. More...
 
void setOption (const QString &name, const QVariant &value)
 Sets an option in this importer or exporter. More...
 
QVariant option (const QString &name) const
 Retrieves the value of an option in this instance. More...
 
void addWarning (const QString &str)
 Adds a string to the current list of warnings. More...
 
const std::vector< QString > & warnings () const noexcept
 Returns the current list of warnings collected by this object. More...
 

Protected Member Functions

bool exportImplementation () override
 Actual implementation of the export. More...
 
void exportGeoreferencing ()
 
void exportColors ()
 
void exportSymbols ()
 
void exportMapParts ()
 
void exportTemplates ()
 
void exportView ()
 
void exportPrint ()
 
void exportUndo ()
 
void exportRedo ()
 

Additional Inherited Members

- Protected Attributes inherited from OpenOrienteering::Exporter
const QString path
 The output path. More...
 
const Map *const map
 The Map to import or export. More...
 
const MapView *const view
 The MapView to import or export. More...
 

Detailed Description

Map exporter for the xml based map format.

Constructor & Destructor Documentation

◆ XMLFileExporter() [1/4]

OpenOrienteering::XMLFileExporter::XMLFileExporter ( const QString path,
const Map map,
const MapView view 
)

◆ XMLFileExporter() [2/4]

OpenOrienteering::XMLFileExporter::XMLFileExporter ( )
delete

◆ XMLFileExporter() [3/4]

OpenOrienteering::XMLFileExporter::XMLFileExporter ( const XMLFileExporter )
delete

◆ XMLFileExporter() [4/4]

OpenOrienteering::XMLFileExporter::XMLFileExporter ( XMLFileExporter &&  )
delete

◆ ~XMLFileExporter()

OpenOrienteering::XMLFileExporter::~XMLFileExporter ( )
overridedefault

Member Function Documentation

◆ exportColors()

void OpenOrienteering::XMLFileExporter::exportColors ( )
protected

◆ exportGeoreferencing()

void OpenOrienteering::XMLFileExporter::exportGeoreferencing ( )
protected

◆ exportImplementation()

bool OpenOrienteering::XMLFileExporter::exportImplementation ( )
overrideprotectedvirtual

Actual implementation of the export.

Exporters which support input from QIODevice shall use the device(). They must not open or close the device.

If information might be lost in the export, a message shall be recorded by calling addWarning() with a translated, useful description of the issue. If a fatal error is encountered, then this method may either throw an exception, or log an error message with addWarning() and return false.

There is no default implementation.

Implements OpenOrienteering::Exporter.

◆ exportMapParts()

void OpenOrienteering::XMLFileExporter::exportMapParts ( )
protected

◆ exportPrint()

void OpenOrienteering::XMLFileExporter::exportPrint ( )
protected

◆ exportRedo()

void OpenOrienteering::XMLFileExporter::exportRedo ( )
protected

◆ exportSymbols()

void OpenOrienteering::XMLFileExporter::exportSymbols ( )
protected

◆ exportTemplates()

void OpenOrienteering::XMLFileExporter::exportTemplates ( )
protected
Todo:
Update the relative paths in memory when saving to another directory. Otherwise opening templates in the reloaded saved map may behave different from the current map in memory.

◆ exportUndo()

void OpenOrienteering::XMLFileExporter::exportUndo ( )
protected

◆ exportView()

void OpenOrienteering::XMLFileExporter::exportView ( )
protected

◆ operator=() [1/2]

XMLFileExporter& OpenOrienteering::XMLFileExporter::operator= ( const XMLFileExporter )
delete

◆ operator=() [2/2]

XMLFileExporter& OpenOrienteering::XMLFileExporter::operator= ( XMLFileExporter &&  )
delete

The documentation for this class was generated from the following files: