SMTK  @SMTK_VERSION@
Simulation Modeling Tool Kit
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
smtk::session::polygon::Resource Class Reference
Inheritance diagram for smtk::session::polygon::Resource:
[legend]
Collaboration diagram for smtk::session::polygon::Resource:
[legend]

Public Member Functions

 smtkTypeMacro (smtk::session::polygon::Resource)
 
 smtkSharedPtrCreateMacro (smtk::resource::PersistentObject)
 
void setSession (const Session::Ptr &)
 
SessionPtr polygonSession ()
 Return a shared pointer to the session backing a polygon operator.
 
ConstSessionPtr polygonSession () const
 
void addStorage (const smtk::common::UUID &uid, smtk::session::polygon::internal::entity::Ptr storage)
 
bool removeStorage (const smtk::common::UUID &uid)
 
template<typename T >
T::Ptr findStorage (const smtk::common::UUID &uid)
 
template<typename T >
findOrAddStorage (const smtk::common::UUID &uid)
 
int nextModelNumber ()
 
- Public Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::model::Resource >
bool isOfType (const Resource::Index &index) const override
 given a resource index, return whether or not this resource is or is derived from the resource described by the index.
 
bool isOfType (const std::string &typeName) const override
 given a resource's unique name, return whether or not this resource is or is derived from the resource described by the name.
 
int numberOfGenerationsFromBase (const std::string &typeName) const override
 
 DerivedFrom (const DerivedFrom &)=delete
 
- Public Member Functions inherited from smtk::model::Resource
 smtkTypeMacro (smtk::model::Resource)
 
 smtkSharedPtrCreateMacro (smtk::resource::PersistentObject)
 
 Resource (Resource &&rhs)=default
 
const UUIDsToEntitiestopology () const
 
const UUIDsToTessellations & tessellations () const
 
const UUIDsToTessellations & analysisMesh () const
 
smtk::common::UUID modelOwningEntity (const smtk::common::UUID &uid) const
 Attempt to find a model owning the given entity.
 
smtk::common::UUID sessionOwningEntity (const smtk::common::UUID &uid) const
 Attempt to find a session owning the given entity.
 
void assignDefaultNames ()
 Assign a string property named "name" to every entity without one. More...
 
void assignDefaultNamesToModelChildren (const smtk::common::UUID &modelId)
 Assign a string property named "name" to every entity of a model without one. More...
 
std::string assignDefaultName (const smtk::common::UUID &uid)
 Assign a string property named "name" to the given entity. More...
 
std::string assignDefaultNameIfMissing (const smtk::common::UUID &uid)
 Assign a string property named "name" to the given entity. More...
 
SessionRef registerSession (SessionPtr session)
 Mark the start of a modeling session by registering the session with SMTK backing storage.
 
bool unregisterSession (SessionPtr session, bool expungeSession=true)
 Mark the end of a modeling session by removing its session. More...
 
SessionPtr sessionData (const smtk::model::SessionRef &sessRef) const
 Find a session given its session UUID (or nullptr).
 
template<typename Collection , typename Type >
Collection findEntitiesByTypeAndPropertyAs (const std::string &pname, const Type &pval)
 
template<typename Collection , typename Type >
Collection findEntitiesByTypeAndPropertyAs (const std::string &pname, const std::vector< Type > &pval)
 
template<typename Collection >
Collection entitiesMatchingFlagsAs (BitFlags flags, bool exactMatch=true)
 
template<typename T >
bool insertModelFaceWithOrientedOuterLoop (const smtk::common::UUID &faceId, const smtk::common::UUID &faceUseId, const smtk::common::UUID &loopId, const T &orderedEdgesWithOrientation)
 
template<typename T >
bool insertModelFaceOrientedInnerLoop (const smtk::common::UUID &loopId, const smtk::common::UUID &preExistingLoopId, const T &orderedEdgesWithOrientation)
 
template<typename T , typename U , typename V >
bool deleteEntities (T &entities, U &modified, V &expunged, bool debugLog)
 
smtk::io::Loggerlog ()
 
 Resource (smtk::resource::ManagerPtr=smtk::resource::ManagerPtr())
 Create a default, empty model resource.
 
 Resource (const smtk::common::UUID &uid, smtk::resource::ManagerPtr=smtk::resource::ManagerPtr())
 Create a default, empty model resource.
 
 Resource (shared_ptr< UUIDsToEntities > topology, shared_ptr< UUIDsToTessellations > tess, shared_ptr< UUIDsToTessellations > analysismesh, shared_ptr< UUIDsToAttributeAssignments > attribs, const smtk::common::UUID &uid, smtk::resource::ManagerPtr=smtk::resource::ManagerPtr())
 Create a model resource using the given storage instances.
 
 ~Resource () override
 Destroying a model resource requires us to release the default attribute resource..
 
UUIDsToEntitiestopology ()
 Remove all entities and properties from this object. Does not change id or emit signals.
 
