VR-Forces 4.1 Class Documentation
List of all members | Classes | Public Member Functions | Protected Types | Protected Attributes
DtCSVScenarioDescriptionImporterExporter Class Reference
Inheritance diagram for DtCSVScenarioDescriptionImporterExporter:
Inheritance graph
[legend]

Classes

struct  ObjectInformation
 This structure will define the information that is either read in or to be written out to the import file. More...

Public Member Functions

 DtCSVScenarioDescriptionImporterExporter ()
 CTOR.
virtual ~DtCSVScenarioDescriptionImporterExporter ()
 DTOR.
virtual bool loadScenarioDescription (const DtFilename &file, const std::map< std::string, std::string > &importData, const DtMSDLHierarchyPropertyMappings &)
 Loads information from the supplied CSV file into internal structures.
virtual
DtScenarioDescriptionImporterExporter
clone ()
 Clone to create a new copy of the object. Will be used as a "clean" version for import.
virtual bool importIntoSimulation (DtSimManager *)
 Imports into the simulation.
virtual bool importFromSimulation (DtSimManager *, const std::map< std::string, std::string > &exportData, const DtMSDLHierarchyPropertyMappings &)
 Imports from the simulation into internal structures.
virtual bool saveScenarioDescription (const DtFilename &file, const DtScenario &) const
 Saves the scenario description information to the specified file.
virtual std::string supportedExtensions ()
 Returns a space delimeted list of the extensions supported ("csv txt")
virtual bool canImportFile (const DtFilename &)
 Returns true if the supplied file can be loaded by this importer.
- Public Member Functions inherited from DtScenarioDescriptionImporterExporter
 DtScenarioDescriptionImporterExporter ()
 CTOR.
virtual ~DtScenarioDescriptionImporterExporter ()
 DTOR.
const DtScenarioscenario () const
const std::string & error () const
virtual bool complete () const
 Return true if import is complete. Default is true.

Protected Types

typedef std::map< DtString,
ObjectInformation * > 
ObjectMap
 Map by name of objects in the scenario.
typedef std::map< DtString,
std::vector< ObjectInformation * > > 
WaitingMap
 List of objects that have not been parented yet and are awaiting a superior to be read from file.

Protected Attributes

ObjectMap myObjectMap
WaitingMap myToBeParented
- Protected Attributes inherited from DtScenarioDescriptionImporterExporter
DtScenario myScenario
std::string myError

Member Typedef Documentation

Map by name of objects in the scenario.

List of objects that have not been parented yet and are awaiting a superior to be read from file.

Constructor & Destructor Documentation

DtCSVScenarioDescriptionImporterExporter::DtCSVScenarioDescriptionImporterExporter ( )

CTOR.

virtual DtCSVScenarioDescriptionImporterExporter::~DtCSVScenarioDescriptionImporterExporter ( )
virtual

DTOR.

Member Function Documentation

virtual bool DtCSVScenarioDescriptionImporterExporter::loadScenarioDescription ( const DtFilename &  file,
const std::map< std::string, std::string > &  importData,
const DtMSDLHierarchyPropertyMappings  
)
virtual

Loads information from the supplied CSV file into internal structures.

Import data may contain additional information to be applied to the load. DtMSDLHierarchyPropertyMappings contains MSDL specific hierarchy mappings (SIDC code and Military Enumeration) in case this format wishes to use that information.

Implements DtScenarioDescriptionImporterExporter.

Reimplemented in DtVrfCSVScenarioDescriptionImporterExporter.

virtual DtScenarioDescriptionImporterExporter* DtCSVScenarioDescriptionImporterExporter::clone ( )
virtual

Clone to create a new copy of the object. Will be used as a "clean" version for import.

Implements DtScenarioDescriptionImporterExporter.

Reimplemented in DtVrfCSVScenarioDescriptionImporterExporter.

virtual bool DtCSVScenarioDescriptionImporterExporter::importIntoSimulation ( DtSimManager )
virtual

Imports into the simulation.

DtSimManager is not defined at this level, so subclasses at vrfobjcore level must implement. This level is a no-op

Implements DtScenarioDescriptionImporterExporter.

Reimplemented in DtVrfCSVScenarioDescriptionImporterExporter.

virtual bool DtCSVScenarioDescriptionImporterExporter::importFromSimulation ( DtSimManager ,
const std::map< std::string, std::string > &  exportData,
const DtMSDLHierarchyPropertyMappings  
)
virtual

Imports from the simulation into internal structures.

DtSimManager is not defined at this level, so subclasses at vrfobjcore level must implement. This level is a no-op

Implements DtScenarioDescriptionImporterExporter.

Reimplemented in DtVrfCSVScenarioDescriptionImporterExporter.

virtual bool DtCSVScenarioDescriptionImporterExporter::saveScenarioDescription ( const DtFilename &  file,
const DtScenario  
) const
virtual

Saves the scenario description information to the specified file.

The format will be a comma delimeted format containing the information specified at the top of this file

Implements DtScenarioDescriptionImporterExporter.

virtual std::string DtCSVScenarioDescriptionImporterExporter::supportedExtensions ( )
virtual

Returns a space delimeted list of the extensions supported ("csv txt")

Implements DtScenarioDescriptionImporterExporter.

virtual bool DtCSVScenarioDescriptionImporterExporter::canImportFile ( const DtFilename &  )
virtual

Returns true if the supplied file can be loaded by this importer.

Implements DtScenarioDescriptionImporterExporter.

Member Data Documentation

ObjectMap DtCSVScenarioDescriptionImporterExporter::myObjectMap
protected
WaitingMap DtCSVScenarioDescriptionImporterExporter::myToBeParented
protected

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

Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)