API Documentation
Loading...
Searching...
No Matches
DesignObjectLookup Class Reference

#include <DesignObjectLookup.h>

Inheritance diagram for DesignObjectLookup:
[legend]
Collaboration diagram for DesignObjectLookup:
[legend]

Public Member Functions

 DesignObjectLookup ()
 
virtual ~DesignObjectLookup ()
 
WLock writeLock ()
 
RLock readLock () const
 
void setupDefaultScene ()
 
WLock writeLock (const std::function< void()> &wait_callback)
 
RLock readLock (const std::function< void()> &wait_callback) const
 
WLock tryWriteLock (uint08 milliseconds=10)
 
RLock tryReadLock (uint08 milliseconds=10) const
 
WLock tryWriteLock (const TimeSpan &span)
 
RLock tryReadLock (const TimeSpan &span) const
 
WLock commandLock ()
 
WLock tryCommandLock ()
 
bool isCommandLocked () const
 
const void * lockPtr () const
 
RDesignLock readLock (UUID id)
 
WDesignLock writeLock (UUID id)
 
virtual void addScene (Scene scene, bool ignore_application_scene=false)
 
virtual void addMaterial (Material object)
 
virtual void addGeometry (Geometry object)
 
virtual void addEffect (Effect object)
 
virtual void addModel (Model object)
 
virtual void addCameraModel (const UUID &camera, const Model &object)
 
virtual void addLayer (Model layer)
 
virtual void addSelection (const DesignSelection &object)
 
virtual void clearSelected ()
 
virtual void setSelected (Buffer< UUID > ids)
 
virtual void appendSelected (Buffer< UUID > ids)
 
virtual void refreshScene (UUID scene_id, bool ignore_application_scene)
 
virtual void refreshModel (const Model &object)
 
virtual void updateModelTopLevel (const Model &object)
 
virtual void executePendingCommands ()
 
virtual void deleteObject (UUID id)
 
virtual void eraseModel (UUID id)
 
virtual Model restoreModel (UUID id)
 
virtual void setActiveLayer (UUID layer_id)
 
virtual void setActiveProject (UUID layer_id)
 
virtual UUID activeProject () const
 
virtual Project activeProjectModel () const
 
void ensureLayerExistsInScene (const UUID &layer_id, const UUID &scene_id)
 
void addUpdateTarget (DesignObjectUpdateTarget *target)
 
void removeUpdateTarget (DesignObjectUpdateTarget *target)
 
Geometry geometry (const UUID &id, bool allow_deleted=false) const
 
Material material (const UUID &id, bool allow_deleted=false) const
 
Scene scene (const UUID &id, bool allow_deleted=false) const
 
Model modelOrLayer (const UUID &id, bool allow_deleted=false) const
 
Model model (const UUID &id, bool allow_deleted=false) const
 
Effect effect (const UUID &id, bool allow_deleted=false) const
 
Model layer (const UUID &id, bool allow_deleted=false) const
 
Model layer (const UUID &layer_id, const UUID &scene_id, bool allow_deleted=false) const
 
Model findLayer (const String &layer, bool use_translation=true) const
 
Model findLayer (const TranslatedString &layer) const
 
virtual DesignCommandManagercommandManager ()
 
const DynamicPointer< DesignSelection > & getSelectionInfo (const UUID &id)
 
const ConstPointer< DesignSelection > & getSelectionInfo (const UUID &id) const
 
bool hasModelID (const UUID &id, bool allow_deleted=false) const
 
bool hasSceneID (const UUID &id, bool allow_deleted=false) const
 
bool hasObjectID (const UUID &id, bool allow_deleted=false) const
 
bool hasMaterialID (const UUID &id) const
 
bool hasGeometryID (const UUID &id) const
 
bool hasEffect (const UUID &id) const
 
bool hasSelectionInfo (const UUID &id) const
 
bool hasLayerID (const UUID &id, bool allow_deleted=false) const
 
bool hasLayerID (const UUID &id, const UUID &scene_id) const
 
const Dictionary< UUID, Model > & getAllSceneLayers (const UUID &id) const
 