UUIDsToTessellations & tessellations ()
 Remove all entities and properties from this object. Does not change id or emit signals.
 
UUIDsToTessellations & analysisMesh ()
 Remove all entities and properties from this object. Does not change id or emit signals.
 
bool setMeshTessellations (const smtk::mesh::ResourcePtr &)
 Remove all entities and properties from this object. Does not change id or emit signals.
 
smtk::mesh::ResourcePtr meshTessellations () const
 Remove all entities and properties from this object. Does not change id or emit signals.
 
void clear ()
 Remove all entities and properties from this object. Does not change id or emit signals.
 
const UUIDsToAttributeAssignmentsattributeAssignments () const
 Remove all entities and properties from this object. Does not change id or emit signals.
 
BitFlags type (const smtk::common::UUID &ofEntity) const
 Queries on entities belonging to the solid. More...
 
int dimension (const smtk::common::UUID &ofEntity) const
 Return the dimension of the manifold that the passed entity represents.
 
std::string name (const smtk::common::UUID &ofEntity) const
 Return a name for the given entity ID. More...
 
EntityPtr findEntity (const smtk::common::UUID &uid, bool trySessions=true) const
 Return the smtk::model::Entity associated with uid (or nullptr). More...
 
smtk::resource::ComponentPtr find (const smtk::common::UUID &uid) const override
 Remove all entities and properties from this object. Does not change id or emit signals.
 
std::function< bool(const smtk::resource::Component &)> queryOperation (const std::string &) const override
 Given a query string, return a functor that determines if a component is accepted by the query.
 
void visit (smtk::resource::Component::Visitor &) const override
 Remove all entities and properties from this object. Does not change id or emit signals.
 
virtual SessionInfoBits erase (const smtk::common::UUID &uid, SessionInfoBits flags=smtk::model::SESSION_EVERYTHING)
 Remove the entity with the given uid. More...
 
virtual SessionInfoBits erase (const EntityRef &entityref, SessionInfoBits flags=smtk::model::SESSION_EVERYTHING)
 A convenience method for erasing an entity from storage.
 
virtual SessionInfoBits erase (const EntityPtr &entityrec, SessionInfoBits flags=smtk::model::SESSION_EVERYTHING)
 A convenience method for erasing an entity from storage.
 
virtual SessionInfoBits eraseModel (const Model &entityref, SessionInfoBits flags=smtk::model::SESSION_EVERYTHING)
 A convenience method for erasing a model and its children. More...
 
SessionInfoBits hardErase (const EntityRef &eref, SessionInfoBits flags=smtk::model::SESSION_EVERYTHING)
 Erase records related to the entity with no clean or safety checks. More...
 
smtk::common::UUIDs bordantEntities (const smtk::common::UUID &ofEntity, int ofDimension=-2) const
 Return the (Dimension+1 or higher)-entities that are the immediate bordants of the passed entity. More...
 
smtk::common::UUIDs bordantEntities (const smtk::common::UUIDs &ofEntities, int ofDimension=-2) const
 Return the (Dimension+1 or higher)-entities that are the immediate bordants of any of the passed entities. More...
 
smtk::common::UUIDs boundaryEntities (const smtk::common::UUID &ofEntity, int ofDimension=-2) const
 Return the (Dimension-1 or lower)-entities that are the immediate boundary of the passed entity. More...
 
smtk::common::UUIDs boundaryEntities (const smtk::common::UUIDs &ofEntities, int ofDimension=-2) const
 Return the (Dimension-1 or lower)-entities that are the immediate boundary of any of the passed entities. More...
 
smtk::common::UUIDs lowerDimensionalBoundaries (const smtk::common::UUID &ofEntity, int lowerDimension)
 Return lower-dimensional boundaries of the passed d-dimensional entity. More...
 
smtk::common::UUIDs higherDimensionalBordants (const smtk::common::UUID &ofEntity, int higherDimension)
 Return higher-dimensional bordants of the passed d-dimensional entity. More...
 
smtk::common::UUIDs adjacentEntities (const smtk::common::UUID &ofEntity, int ofDimension)
 Return entities of the requested dimension that share a boundary relationship with the passed entity.
 
smtk::common::UUIDs entitiesMatchingFlags (BitFlags mask, bool exactMatch=true)
 Return all entities of the requested dimension that are present in the solid.
 
smtk::common::UUIDs entitiesOfDimension (int dim)
 Return all entities of the requested dimension that are present in the solid.
 
smtk::common::UUID unusedUUID ()
 Entity construction. More...
 
iter_type insertEntityOfTypeAndDimension (BitFlags entityFlags, int dim)
 Insert a new cell of the specified dimension, returning an iterator with a new, unique UUID.
 
iter_type insertEntity (EntityPtr cell)
 Insert the specified cell, returning an iterator. More...
 
iter_type setEntityOfTypeAndDimension (const smtk::common::UUID &uid, BitFlags entityFlags, int dim)
 Create and map a new cell of the given dimension to the given uid. More...
 
