VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtModelDefinitionEditorLogic Class Reference

The logic for editing model definitions. More...

Inheritance diagram for makVrv::DtModelDefinitionEditorLogic:
Inheritance graph
[legend]

Public Member Functions

 DtModelDefinitionEditorLogic (DtDe &de, DtInstanceEditorInterface *instanceInterface, DtModelDefinitionEditorInterface *modelDefInterface, DtMapEditorInterface *mapInterface, DtPersistenceControlsInterface *toolbar, DtPage *page=0)
 CTOR. More...
 
virtual ~DtModelDefinitionEditorLogic ()
 DTOR. More...
 
virtual void checkIfModified ()
 check if the model definitions have changed since the start up More...
 

Protected Member Functions

virtual void createModelDefinition (const std::string &definitionName, const std::string &schema)
 
virtual void copyModelDefinition (const std::string &definitionName, const std::string &newName)
 
virtual void deleteModelDefinition (const std::vector< std::string > &definitionNames)
 
virtual void setSelectedDefinition (const std::string &definitionName, const std::string &schema)
 
virtual void setDefinitionFilter (const std::string &schema)
 
virtual void renameInstance (const std::string &oldName, const std::string &definitionName, int)
 
virtual void setDefinitionSchema (const std::string &schema)
 
virtual void renameParameter (const std::string &oldName, const std::string &newName)
 
virtual void modifyValue (const std::string &key, const std::string &value)
 
virtual void deleteValue (const std::string &key)
 
std::string generateDefinitionName (const std::string &rootName) const
 
void setupInstances ()
 
void setupFileFilter (const std::string &fileName)
 Filters out all definitions whose file names don't match the file name in the dropdown box. More...
 
void setupFileLocationBar ()
 Fill dropdown with list of files. More...
 
void changeFileLocation ()
 Change displayed file location to the model def currently slected. More...
 
void changeFileFilter ()
 Filter out model defs based on filter. More...
 
bool isDefinitionValid (const DtModelDefinition &definition)
 Get whether a definition is valid or not. More...
 
void setupFilters ()
 
void setupSchema ()
 
void setupModelDefinition ()
 
void setFileName (const std::string &currentLocation)
 Sets the file path displayed in the dropdown to match the path of the currently selected model. More...
 
void setupMap ()
 
virtual void onExportSelected ()
 Called when a user wants to export selected items of the current model definitions to a file. More...
 
virtual void onExportAllFiles ()
 Called when user wants to export all the model definitions to a file. More...
 
virtual void onExportSelectedChosen (const std::string &)
 Called when the export filename has been chosen. More...
 
virtual void onImport ()
 Called when a user wants to import (replace) selected schema with contents of selected file. More...
 
virtual void onImportFilenameChosen (const std::string &)
 Called when the import filename has been chose. More...
 
virtual void onMerge ()
 Called when a user wants to merge selected file into currently selected schema. More...
 
virtual void onMergeFilenameChosen (const std::string &)
 Called when the merge filename has been chose. More...
 
virtual void onSaveDefaults ()
 Called when a user wants to save the current model definitions to the default location (usually appData/definitions) Note: no need for onDefaultSaveFilenameChosen since we know the name already. More...
 
virtual void modelDefinitionsRestored (const DtSettingsBackup *s)
 Called when restored, restore gui. More...
 
virtual void schemaChanged (DtSettingsChangeObject *)
 Called when something about the schema has changed. Resets filters. More...
 
virtual DtModelDefinitionManagerdefinitionManager ()
 Returns model definition dictionary being used. More...
 
virtual const
DtModelDefinitionManager
definitionManager () const
 
virtual void addModelDefinition (const DtModelDefinition &newDef)
 Adds a new model definition into the system. More...
 
virtual void renameModelDefinition (const DtModelDefinition &old, const DtModelDefinition &newDef)
 Renames model definition. More...
 

Protected Attributes

DtDemyDe
 
DtSignalConnectionManager myConnections
 
DtInstanceEditorInterfacemyInstanceInterface
 
DtModelDefinitionEditorInterfacemyModelDefinitionInterface
 
DtMapEditorInterfacemyMapInterface
 
DtPersistenceControlsInterfacemyToolbarInterface
 
DtPagemyPage
 
std::string mySelectedDefinition
 
std::string myFilter
 
std::string mySchema
 
std::string myDirectoryPath
 

Detailed Description

The logic for editing model definitions.

Constructor & Destructor Documentation

makVrv::DtModelDefinitionEditorLogic::DtModelDefinitionEditorLogic ( DtDe de,
DtInstanceEditorInterface instanceInterface,
DtModelDefinitionEditorInterface modelDefInterface,
DtMapEditorInterface mapInterface,
DtPersistenceControlsInterface toolbar,
DtPage page = 0 
)

CTOR.

virtual makVrv::DtModelDefinitionEditorLogic::~DtModelDefinitionEditorLogic ( )
virtual

DTOR.

Member Function Documentation

virtual void makVrv::DtModelDefinitionEditorLogic::checkIfModified ( )
virtual

check if the model definitions have changed since the start up