DesignObject object (const UUID &id) const
 
Buffer< UUIDgetRootObjectIDs (bool include_app_owned=false) const
 
Buffer< UUIDgetRootObjectIDs (UUID camera_id, bool include_app_owned=false) const
 
Buffer< ModelgetRootObjects (bool include_app_owned=false) const
 
Buffer< ModelgetRootObjects (UUID camera_id, bool include_app_owned=false) const
 
void processSelection (SelectionInfo &info) const
 
void colorByChannel (UUID target, const DesignParameter &channel)
 
Bounds< 3, fltp08bounds () const
 
Bounds< 3, fltp08boundsOfVisible () const
 
virtual LogManagerlogManager () const
 
virtual DesignTaskManagertaskManager () const
 
virtual void postCommand (const DynamicPointer< DesignCommand > &command)
 
virtual void runCommand (const DynamicPointer< DesignCommand > &command)
 
virtual void finishCommand (const DynamicPointer< DesignCommand > &command)
 
Buffer< UUIDgetModelIDsByType (const String &type) const
 
Buffer< ModelgetModelsByType (const String &type) const
 
Buffer< ModelgetModelsByType (const Buffer< String > &types) const
 
Buffer< ModelgetLayersByType (const String &type) const
 
Buffer< ModelgetLayersByType (const Buffer< String > &types) const
 
Buffer< ModelgetModelsByID (const Buffer< UUID > &ids) const
 
Buffer< ModelgetModelsByName (const String &name) const
 
void setSelectionEffect (SelectionEffect *effect)
 
const ScenedefaultScene ()
 
Material createMaterial ()
 
Material createCameraMaterial (UUID camera)
 
const Dictionary< UUID, Scene > & sceneObjects ()
 
const Dictionary< UUID, Model > & modelObjects ()
 
const Dictionary< UUID, Dictionary< UUID, Model > > & layerObjects ()
 
const Dictionary< UUID, Material > & materialObjects ()
 
const Dictionary< UUID, Geometry > & geometryObjects ()
 
const Dictionary< UUID, DesignObject > & objects ()
 
const Dictionary< UUID, Effect > & effectObjects ()
 
const Dictionary< UUID, DesignObject > & deletedObjects ()
 
void removeDeletedObject (UUID id)
 
Buffer< UUIDvisibleModels () const
 
Geometry createMesh ()
 
Model createModel ()
 
Model createCameraModel (UUID camera)
 
Model createLayer ()
 
void invalidateStationVisuals (bool invalidate_visuals, bool invalidate_font)
 
void updateTranslation ()
 
virtual void clearAll ()
 
void cleanupMemory (Buffer< UUID > deleted_objects)
 
virtual void update (const Time &time, const std::function< void()> &wait_callback)
 
virtual void requestAutoSave ()
 
virtual void requestAutoSaveCheckpoint ()
 
virtual Buffer< UUIDgetInverseOf (const Buffer< UUID > &model_ids)
 
virtual Buffer< UUIDgetDescendentsOf (const Buffer< UUID > &model_ids)
 
void selectEnclosed (UUID selection_id)
 
Buffer< DesignParameter, uint04, ObjectAllocator< false > > designParameters () const
 
Buffer< DesignParameterAccumulator, uint04, ObjectAllocator< false > > accumulateDesignParameters (const BitFlag &accumulation_flags) const
 
DesignParameterAccumulator accumulateDesignParameter (const DesignParameter &channel, const BitFlag &accumulation_flags) const
 

Public Attributes

Resource< RGBColorfocus_color
 
Resource< UUIDcurrent_layer
 
Resource< Timemodified_time
 
Resource< Timeautosave_request_time
 
Resource< Timeautosave_checkpoint_request_time
 

Protected Member Functions

void updateEffects (const Time &time, const std::function< void()> &wait_callback)
 

Protected Attributes

UUID m_active_layer
 
UUID m_active_project
 
Scene m_default_scene
 
SelectionController * m_selection_controller
 
ModelEditController * m_edit_controller
 