iter_type setEntity (EntityPtr cell)
 Map the specified cell c to the given uid. More...
 
smtk::common::UUID addEntityOfTypeAndDimension (BitFlags entityFlags, int dim)
 A wrappable version of InsertEntityOfTypeAndDimension.
 
smtk::common::UUID addEntity (EntityPtr cell)
 A wrappable version of InsertEntity.
 
smtk::common::UUID addEntityOfTypeAndDimensionWithUUID (const smtk::common::UUID &uid, BitFlags entityFlags, int dim)
 A wrappable version of SetEntityOfTypeAndDimension.
 
smtk::common::UUID addEntityWithUUID (const smtk::common::UUID &uid, EntityPtr cell)
 A wrappable version of setEntity. This will override the UUID in cell.
 
iter_type insertCellOfDimension (int dim)
 Shortcuts for inserting cells with default entity flags.
 
iter_type setCellOfDimension (const smtk::common::UUID &uid, int dim)
 Remove all entities and properties from this object. Does not change id or emit signals.
 
smtk::common::UUID addCellOfDimension (int dim)
 Remove all entities and properties from this object. Does not change id or emit signals.
 
smtk::common::UUID addCellOfDimensionWithUUID (const smtk::common::UUID &uid, int dim)
 Remove all entities and properties from this object. Does not change id or emit signals.
 
void insertEntityReferences (const UUIDWithEntityPtr &c)
 Given an entity c, ensure that all of its references contain a reference to it.
 
bool elideOneEntityReference (const UUIDWithEntityPtr &c, const smtk::common::UUID &r)
 Given an entity c and the ID of one of its related entities r, overwrite the occurrence of r in c's array of relations with an invalid UUID. More...
 
void elideEntityReferences (const UUIDWithEntityPtr &c)
 Given an entity c, ensure that all of its references contain no reference to it. More...
 
void removeEntityReferences (const UUIDWithEntityPtr &c)
 Given an entity c, ensure that all of its references contain no reference to it.
 
virtual void addToGroup (const smtk::common::UUID &groupId, const smtk::common::UUIDs &uids)
 Add entities (specified by their uids) to the given group (groupId). More...
 
void setFloatProperty (const smtk::common::UUID &entity, const std::string &propName, smtk::model::Float propValue)
 
void setFloatProperty (const smtk::common::UUID &entity, const std::string &propName, const smtk::model::FloatList &propValue)
 
smtk::model::FloatList const & floatProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
smtk::model::FloatList & floatProperty (const smtk::common::UUID &entity, const std::string &propName)
 
bool hasFloatProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
bool removeFloatProperty (const smtk::common::UUID &entity, const std::string &propName)
 
void setStringProperty (const smtk::common::UUID &entity, const std::string &propName, const smtk::model::String &propValue)
 
void setStringProperty (const smtk::common::UUID &entity, const std::string &propName, const smtk::model::StringList &propValue)
 
smtk::model::StringList const & stringProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
smtk::model::StringListstringProperty (const smtk::common::UUID &entity, const std::string &propName)
 
bool hasStringProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
bool removeStringProperty (const smtk::common::UUID &entity, const std::string &propName)
 
void setIntegerProperty (const smtk::common::UUID &entity, const std::string &propName, smtk::model::Integer propValue)
 
void setIntegerProperty (const smtk::common::UUID &entity, const std::string &propName, const smtk::model::IntegerList &propValue)
 
smtk::model::IntegerList const & integerProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
smtk::model::IntegerList & integerProperty (const smtk::common::UUID &entity, const std::string &propName)
 
bool hasIntegerProperty (const smtk::common::UUID &entity, const std::string &propName) const
 
bool removeIntegerProperty (const smtk::common::UUID &entity, const std::string &propName)
 
bool closeSession (const SessionRef &sess)
 Unregister a session from the model resource.
 
SessionRefs sessions () const
 Return an array of all the sessions this resource owns.
 
Vertex insertVertex (const smtk::common::UUID &uid)
 Add a vertex to the resource (without any relationships) at the given uid.
 
Edge insertEdge (const smtk::common::UUID &uid)
 Add an edge to the resource (without any relationships) at the given uid.
 
Face insertFace (const smtk::common::UUID &uid)
 Add a face to the resource (without any relationships) at the given uid.
 
Volume insertVolume (const smtk::common::UUID &uid)
 Add a volume to the resource (without any relationships) at the given uid.
 
Vertex addVertex ()
 Add an edge to the resource (without any relationships)
 
Edge addEdge ()
 Add an edge to the resource (without any relationships)
 
Face addFace ()
 Add a face to the resource (without any relationships) More...
 
Volume addVolume ()
 Add a volume to the resource (without any relationships)
 
VertexUse insertVertexUse (const smtk::common::UUID &uid)
 Insert a VertexUse at the specified uid.
 
