SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
Go to the documentation of this file.
10 #ifndef smtk_model_Session_h
11 #define smtk_model_Session_h
17 #include "smtk/SharedPtr.h"
18 #include "smtk/SystemConfig.h"
20 #include "smtk/common/UUID.h"
46 typedef std::map<smtk::common::UUID, smtk::shared_ptr<Session>>
UUIDsToSessions;
47 typedef std::map<smtk::model::EntityRef, SessionInfoBits> DanglingEntities;
125 static std::string staticClassName() {
return "smtk::model::Session"; }
126 virtual std::string name()
const;
127 virtual std::string className()
const {
return Session::staticClassName(); }
133 bool onlyDangling =
true,
138 const DanglingEntities& danglingEntities()
const;
141 virtual int setup(
const std::string& optName,
const StringList& optVal);
150 bool ok = this->splitAttributes(from, to);
151 ok &= this->splitProperties(from, to);
156 bool ok = this->mergeAttributes(from, to);
157 ok &= this->mergeProperties(from, to);
168 virtual std::string defaultFileExtension(
const Model& model)
const;
179 void setResource(
Resource* resource);
183 int findOrAddRelatedEntities(
187 virtual int findOrAddCellAdjacencies(
195 virtual int findOrAddShellAdjacencies(
199 virtual int findOrAddUseAdjacencies(
211 virtual int findOrAddRelatedModels(
215 virtual int findOrAddRelatedGroups(
219 virtual int findOrAddRelatedInstances(
236 virtual SessionIOPtr createIODelegate(
const std::string& format);
238 DanglingEntities m_dangling;
246 #endif // smtk_model_Session_h
The main namespace for the Simulation Modeling Tool Kit (SMTK).
Definition: doc.h:33
@ SESSION_ENTITY_TYPE
Transcribe the Entity type.
Definition: Session.h:63
@ SESSION_NOTHING
Transcribe nothing.
Definition: Session.h:82
@ SESSION_STRING_PROPERTIES
String properties.
Definition: Session.h:68
A base class for bridging modelers into SMTK.
Definition: Session.h:118
@ SESSION_ENTITY_RELATIONS
Transcribe the Entity relationship vector.
Definition: Session.h:64
A entityref subclass that provides methods specific to models.
Definition: Model.h:30
Superclass for session-specific updates to arrangments of entities.
Definition: ArrangementHelper.h:29
std::vector< String > StringList
Use vectors of String objects for holding string properties on model entities.
Definition: StringData.h:32
Log messages for later presentation to a user or a file.
Definition: Logger.h:94
@ SESSION_USER_DEFINED_PROPERTIES
Remove user-defined as well as machine-generated properties.
Definition: Session.h:73
@ SESSION_EVERYTHING
Transcribe all information about the entity.
Definition: Session.h:87
@ SESSION_ARRANGEMENTS
Arrangement information for the relationships.
Definition: Session.h:65
smtk::shared_ptr< smtk::model::Entity > EntityPtr
Definition: PublicPointerDefs.h:423
@ SESSION_PROPERTIES
Transcribe all properties.
Definition: Session.h:86
@ SESSION_ENTITY_RECORD
Transcribe both entity type and relations.
Definition: Session.h:83
#define smtkCreateMacro(...)
Add static create() methods to a class.
Definition: SharedFromThis.h:173
#define smtkEnableSharedPtr(...)
An abbreviation for enabling shared pointers.
Definition: SharedFromThis.h:214
A entityref subclass with methods specific to cell entities.
Definition: CellEntity.h:30
Store information about solid models.
Definition: Resource.h:91
@ SESSION_ENTITY_ARRANGED
Transcribe the entity record and all arrangement information.
Definition: Session.h:84
A entityref subclass that provides methods specific to entity use records.
Definition: Instance.h:23
std::map< smtk::common::UUID, smtk::shared_ptr< smtk::model::Session > > UUIDsToSessions
Definition: PublicPointerDefs.h:395
A entityref subclass that provides methods specific to entity use records.
Definition: SessionRef.h:28
SessionInformation
Bit flags describing types of information sessiond to Resource.
Definition: Session.h:60
unsigned long SessionInfoBits
Bit-vector combinations of SessionInformation values for requesting information to transcribe.
Definition: Session.h:34
smtk::shared_ptr< smtk::model::Resource > ResourcePtr
Definition: PublicPointerDefs.h:419
A entityref subclass that provides methods specific to entity use records.
Definition: Group.h:27
#define smtkSuperclassMacro(...)
Add a typedef to the superclass of this class.
Definition: SharedFromThis.h:147
smtk::shared_ptr< smtk::model::SessionIO > SessionIOPtr
Definition: PublicPointerDefs.h:399
@ SESSION_TESSELLATION
Points and triangles used to render an entity.
Definition: Session.h:66
@ SESSION_EXHAUSTIVE
Erase all information about the entity, including user-specified.
Definition: Session.h:88
@ SESSION_FLOAT_PROPERTIES
Floating-point properties.
Definition: Session.h:67
A entityref subclass that provides methods specific to entity-use records.
Definition: UseEntity.h:53
A entityref subclass with methods specific to shell entities.
Definition: ShellEntity.h:33
Macros for dealing with shared-pointer classes.
#define smtkTypeMacroBase(...)
Add typedefs to a class for identifcation.
Definition: SharedFromThis.h:131
@ SESSION_INTEGER_PROPERTIES
Integer properties.
Definition: Session.h:69
std::set< smtk::model::EntityRef > EntityRefs
Definition: PublicPointerDefs.h:162
A lightweight entityref pointing to a model entity's resource.
Definition: EntityRef.h:112
@ SESSION_ATTRIBUTE_ASSOCIATIONS
Attribute associations.
Definition: Session.h:70