DesignCommandManagerm_command_controller
 
SelectionEffectm_selection_effect
 
LogManagerm_log_manager
 
DesignTaskManagerm_task_controller
 
Dictionary< UUID, Modelm_camera_root
 
Dictionary< UUID, Scenem_all_scene_objects
 
Dictionary< UUID, Scenem_scene_objects
 
Dictionary< UUID, Modelm_model_objects
 
Dictionary< UUID, DesignObjectm_design_objects
 
Dictionary< UUID, DesignObjectm_deleted_objects
 
Dictionary< UUID, UUIDm_erased_objects
 
Dictionary< UUID, Modelm_model_root_objects
 
Dictionary< UUID, Modelm_application_root_objects
 
Dictionary< UUID, Dictionary< UUID, Model > > m_layer_objects
 
Dictionary< UUID, Materialm_material_objects
 
Dictionary< UUID, Geometrym_geometry_objects
 
Dictionary< UUID, Effectm_effect_objects
 
Dictionary< UUID, DynamicPointer< DesignSelection > > m_selection_info
 
ResourceListenerm_invalidate_station_visuals_listener
 
ResourceListenerm_language_change_listener
 
Buffer< DesignObjectUpdateTarget * > m_update_targets
 
Time m_last_update_time
 
TimeSpan m_prefered_update_timespan
 
bool m_update_station_visuals
 
bool m_update_station_font
 
bool m_update_language
 
UUID m_uuid
 

Constructor & Destructor Documentation

◆ DesignObjectLookup()

◆ ~DesignObjectLookup()

~DesignObjectLookup ( )
virtual

Member Function Documentation

◆ accumulateDesignParameter()

DesignParameterAccumulator accumulateDesignParameter ( const DesignParameter & channel,
const BitFlag & accumulation_flags ) const

◆ accumulateDesignParameters()

Buffer< DesignParameterAccumulator > accumulateDesignParameters ( const BitFlag & accumulation_flags) const

◆ activeProject()

virtual UUID activeProject ( ) const
inlinevirtual

◆ activeProjectModel()

Project activeProjectModel ( ) const
virtual

◆ addCameraModel()

void addCameraModel ( const UUID & camera,
const Model & object )
virtual

Reimplemented in QTModelManager.

◆ addEffect()

void addEffect ( Effect object)
virtual

◆ addGeometry()

void addGeometry ( Geometry object)
virtual

Reimplemented in QTModelManager.

◆ addLayer()

void addLayer ( Model layer)
virtual

Reimplemented in QTModelManager.

◆ addMaterial()

void addMaterial ( Material object)
virtual

Reimplemented in QTModelManager.

◆ addModel()

void addModel ( Model object)
virtual

Reimplemented in QTModelManager.

◆ addScene()

void addScene ( Scene scene,
bool ignore_application_scene = false )
virtual

Reimplemented in QTModelManager.

◆ addSelection()

void addSelection ( const DesignSelection & object)
virtual

◆ addUpdateTarget()

void addUpdateTarget ( DesignObjectUpdateTarget * target)

◆ appendSelected()

void appendSelected ( Buffer< UUID > ids)
virtual

Reimplemented in QTModelManager.

◆ bounds()

Bounds< 3, fltp08 > bounds ( ) const

◆ boundsOfVisible()

Bounds< 3, fltp08 > boundsOfVisible ( ) const

◆ cleanupMemory()

void cleanupMemory ( Buffer< UUID > deleted_objects)

◆ clearAll()

void clearAll ( )
virtual

Reimplemented in QTModelManager.

◆ clearSelected()

void clearSelected ( )
virtual

Reimplemented in QTModelManager.

◆ colorByChannel()

void colorByChannel ( UUID target,
const DesignParameter & channel )

◆ commandLock()

WLock commandLock ( )

◆ commandManager()

DesignCommandManager * commandManager ( )
virtual

◆ createCameraMaterial()

Material createCameraMaterial ( UUID camera)

◆ createCameraModel()

Model createCameraModel ( UUID camera)