VertexUse setVertexUse (const smtk::common::UUID &uid, const Vertex &src, int sense)
 Create a VertexUse with the specified uid and replace src's VertexUse.
 
EdgeUse insertEdgeUse (const smtk::common::UUID &uid)
 Insert a EdgeUse at the specified uid.
 
EdgeUse setEdgeUse (const smtk::common::UUID &uid, const Edge &src, int sense, Orientation o)
 Create a EdgeUse with the specified uid and replace src's EdgeUse.
 
FaceUse insertFaceUse (const smtk::common::UUID &uid)
 Insert a FaceUse at the specified uid.
 
FaceUse setFaceUse (const smtk::common::UUID &uid, const Face &src, int sense, Orientation o)
 Create a FaceUse with the specified uid and replace src's FaceUse.
 
VolumeUse insertVolumeUse (const smtk::common::UUID &uid)
 Insert a VolumeUse at the specified uid.
 
VolumeUse setVolumeUse (const smtk::common::UUID &uid, const Volume &src)
 Create a VolumeUse with the specified uid and replace src's VolumeUse.
 
VertexUse addVertexUse ()
 Add a vertex-use to the resource (without any relationships)
 
VertexUse addVertexUse (const Vertex &src, int sense)
 Find or add a vertex-use to the resource with a relationship back to a vertex.
 
EdgeUse addEdgeUse ()
 Add an edge-use to the resource (without any relationships)
 
EdgeUse addEdgeUse (const Edge &src, int sense, Orientation o)
 Find or add a edge-use to the resource with a relationship back to a edge.
 
FaceUse addFaceUse ()
 Add a face-use to the resource (without any relationships)
 
FaceUse addFaceUse (const Face &src, int sense, Orientation o)
 Find or add a face-use to the resource with a relationship back to a face.
 
VolumeUse addVolumeUse ()
 Add a volume-use to the resource (without any relationships)
 
VolumeUse addVolumeUse (const Volume &src)
 Find or add a volume-use to the resource with a relationship back to a volume.
 
Chain insertChain (const smtk::common::UUID &uid)
 Insert a Chain at the specified uid.
 
Chain setChain (const smtk::common::UUID &uid, const EdgeUse &use)
 Find or add a chain to the resource with a relationship back to its owning edge-use.
 
Chain setChain (const smtk::common::UUID &uid, const Chain &parent)
 Find or add a chain to the resource with a relationship back to its owning chain.
 
Loop insertLoop (const smtk::common::UUID &uid)
 Insert a Loop at the specified uid.
 
Loop setLoop (const smtk::common::UUID &uid, const FaceUse &use)
 Find or add a chain to the resource with a relationship back to its owning face-use.
 
Loop setLoop (const smtk::common::UUID &uid, const Loop &parent)
 Find or add a chain to the resource with a relationship back to its owning loop.
 
Shell insertShell (const smtk::common::UUID &uid)
 Insert a Shell at the specified uid.
 
Shell setShell (const smtk::common::UUID &uid, const VolumeUse &use)
 Find or add a chain to the resource with a relationship back to its owning volume-use.
 
Shell setShell (const smtk::common::UUID &uid, const Shell &parent)
 Find or add a chain to the resource with a relationship back to its owning shell.
 
Chain addChain ()
 Add a 0/1-d shell (a vertex chain) to the resource (without any relationships)
 
Chain addChain (const EdgeUse &)
 Add a 0/1-d shell (a vertex chain) to the resource with a relation to its edge use.
 
Chain addChain (const Chain &)
 Add a 0/1-d shell (a vertex chain) to the resource with a relation to its edge use.
 
Loop addLoop ()
 Add a 1/2-d shell (an edge loop) to the resource (without any relationships)
 
Loop addLoop (const FaceUse &)
 Add a 1/2-d shell (an edge loop) to the resource with a relation to its parent face use.
 
Loop addLoop (const Loop &)
 Add a 1/2-d shell (an edge loop) to the resource with a relation to its parent loop.
 
Shell addShell ()
 Add a 2/3-d shell (a face-shell) to the resource (without any relationships)
 
Shell addShell (const Volume &src)
 A convenience method to find or create a volume use for the volume plus a shell.
 
Shell addShell (const VolumeUse &src)
 Add a 2/3-d shell (an face shell) to the resource with a relation to its volume.
 
Group insertGroup (const smtk::common::UUID &uid, int extraFlags=0, const std::string &name=std::string())
 Add an entity group to the resource (without any relationships). More...
 
Group addGroup (int extraFlags=0, const std::string &name=std::string())
 Add a group, creating a new UUID in the process. More...
 
AuxiliaryGeometry insertAuxiliaryGeometry (const smtk::common::UUID &uid, int dim=-1)
 Add auxiliary geometry (of the given dim, which may be -1) to the resource with the specified uid.
 
AuxiliaryGeometry addAuxiliaryGeometry (int dim=-1)
 Add auxiliary geometry (of the given dim, which may be -1) to the resource.
 
