SMTK  @SMTK_VERSION@
Simulation Modeling Tool Kit
Public Member Functions | Protected Member Functions | List of all members
smtk::view::QueryFilterSubphraseGenerator Class Reference

Generate subphrases by querying the filter in ObjectGroupPhraseContent. More...

#include <QueryFilterSubphraseGenerator.h>

Inheritance diagram for smtk::view::QueryFilterSubphraseGenerator:
[legend]
Collaboration diagram for smtk::view::QueryFilterSubphraseGenerator:
[legend]

Public Member Functions

 smtkTypeMacro (smtk::view::QueryFilterSubphraseGenerator)
 
 smtkSuperclassMacro (smtk::view::SubphraseGenerator)
 
 smtkSharedPtrCreateMacro (smtk::view::SubphraseGenerator)
 
DescriptivePhrases subphrases (DescriptivePhrase::Ptr src) override
 Return a list of descriptive phrases that elaborate upon src.
 
- Public Member Functions inherited from smtk::view::SubphraseGenerator
 smtkTypeMacroBase (smtk::view::SubphraseGenerator)
 
 smtkCreateMacro (smtk::view::SubphraseGenerator)
 
virtual bool hasChildren (const DescriptivePhrase &src) const
 Return true if children would be generated for the Descriptive Phrase.
 
virtual smtk::resource::PersistentObjectSet parentObjects (const smtk::resource::PersistentObjectPtr &obj) const
 Return a set of parent Persistent Objects for this object. More...
 
bool setModel (PhraseModelPtr model)
 Set the phrase model used to adapt phrases to a user interface.
 
PhraseModelPtr model () const
 Return the phrase model (if any) used to adapt phrases to a user interface.
 
virtual DescriptivePhrasePtr createSubPhrase (const smtk::resource::PersistentObjectPtr &obj, const DescriptivePhrasePtr &parent, Path &childPath)
 Create a new Subphrase for an object which will be a child of parent and return the path to the phrase.
 
virtual void subphrasesForCreatedObjects (const smtk::resource::PersistentObjectArray &objects, const DescriptivePhrasePtr &localRoot, PhrasesByPath &resultingPhrases)
 Append subphrases and their paths that the given set of created objects implies. More...
 
virtual int directLimit () const
 The maximum number of subphrases to directly include before turning into a list. More...
 
virtual bool setDirectLimit (int val)
 Set the maximum number of direct children before a summary phrase is inserted. More...
 
virtual bool shouldOmitProperty (DescriptivePhrase::Ptr parent, smtk::resource::PropertyType ptype, const std::string &pname) const
 Should the property of the given type and name be omitted from presentation? More...
 
ManagerPtr manager () const
 SubphraseGenerators that are managed have a non-null pointer to their manager.
 
virtual void setSkipProperties (bool val)
 Get/Set whether entity properties will be skiped for subphrases. More...
 
virtual bool skipProperties () const
 Get/Set whether entity properties will be skiped for subphrases. More...
 
virtual void setSkipAttributes (bool val)
 Get/Set whether entity attributes will be skiped for subphrases. More...
 
virtual bool skipAttributes () const
 Get/Set whether entity attributes will be skiped for subphrases. More...
 

Protected Member Functions

Path indexOfObjectInParent (const smtk::resource::PersistentObjectPtr &obj, const smtk::view::DescriptivePhrasePtr &parent, const Path &parentPath) override
 
- Protected Member Functions inherited from smtk::view::SubphraseGenerator
virtual int findResourceLocation (smtk::resource::ResourcePtr rsrc, const DescriptivePhrase::Ptr &root) const
 
virtual bool findSortedLocation (Path &pathOut, smtk::attribute::AttributePtr attr, DescriptivePhrase::Ptr &phr, const DescriptivePhrase::Ptr &parent) const
 
virtual bool findSortedLocation (Path &pathOut, smtk::model::EntityPtr entity, DescriptivePhrase::Ptr &phr, const DescriptivePhrase::Ptr &parent) const
 
virtual bool findSortedLocation (Path &pathOut, smtk::mesh::ComponentPtr comp, DescriptivePhrase::Ptr &phr, const DescriptivePhrase::Ptr &parent) const
 
bool resourceHasChildren (const smtk::resource::ResourcePtr &rsrc) const
 Return true if the resource would cause subphrases to be generated.
 
bool modelEntityHasChildren (const smtk::model::EntityPtr &entity) const
 Return true if the model entity would cause subphrases to be generated.
 
void componentsOfResource (DescriptivePhrase::Ptr src, smtk::resource::ResourcePtr rsrc, DescriptivePhrases &result)
 Populate result with the top-level components of rsrc with src as their parent.
 
void itemsOfAttribute (DescriptivePhrase::Ptr src, smtk::attribute::AttributePtr att, DescriptivePhrases &result)
 Populate result with the active, public items of att with src as their parent.
 