◆ createLayer()

Model createLayer ( )

◆ createMaterial()

Material createMaterial ( )

◆ createMesh()

Geometry createMesh ( )

◆ createModel()

Model createModel ( )

◆ defaultScene()

const Scene & defaultScene ( )
inline

◆ deletedObjects()

const Dictionary< UUID, DesignObject > & deletedObjects ( )
inline

◆ deleteObject()

void deleteObject ( UUID id)
virtual

Reimplemented in QTModelManager.

◆ designParameters()

Buffer< DesignParameter, uint04, ObjectAllocator< false > > designParameters ( ) const

◆ effect()

Effect effect ( const UUID & id,
bool allow_deleted = false ) const

◆ effectObjects()

const Dictionary< UUID, Effect > & effectObjects ( )
inline

◆ ensureLayerExistsInScene()

void ensureLayerExistsInScene ( const UUID & layer_id,
const UUID & scene_id )

◆ eraseModel()

void eraseModel ( UUID id)
virtual

Reimplemented in QTModelManager.

◆ executePendingCommands()

void executePendingCommands ( )
virtual

◆ findLayer() [1/2]

Model findLayer ( const String & layer,
bool use_translation = true ) const

◆ findLayer() [2/2]

Model findLayer ( const TranslatedString & layer) const

◆ finishCommand()

void finishCommand ( const DynamicPointer< DesignCommand > & command)
virtual

Reimplemented in QTModelManager.

◆ geometry()

Geometry geometry ( const UUID & id,
bool allow_deleted = false ) const

◆ geometryObjects()

const Dictionary< UUID, Geometry > & geometryObjects ( )
inline

◆ getAllSceneLayers()

const Dictionary< UUID, Model > & getAllSceneLayers ( const UUID & id) const

◆ getDescendentsOf()

Buffer< UUID > getDescendentsOf ( const Buffer< UUID > & model_ids)
virtual

◆ getInverseOf()

Buffer< UUID > getInverseOf ( const Buffer< UUID > & model_ids)
virtual

◆ getLayersByType() [1/2]

Buffer< Model > getLayersByType ( const Buffer< String > & types) const

◆ getLayersByType() [2/2]

Buffer< Model > getLayersByType ( const String & type) const

◆ getModelIDsByType()

Buffer< UUID > getModelIDsByType ( const String & type) const

◆ getModelsByID()

Buffer< Model > getModelsByID ( const Buffer< UUID > & ids) const

◆ getModelsByName()

Buffer< Model > getModelsByName ( const String & name) const

◆ getModelsByType() [1/2]

Buffer< Model > getModelsByType ( const Buffer< String > & types) const

◆ getModelsByType() [2/2]

Buffer< Model > getModelsByType ( const String & type) const

◆ getRootObjectIDs() [1/2]

Buffer< UUID > getRootObjectIDs ( bool include_app_owned = false) const

◆ getRootObjectIDs() [2/2]

Buffer< UUID > getRootObjectIDs ( UUID camera_id,
bool include_app_owned = false ) const

◆ getRootObjects() [1/2]

Buffer< Model > getRootObjects ( bool include_app_owned = false) const

◆ getRootObjects() [2/2]

Buffer< Model > getRootObjects ( UUID camera_id,
bool include_app_owned = false ) const

◆ getSelectionInfo() [1/2]

const DynamicPointer< DesignSelection > & getSelectionInfo ( const UUID & id)

◆ getSelectionInfo() [2/2]

const ConstPointer< DesignSelection > & getSelectionInfo ( const UUID & id) const

◆ hasEffect()

bool hasEffect ( const UUID & id) const

◆ hasGeometryID()

bool hasGeometryID ( const UUID & id) const

◆ hasLayerID() [1/2]

bool hasLayerID ( const UUID & id,
bool allow_deleted = false ) const

◆ hasLayerID() [2/2]

bool hasLayerID ( const UUID & id,
const UUID & scene_id ) const

◆ hasMaterialID()

bool hasMaterialID ( const UUID & id) const

◆ hasModelID()