AuxiliaryGeometry addAuxiliaryGeometry (const Model &parent, int dim=-1)
 Add auxiliary geometry (of the given dim, which may be -1) to the resource, embedded in its parent.
 
AuxiliaryGeometry addAuxiliaryGeometry (const AuxiliaryGeometry &parent, int dim=-1)
 Add auxiliary geometry (of the given dim, which may be -1) to the resource, embedded in its parent.
 
Model insertModel (const smtk::common::UUID &uid, int parametricDim=3, int embeddingDim=3, const std::string &name=std::string())
 Add a model to the resource. More...
 
Model addModel (int parametricDim=3, int embeddingDim=3, const std::string &name=std::string())
 Add a model, creating a new UUID at the time. More...
 
Instance addInstance ()
 Add an instance of some model entity to the resource. More...
 
Instance addInstance (const EntityRef &instanceOf)
 Add an instance with the given prototype to the resource. More...
 
EntityRefArray findEntitiesByProperty (const std::string &pname, Integer pval)
 Find entities with an integer property named pname whose value is the single value pval.
 
EntityRefArray findEntitiesByProperty (const std::string &pname, Float pval)
 Find entities with a floating-point property named pname whose value is the single value pval.
 
EntityRefArray findEntitiesByProperty (const std::string &pname, const std::string &pval)
 Find entities with a string property named pname whose value is the single value pval.
 
EntityRefArray findEntitiesByProperty (const std::string &pname, const IntegerList &pval)
 Find entities with an integer property named pname whose every value matches the array pval.
 
EntityRefArray findEntitiesByProperty (const std::string &pname, const FloatList &pval)
 Find entities with a floating-point property named pname whose every value matches the array pval.
 
EntityRefArray findEntitiesByProperty (const std::string &pname, const StringList &pval)
 Find entities with a string property named pname whose every value matches the array pval.
 
EntityRefArray findEntitiesOfType (BitFlags flags, bool exactMatch=true)
 Find entities whose type matches the given flags. More...
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, long pval)
 Return entities with a property named pname whose values match the given pval.
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, const std::vector< long > &pval)
 Return entities with a property named pname whose values match the given pval.
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, Float pval)
 Return entities with a property named pname whose values match the given pval.
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, const std::vector< double > &pval)
 Return entities with a property named pname whose values match the given pval.
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, const std::string &pval)
 Return entities with a property named pname whose values match the given pval.
 
template<typename Collection >
Collection findEntitiesByPropertyAs (const std::string &pname, const std::vector< std::string > &pval)
 Return entities with a property named pname whose values match the given pval.
 
tess_iter_type setTessellation (const smtk::common::UUID &cellId, const Tessellation &geom, int analysis=0, int *gen=nullptr)
 Set the tessellation information and for a given cellId. More...
 
tess_iter_type setTessellationAndBoundingBox (const smtk::common::UUID &cellId, const Tessellation &geom, int analysis=0, int *gen=nullptr)
 Set the tessellation information and bounding box for a given cellId. More...
 
bool setBoundingBox (const smtk::common::UUID &cellId, const std::vector< double > &coords, int providedBBox=0)
 set the bounding box of a model entity given entityId and coords. More...
 
bool removeTessellation (const smtk::common::UUID &cellId, bool removeGen=false)
 Remove the tessellation of the given entityId. More...
 
int arrangeEntity (const smtk::common::UUID &entityId, ArrangementKind, const Arrangement &arr, int index=-1)
 Add or replace information about the arrangement of an entity. More...
 
int unarrangeEntity (const smtk::common::UUID &entityId, ArrangementKind, int index, bool removeIfLast=false)
 Remove an arrangement from an entity, and optionally the entity itself. More...
 
bool clearArrangements (const smtk::common::UUID &entityId)
 Erase all arrangements for the given entityId. More...
 
const ArrangementshasArrangementsOfKindForEntity (const smtk::common::UUID &cellId, ArrangementKind) const
 This is a const version of hasArrangementsOfKindForEntity().
 
ArrangementshasArrangementsOfKindForEntity (const smtk::common::UUID &cellId, ArrangementKind)
 Returns true when the given entity has any arrangements of the given kind (otherwise false). More...
 
ArrangementsarrangementsOfKindForEntity (const smtk::common::UUID &cellId, ArrangementKind)
 Return an array of arrangements of the given kind for the given entity. More...
 
const ArrangementfindArrangement (const smtk::common::UUID &entityId, ArrangementKind kind, int index) const
 Retrieve arrangement information for a cell. More...
 
ArrangementfindArrangement (const smtk::common::UUID &entityId, ArrangementKind kind, int index)
 Retrieve arrangement information for an entity. More...
 
int findArrangementInvolvingEntity (const smtk::common::UUID &entityId, ArrangementKind kind, const smtk::common::UUID &involved) const
 Find an arrangement of type kind that relates entityId to involvedEntity. More...
 