virtual void makVrv::DtModelDefinitionEditorLogic::createModelDefinition ( const std::string &  definitionName,
const std::string &  schema 
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::copyModelDefinition ( const std::string &  definitionName,
const std::string &  newName 
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::deleteModelDefinition ( const std::vector< std::string > &  definitionNames)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::setSelectedDefinition ( const std::string &  definitionName,
const std::string &  schema 
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::setDefinitionFilter ( const std::string &  schema)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::renameInstance ( const std::string &  oldName,
const std::string &  definitionName,
int   
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::setDefinitionSchema ( const std::string &  schema)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::renameParameter ( const std::string &  oldName,
const std::string &  newName 
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::modifyValue ( const std::string &  key,
const std::string &  value 
)
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::deleteValue ( const std::string &  key)
protectedvirtual
std::string makVrv::DtModelDefinitionEditorLogic::generateDefinitionName ( const std::string &  rootName) const
protected
void makVrv::DtModelDefinitionEditorLogic::setupInstances ( )
protected
void makVrv::DtModelDefinitionEditorLogic::setupFileFilter ( const std::string &  fileName)
protected

Filters out all definitions whose file names don't match the file name in the dropdown box.

void makVrv::DtModelDefinitionEditorLogic::setupFileLocationBar ( )
protected

Fill dropdown with list of files.

void makVrv::DtModelDefinitionEditorLogic::changeFileLocation ( )
protected

Change displayed file location to the model def currently slected.

void makVrv::DtModelDefinitionEditorLogic::changeFileFilter ( )
protected

Filter out model defs based on filter.

bool makVrv::DtModelDefinitionEditorLogic::isDefinitionValid ( const DtModelDefinition definition)
protected

Get whether a definition is valid or not.

void makVrv::DtModelDefinitionEditorLogic::setupFilters ( )
protected
void makVrv::DtModelDefinitionEditorLogic::setupSchema ( )
protected
void makVrv::DtModelDefinitionEditorLogic::setupModelDefinition ( )
protected
void makVrv::DtModelDefinitionEditorLogic::setFileName ( const std::string &  currentLocation)
protected

Sets the file path displayed in the dropdown to match the path of the currently selected model.

void makVrv::DtModelDefinitionEditorLogic::setupMap ( )
protected
virtual void makVrv::DtModelDefinitionEditorLogic::onExportSelected ( )
protectedvirtual

Called when a user wants to export selected items of the current model definitions to a file.

virtual void makVrv::DtModelDefinitionEditorLogic::onExportAllFiles ( )
protectedvirtual

Called when user wants to export all the model definitions to a file.

virtual void makVrv::DtModelDefinitionEditorLogic::onExportSelectedChosen ( const std::string &  )
protectedvirtual

Called when the export filename has been chosen.

Will export selected items to the given file

virtual void makVrv::DtModelDefinitionEditorLogic::onImport ( )
protectedvirtual

Called when a user wants to import (replace) selected schema with contents of selected file.

virtual void makVrv::DtModelDefinitionEditorLogic::onImportFilenameChosen ( const std::string &  )
protectedvirtual

Called when the import filename has been chose.

Will import contents of file to selected schema

virtual void makVrv::DtModelDefinitionEditorLogic::onMerge ( )
protectedvirtual

Called when a user wants to merge selected file into currently selected schema.

Merge will replace or add, not delete items

virtual void makVrv::DtModelDefinitionEditorLogic::onMergeFilenameChosen ( const std::string &  )
protectedvirtual

Called when the merge filename has been chose.

Will merge contents of file to selected schema

virtual void makVrv::DtModelDefinitionEditorLogic::onSaveDefaults ( )
protectedvirtual

Called when a user wants to save the current model definitions to the default location (usually appData/definitions) Note: no need for onDefaultSaveFilenameChosen since we know the name already.

virtual void makVrv::DtModelDefinitionEditorLogic::modelDefinitionsRestored ( const DtSettingsBackup s)
protectedvirtual

Called when restored, restore gui.

virtual void makVrv::DtModelDefinitionEditorLogic::schemaChanged ( DtSettingsChangeObject )
protectedvirtual

Called when something about the schema has changed. Resets filters.

virtual DtModelDefinitionManager& makVrv::DtModelDefinitionEditorLogic::definitionManager ( )
protectedvirtual

Returns model definition dictionary being used.

Reimplemented in makVrv::DtModelDefinitionInstanceEditorLogic.

virtual const DtModelDefinitionManager& makVrv::DtModelDefinitionEditorLogic::definitionManager ( ) const
protectedvirtual
virtual void makVrv::DtModelDefinitionEditorLogic::addModelDefinition ( const DtModelDefinition newDef)
protectedvirtual

Adds a new model definition into the system.

Reimplemented in makVrv::DtModelDefinitionInstanceEditorLogic.

virtual void makVrv::DtModelDefinitionEditorLogic::renameModelDefinition ( const DtModelDefinition old,
const DtModelDefinition newDef 
)
protectedvirtual

Renames model definition.

Reimplemented in makVrv::DtModelDefinitionInstanceEditorLogic.

Member Data Documentation

DtDe& makVrv::DtModelDefinitionEditorLogic::myDe
protected
DtSignalConnectionManager makVrv::DtModelDefinitionEditorLogic::myConnections
protected
DtInstanceEditorInterface* makVrv::DtModelDefinitionEditorLogic::myInstanceInterface
protected
DtModelDefinitionEditorInterface* makVrv::DtModelDefinitionEditorLogic::myModelDefinitionInterface
protected
DtMapEditorInterface* makVrv::DtModelDefinitionEditorLogic::myMapInterface
protected
DtPersistenceControlsInterface* makVrv::DtModelDefinitionEditorLogic::myToolbarInterface
protected
DtPage* makVrv::DtModelDefinitionEditorLogic::myPage
protected
std::string makVrv::DtModelDefinitionEditorLogic::mySelectedDefinition
protected
std::string makVrv::DtModelDefinitionEditorLogic::myFilter
protected
std::string makVrv::DtModelDefinitionEditorLogic::mySchema
protected
std::string makVrv::DtModelDefinitionEditorLogic::myDirectoryPath
protected

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

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)