bool hasModelID ( const UUID & id,
bool allow_deleted = false ) const

◆ hasObjectID()

bool hasObjectID ( const UUID & id,
bool allow_deleted = false ) const

◆ hasSceneID()

bool hasSceneID ( const UUID & id,
bool allow_deleted = false ) const

◆ hasSelectionInfo()

bool hasSelectionInfo ( const UUID & id) const

◆ invalidateStationVisuals()

void invalidateStationVisuals ( bool invalidate_visuals,
bool invalidate_font )

◆ isCommandLocked()

bool isCommandLocked ( ) const

◆ layer() [1/2]

Model layer ( const UUID & id,
bool allow_deleted = false ) const

◆ layer() [2/2]

Model layer ( const UUID & layer_id,
const UUID & scene_id,
bool allow_deleted = false ) const

◆ layerObjects()

const Dictionary< UUID, Dictionary< UUID, Model > > & layerObjects ( )
inline

◆ lockPtr()

const void * lockPtr ( ) const

◆ logManager()

LogManager * logManager ( ) const
virtual

Reimplemented in QTModelManager.

◆ material()

Material material ( const UUID & id,
bool allow_deleted = false ) const

◆ materialObjects()

const Dictionary< UUID, Material > & materialObjects ( )
inline

◆ model()

Model model ( const UUID & id,
bool allow_deleted = false ) const

◆ modelObjects()

const Dictionary< UUID, Model > & modelObjects ( )
inline

◆ modelOrLayer()

Model modelOrLayer ( const UUID & id,
bool allow_deleted = false ) const

◆ object()

DesignObject object ( const UUID & id) const

◆ objects()

const Dictionary< UUID, DesignObject > & objects ( )
inline

◆ postCommand()

void postCommand ( const DynamicPointer< DesignCommand > & command)
virtual

Reimplemented in QTModelManager.

◆ processSelection()

void processSelection ( SelectionInfo & info) const

◆ readLock() [1/3]

RLock readLock ( ) const

◆ readLock() [2/3]

RLock readLock ( const std::function< void()> & wait_callback) const

◆ readLock() [3/3]

RDesignLock readLock ( UUID id)

◆ refreshModel()

void refreshModel ( const Model & object)
virtual

◆ refreshScene()

void refreshScene ( UUID scene_id,
bool ignore_application_scene )
virtual

Reimplemented in QTModelManager.

◆ removeDeletedObject()

void removeDeletedObject ( UUID id)
inline

◆ removeUpdateTarget()

void removeUpdateTarget ( DesignObjectUpdateTarget * target)

◆ requestAutoSave()

void requestAutoSave ( )
virtual

◆ requestAutoSaveCheckpoint()

void requestAutoSaveCheckpoint ( )
virtual

◆ restoreModel()

Model restoreModel ( UUID id)
virtual

Reimplemented in QTModelManager.

◆ runCommand()

void runCommand ( const DynamicPointer< DesignCommand > & command)
virtual

Reimplemented in QTModelManager.

◆ scene()

Scene scene ( const UUID & id,
bool allow_deleted = false ) const

◆ sceneObjects()

const Dictionary< UUID, Scene > & sceneObjects ( )
inline

◆ selectEnclosed()

void selectEnclosed ( UUID selection_id)

◆ setActiveLayer()

void setActiveLayer ( UUID layer_id)
virtual

Reimplemented in QTModelManager.

◆ setActiveProject()

void setActiveProject ( UUID layer_id)
virtual

Reimplemented in QTModelManager.

◆ setSelected()

void setSelected ( Buffer< UUID > ids)
virtual

Reimplemented in QTModelManager.

◆ setSelectionEffect()

void setSelectionEffect ( SelectionEffect * effect)

◆ setupDefaultScene()

void setupDefaultScene ( )

◆ taskManager()

DesignTaskManager * taskManager ( ) const
virtual

Reimplemented in QTModelManager.

◆ tryCommandLock()

WLock tryCommandLock ( )

◆ tryReadLock() [1/2]

RLock tryReadLock ( const TimeSpan & span) const