bool findDualArrangements (const smtk::common::UUID &entityId, ArrangementKind kind, int index, ArrangementReferences &duals) const
 Find the inverse of the given arrangement, if it exists. More...
 
bool addDualArrangement (const smtk::common::UUID &parent, const smtk::common::UUID &child, ArrangementKind kind, int sense, Orientation orientation)
 A method to add bidirectional arrangements between a parent and child.
 
int findCellHasUseWithSense (const smtk::common::UUID &cellId, const smtk::common::UUID &use, int sense) const
 Find a particular arrangement: a cell's HAS_USE with a given sense. More...
 
std::set< int > findCellHasUsesWithOrientation (const smtk::common::UUID &cellId, Orientation orient) const
 Find HAS_USE arrangements of a cell with a given orientation. More...
 
smtk::common::UUID cellHasUseOfSenseAndOrientation (const smtk::common::UUID &cell, int sense, Orientation o) const
 Return the UUID of a use record for the given cell and sense, or nullptr if it does not exist.
 
smtk::common::UUID findCreateOrReplaceCellUseOfSenseAndOrientation (const smtk::common::UUID &cell, int sense, Orientation o, const smtk::common::UUID &replacement=smtk::common::UUID::null())
 Find a use record for the given cell and sense, creating one if it does not exist or replacing it if replacement is non-nullptr.
 
smtk::common::UUIDs useOrShellIncludesShells (const smtk::common::UUID &cellUseOrShell) const
 Return the UUIDs of all shells included by the given cell-use or shell. More...
 
smtk::common::UUID createIncludedShell (const smtk::common::UUID &cellUseOrShell)
 Add a new shell to the specified useOrShell entity as an inclusion. More...
 
bool findOrAddIncludedShell (const smtk::common::UUID &parentUseOrShell, const smtk::common::UUID &shellToInclude)
 Add a shell to parentUseOrShell as an inclusion unless it already exists. More...
 
bool findOrAddUseToShell (const smtk::common::UUID &shell, const smtk::common::UUID &use)
 Add a cell-use to a shell if it is not already contained in the shell. More...
 
bool findOrAddInclusionToCellOrModel (const smtk::common::UUID &cell, const smtk::common::UUID &inclusion)
 Add an entity to a cell as a geometric inclusion. More...
 
bool findOrAddEntityToGroup (const smtk::common::UUID &grp, const smtk::common::UUID &ent)
 Add an entity as a subset of a group. More...
 
smtk::resource::ResourceSet associations () const
 Find entities with an integer property named pname whose value is the single value pval.
 
bool associate (const smtk::resource::ResourcePtr &resource)
 Find entities with an integer property named pname whose value is the single value pval.
 
bool disassociate (const smtk::resource::ResourcePtr &resource)
 Find entities with an integer property named pname whose value is the single value pval.
 
bool hasAttribute (const smtk::common::UUID &attribId, const smtk::common::UUID &toEntity)
 Report whether an entity has been assigned an attribute.
 
bool associateAttribute (smtk::attribute::ResourcePtr attResource, const smtk::common::UUID &attribId, const smtk::common::UUID &toEntity)
 Assign an attribute to an entity. More...
 
bool disassociateAttribute (smtk::attribute::ResourcePtr attResource, const smtk::common::UUID &attribId, const smtk::common::UUID &fromEntity, bool reverse=true)
 Unassign an attribute from an entity.
 
bool insertEntityAssociations (const EntityRef &modelEntity, std::set< smtk::attribute::AttributePtr > &associations)
 Insert the attributes associated with modelEntity into the associations set. More...
 
std::set< smtk::attribute::AttributePtrassociations (const EntityRef &modelEntity)
 Report whether an entity has been assigned an attribute.
 
void observe (ResourceEventType event, ConditionCallback functionHandle, void *callData)
 Request notification from this resource instance when event occurs.
 
void observe (ResourceEventType event, OneToOneCallback functionHandle, void *callData)
 Request notification from this resource instance when event occurs.
 
void observe (ResourceEventType event, OneToManyCallback functionHandle, void *callData)
 Request notification from this resource instance when event occurs.
 
void unobserve (ResourceEventType event, ConditionCallback functionHandle, void *callData)
 Decline further notification from this resource instance when event occurs.
 
void unobserve (ResourceEventType event, OneToOneCallback functionHandle, void *callData)
 Decline further notification from this resource instance when event occurs.
 
void unobserve (ResourceEventType event, OneToManyCallback functionHandle, void *callData)
 Decline further notification from this resource instance when event occurs.
 
void trigger (ResourceEventType event, const smtk::model::EntityRef &src)
 Called by this Resource instance or EntityRef instances referencing it when event occurs.
 
void trigger (ResourceEventType event, const smtk::model::EntityRef &src, const smtk::model::EntityRef &related)
 Called by this Resource instance or EntityRef instances referencing it when event occurs.
 
void trigger (ResourceEventType event, const smtk::model::EntityRef &src, const smtk::model::EntityRefArray &related)
 Called by this Resource instance or EntityRef instances referencing it when event occurs.
 