void childrenOfModelEntity (DescriptivePhrase::Ptr src, smtk::model::EntityPtr modelEntity, DescriptivePhrases &result)
 Populate result with the children of modelEntity with src as their parent.
 
template<typename T >
PhraseListContentPtr addComponentPhrases (const T &components, DescriptivePhrase::Ptr parent, DescriptivePhrases &result, int mutability=static_cast< int >(smtk::view::PhraseContent::ContentType::TITLE)|static_cast< int >(smtk::view::PhraseContent::ContentType::COLOR), std::function< bool(const DescriptivePhrase::Ptr &, const DescriptivePhrase::Ptr &)> comparator=DescriptivePhrase::compareByTypeThenTitle)
 A templated helper for creating lists of components as subphrases. More...
 
template<typename T >
void filterModelEntityPhraseCandidates (T &ents)
 A template helper for filtering the model entity phrase candidates As a model entity could be marked as excluded from view presentation, this helper will update the container to respect this property. More...
 
template<typename T >
PhraseListContentPtr addModelEntityPhrases (const T &ents, DescriptivePhrase::Ptr parent, int limit, DescriptivePhrases &result, int mutability=static_cast< int >(smtk::view::PhraseContent::ContentType::TITLE)|static_cast< int >(smtk::view::PhraseContent::ContentType::COLOR), std::function< bool(const DescriptivePhrase::Ptr &, const DescriptivePhrase::Ptr &)> comparator=nullptr)
 A templated helper for the model-related utility methods.
 
void freeSubmodelsOfModel (DescriptivePhrase::Ptr src, const smtk::model::Model &mod, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void freeGroupsOfModel (DescriptivePhrase::Ptr src, const smtk::model::Model &mod, DescriptivePhrases &result)
 Add groups of mod to result with src as their parent.
 
void freeCellsOfModel (DescriptivePhrase::Ptr src, const smtk::model::Model &mod, DescriptivePhrases &result)
 Add free cells of mod to result with src as their parent.
 
void freeAuxiliaryGeometriesOfModel (DescriptivePhrase::Ptr src, const smtk::model::Model &mod, DescriptivePhrases &result)
 Add auxiliary geometry entities of mod to result with src as their parent.
 
void instancesOfModelEntity (DescriptivePhrase::Ptr src, const smtk::model::EntityRef &ent, DescriptivePhrases &result)
 Add instances of ent to result with src as their parent.
 
void cellOfModelUse (DescriptivePhrase::Ptr src, const smtk::model::UseEntity &ent, DescriptivePhrases &result)
 Add attributes associated with ent to result with src as their parent.
 
void boundingShellsOfModelUse (DescriptivePhrase::Ptr src, const smtk::model::UseEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void toplevelShellsOfModelUse (DescriptivePhrase::Ptr src, const smtk::model::UseEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void usesOfModelCell (DescriptivePhrase::Ptr src, const smtk::model::CellEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void inclusionsOfModelCell (DescriptivePhrase::Ptr src, const smtk::model::CellEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void boundingCellsOfModelCell (DescriptivePhrase::Ptr src, const smtk::model::CellEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void usesOfModelShell (DescriptivePhrase::Ptr src, const smtk::model::ShellEntity &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void membersOfModelGroup (DescriptivePhrase::Ptr src, const smtk::model::Group &grp, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void childrenOfModelAuxiliaryGeometry (DescriptivePhrase::Ptr src, const smtk::model::AuxiliaryGeometry &aux, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
void prototypeOfModelInstance (DescriptivePhrase::Ptr src, const smtk::model::Instance &ent, DescriptivePhrases &result)
 Model-entity utility methods. More...
 
template<typename T >
void PreparePath (T &result, const T &parentPath, int childIndex)
 Model-entity utility methods. More...
 
template<typename T >
int IndexFromTitle (const std::string &title, const T &phrases)
 Model-entity utility methods. More...
 

Additional Inherited Members

- Public Types inherited from smtk::view::SubphraseGenerator
using Path = std::vector< int >
 
using PhrasesByPath = std::multimap< Path, DescriptivePhrasePtr >
 
- Static Public Member Functions inherited from smtk::view::SubphraseGenerator
static std::string getType (const smtk::view::ConfigurationPtr &viewSpec)
 
static SubphraseGeneratorPtr create (const std::string &typeName, const smtk::view::ManagerPtr &manager)
 
- Public Attributes inherited from smtk::view::SubphraseGenerator
friend Manager
 
- Protected Attributes inherited from smtk::view::SubphraseGenerator
int m_directLimit
 
bool m_skipAttributes
 
bool m_skipProperties
 
WeakPhraseModelPtr m_model
 
WeakManagerPtr m_manager
 

Detailed Description

Generate subphrases by querying the filter in ObjectGroupPhraseContent.


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