◆ tryReadLock() [2/2]

RLock tryReadLock ( uint08 milliseconds = 10) const

◆ tryWriteLock() [1/2]

WLock tryWriteLock ( const TimeSpan & span)

◆ tryWriteLock() [2/2]

WLock tryWriteLock ( uint08 milliseconds = 10)

◆ update()

void update ( const Time & time,
const std::function< void()> & wait_callback )
virtual

Reimplemented in QTModelManager.

◆ updateEffects()

void updateEffects ( const Time & time,
const std::function< void()> & wait_callback )
protected

◆ updateModelTopLevel()

void updateModelTopLevel ( const Model & object)
virtual

Reimplemented in QTModelManager.

◆ updateTranslation()

void updateTranslation ( )

◆ visibleModels()

Buffer< UUID > visibleModels ( ) const

◆ writeLock() [1/3]

WLock writeLock ( )

◆ writeLock() [2/3]

WLock writeLock ( const std::function< void()> & wait_callback)

◆ writeLock() [3/3]

WDesignLock writeLock ( UUID id)

Member Data Documentation

◆ autosave_checkpoint_request_time

Resource<Time> autosave_checkpoint_request_time

◆ autosave_request_time

Resource<Time> autosave_request_time

◆ current_layer

Resource<UUID> current_layer

◆ focus_color

Resource<RGBColor> focus_color

◆ m_active_layer

UUID m_active_layer
protected

◆ m_active_project

UUID m_active_project
protected

◆ m_all_scene_objects

Dictionary<UUID, Scene> m_all_scene_objects
protected

◆ m_application_root_objects

Dictionary<UUID, Model> m_application_root_objects
protected

◆ m_camera_root

Dictionary<UUID, Model> m_camera_root
protected

◆ m_command_controller

DesignCommandManager* m_command_controller
protected

◆ m_default_scene

Scene m_default_scene
protected

◆ m_deleted_objects

Dictionary<UUID, DesignObject> m_deleted_objects
protected

◆ m_design_objects

Dictionary<UUID, DesignObject> m_design_objects
protected

◆ m_edit_controller

ModelEditController* m_edit_controller
protected

◆ m_effect_objects

Dictionary<UUID, Effect> m_effect_objects
protected

◆ m_erased_objects

Dictionary<UUID, UUID> m_erased_objects
protected

◆ m_geometry_objects

Dictionary<UUID, Geometry> m_geometry_objects
protected

◆ m_invalidate_station_visuals_listener

ResourceListener* m_invalidate_station_visuals_listener
protected

◆ m_language_change_listener

ResourceListener* m_language_change_listener
protected

◆ m_last_update_time

Time m_last_update_time
protected

◆ m_layer_objects

Dictionary<UUID, Dictionary<UUID, Model> > m_layer_objects
protected

◆ m_log_manager

LogManager* m_log_manager
mutableprotected

◆ m_material_objects

Dictionary<UUID, Material> m_material_objects
protected

◆ m_model_objects

Dictionary<UUID, Model> m_model_objects
protected

◆ m_model_root_objects

Dictionary<UUID, Model> m_model_root_objects
protected

◆ m_prefered_update_timespan

TimeSpan m_prefered_update_timespan
protected

◆ m_scene_objects

Dictionary<UUID, Scene> m_scene_objects
protected

◆ m_selection_controller

SelectionController* m_selection_controller
protected

◆ m_selection_effect

SelectionEffect* m_selection_effect
protected

◆ m_selection_info

Dictionary<UUID, DynamicPointer<DesignSelection> > m_selection_info
protected

◆ m_task_controller

DesignTaskManager* m_task_controller
mutableprotected

◆ m_update_language

bool m_update_language
protected

◆ m_update_station_font

bool m_update_station_font
protected

◆ m_update_station_visuals

bool m_update_station_visuals
protected

◆ m_update_targets

Buffer<DesignObjectUpdateTarget*> m_update_targets
protected

◆ m_uuid

UUID m_uuid
protected

◆ modified_time

Resource<Time> modified_time

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