- Public Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::geometry::Resource >
 DerivedFrom (const DerivedFrom &)=delete
 
- Public Member Functions inherited from smtk::geometry::Resource
 smtkTypeMacro (smtk::geometry::Resource)
 
 smtkSuperclassMacro (smtk::resource::DerivedFrom< Resource, smtk::resource::Resource >)
 
 smtkSharedFromThisMacro (smtk::resource::PersistentObject)
 
std::unique_ptr< Geometry > & geometry (const Backend &backend)
 Given a backend, return a provider of geometry for that backend. More...
 
std::unique_ptr< Geometry > & geometry ()
 Return the first geometry provider (for any backend). More...
 
void visitGeometry (std::function< void(std::unique_ptr< Geometry > &)> visitor)
 Visit all existing geometry providers for this resource. More...
 
 Resource (Resource &&)=default
 
- Public Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::resource::Resource >
bool isOfType (const Resource::Index &index) const override
 given a resource index, return whether or not this resource is or is derived from the resource described by the index.
 
bool isOfType (const std::string &typeName) const override
 given a resource's unique name, return whether or not this resource is or is derived from the resource described by the name.
 
int numberOfGenerationsFromBase (const std::string &typeName) const override
 
 DerivedFrom (const DerivedFrom &)=delete
 
- Public Member Functions inherited from smtk::resource::Resource
 smtkTypeMacro (smtk::resource::Resource)
 
 smtkSuperclassMacro (smtk::resource::PersistentObject)
 
 smtkSharedFromThisMacro (smtk::resource::PersistentObject)
 
virtual Index index () const
 index is a compile-time intrinsic of the derived resource; as such, it cannot be set.
 
template<class ResourceType >
bool isOfType () const
 given a resource type, return whether or not this resource is or is derived from the resource described by the index.
 
const smtk::common::UUIDid () const override
 id and location are run-time intrinsics of the derived resource; we need to allow the user to reset these values.
 
const std::string & location () const
 
bool setId (const smtk::common::UUID &myID) override
 Assign an ID to this object (used by readers; not for arbitrary reuse). More...
 
bool setLocation (const std::string &location)
 
std::string name () const override
 Return the user-assigned name of the resource. More...
 
bool setName (const std::string &name)
 
bool isNameSet ()
 
virtual bool clean () const
 Indicate whether the resource is in sync with its location. More...
 
void setClean (bool state=true)
 
void setMarkedForRemoval (bool val)
 Mark the resource to indicate it is about to removed (meaning it is being removed from memory not necessarily for deletion)
 
virtual bool isMarkedForRemoval () const
 Return whether the object is marked for removal.
 
ManagerPtr manager () const
 Resources that are managed have a non-null pointer to their manager.
 
virtual Componentcomponent (const smtk::common::UUID &compId) const
 Given a component's UUID, return a raw pointer to the component.
 
template<typename ComponentType >
ComponentType * componentAs (const smtk::common::UUID &uuid) const
 A templated version of component() that casts its result to a type. More...
 
virtual void visit (std::function< void(const ComponentPtr &)> &v) const =0
 visit all components in a resource.
 
ComponentSet filter (const std::string &queryString) const
 
template<typename Collection >
Collection filterAs (const std::string &queryString) const
 given a a std::string describing a query and a type of container, return a set of components that satisfy both. More...
 
Linkslinks () override
 
const Linkslinks () const override
 
Propertiesproperties () override
 
const Propertiesproperties () const override
 
const Queriesqueries () const
 
Queriesqueries ()
 
Locklock (Key()) const
 classes that are granted permission to the key may retrieve the resource's lock.
 
LockType locked () const
 Anyone can query whether or not the resource is locked.
 
 Resource (Resource &&) noexcept
 
- Public Member Functions inherited from smtk::resource::PersistentObject
 smtkTypeMacroBase (smtk::resource::PersistentObject)
 
template<typename T >
T::Ptr as ()
 Attempt to cast this object to a subclass.
 
template<typename T >
T::ConstPtr as () const
 Attempt to cast this object to a subclass.
 

Protected Member Functions

 Resource (const smtk::common::UUID &, smtk::resource::ManagerPtr manager=nullptr)
 
 Resource (smtk::resource::ManagerPtr manager=nullptr)
 
- Protected Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::model::Resource >
 DerivedFrom (T &&... all)
 Forward all constructor arguments to the parent class.
 
 DerivedFrom (DerivedFrom &&rhs) noexcept=default
 
- Protected Member Functions inherited from smtk::model::Resource
void assignDefaultNamesWithOwner (const UUIDWithEntityPtr &irec, const smtk::common::UUID &owner, const std::string &ownersName, std::set< smtk::common::UUID > &remaining, bool nokids)
 
std::string assignDefaultName (const smtk::common::UUID &uid, BitFlags entityFlags)
 
IntegerList & entityCounts (const smtk::common::UUID &modelId, BitFlags entityFlags)
 Return a reference to the modelId's counter array associated with the given entityFlags.
 
void prepareForEntity (std::pair< smtk::common::UUID, EntityPtr > &entry)
 Initialize storage outside of the topology() table for a new entity. More...
 
smtk::common::UUID modelOwningEntityRecursive (const smtk::common::UUID &uid, std::set< smtk::common::UUID > &visited) const
 Internal method used by modelOwningEntity to prevent infinite recursion.
 
smtk::common::UUID sessionOwningEntityRecursive (const smtk::common::UUID &uid, std::set< smtk::common::UUID > &visited) const
 Attempt to find a session owning the given entity.
 
- Protected Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::geometry::Resource >
 DerivedFrom (T &&... all)
 Forward all constructor arguments to the parent class.
 
 DerivedFrom (DerivedFrom &&rhs) noexcept=default
 
- Protected Member Functions inherited from smtk::geometry::Resource
 Resource (const smtk::common::UUID &myID, smtk::resource::ManagerPtr manager)
 
 Resource (const smtk::common::UUID &myID)
 
 Resource (smtk::resource::ManagerPtr manager=nullptr)
 
- Protected Member Functions inherited from smtk::resource::DerivedFrom< Resource, smtk::resource::Resource >
 DerivedFrom (T &&... all)
 Forward all constructor arguments to the parent class.
 
 DerivedFrom (DerivedFrom &&rhs) noexcept=default
 
- Protected Member Functions inherited from smtk::resource::Resource
 Resource (const smtk::common::UUID &, ManagerPtr manager=nullptr)
 
 Resource (ManagerPtr manager=nullptr)
 

Protected Attributes

Session::Ptr m_session
 
- Protected Attributes inherited from smtk::model::Resource
smtk::shared_ptr< UUIDsToEntitiesm_topology
 
smtk::shared_ptr< UUIDsToTessellations > m_tessellations
 
smtk::shared_ptr< UUIDsToTessellations > m_analysisMesh
 
smtk::shared_ptr< UUIDsToAttributeAssignmentsm_attributeAssignments
 
smtk::shared_ptr< UUIDsToSessionsm_sessions
 
WeakResourceSet m_attributeResources
 
smtk::shared_ptr< Sessionm_defaultSession
 
IntegerList m_globalCounters
 
std::set< ConditionTriggerm_conditionTriggers
 
std::set< OneToOneTriggerm_oneToOneTriggers
 
std::set< OneToManyTriggerm_oneToManyTriggers
 
- Protected Attributes inherited from smtk::resource::Resource
WeakManagerPtr m_manager
 

Additional Inherited Members

- Public Types inherited from smtk::resource::DerivedFrom< Resource, smtk::model::Resource >
typedef smtk::model::Resource ParentResource
 
- Public Types inherited from smtk::model::Resource
typedef UUIDsToEntities storage_type
 
typedef storage_type::iterator iter_type
 
typedef UUIDsToTessellations::iterator tess_iter_type
 
typedef smtk::geometry::Resource ParentResource
 
- Public Types inherited from smtk::resource::DerivedFrom< Resource, smtk::geometry::Resource >
typedef smtk::geometry::Resource ParentResource
 
- Public Types inherited from smtk::resource::DerivedFrom< Resource, smtk::resource::Resource >
typedef smtk::resource::Resource ParentResource
 
- Public Types inherited from smtk::resource::Resource
typedef std::size_t Index
 
typedef smtk::resource::Metadata Metadata
 
typedef detail::ResourceLinks Links
 
typedef detail::ResourceProperties Properties
 
typedef query::Queries Queries
 
- Static Public Member Functions inherited from smtk::model::Resource
static std::string shortUUIDName (const smtk::common::UUID &uid, BitFlags entityFlags)
 
- Static Public Attributes inherited from smtk::resource::DerivedFrom< Resource, smtk::model::Resource >
static const Resource::Index type_index
 A static index for this resource type. More...
 
- Static Public Attributes inherited from smtk::model::Resource
static constexpr smtk::resource::Links::RoleType AssociationRole = -1
 
static constexpr smtk::resource::Links::RoleType TessellationRole = -2
 
- Static Public Attributes inherited from smtk::resource::DerivedFrom< Resource, smtk::geometry::Resource >
static const Resource::Index type_index
 A static index for this resource type. More...
 
- Static Public Attributes inherited from smtk::resource::DerivedFrom< Resource, smtk::resource::Resource >
static const Resource::Index type_index
 A static index for this resource type. More...
 
- Static Public Attributes inherited from smtk::resource::Resource
static const Resource::Index type_index = std::type_index(typeid(Resource)).hash_code()
 
- Protected Types inherited from smtk::model::Resource
typedef std::owner_less< smtk::attribute::WeakResourcePtrResourceLessThan
 
typedef std::set< smtk::attribute::WeakResourcePtr, ResourceLessThan > WeakResourceSet
 

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