Developer Documentation
OpenVolumeMesh::ResourceManager Class Referenceabstract
Inheritance diagram for OpenVolumeMesh::ResourceManager:
OpenVolumeMesh::TopologyKernel OpenVolumeMesh::HexahedralMeshTopologyKernel OpenVolumeMesh::TetrahedralMeshTopologyKernel

Public Types

typedef std::vector< BaseProperty * > Properties
 

Public Member Functions

 ResourceManager (const ResourceManager &other)
 
 ResourceManager (ResourceManager &&other)
 
ResourceManageroperator= (const ResourceManager &other)
 
ResourceManageroperator= (ResourceManager &&other)
 
void resize_vprops (size_t _nv)
 Change size of stored vertex properties.
 
void resize_eprops (size_t _ne)
 Change size of stored edge properties.
 
void resize_fprops (size_t _nf)
 Change size of stored face properties.
 
void resize_cprops (size_t _nc)
 Change size of stored cell properties.
 
void clear_vertex_props ()
 
void clear_edge_props ()
 
void clear_halfedge_props ()
 
void clear_face_props ()
 
void clear_halfface_props ()
 
void clear_cell_props ()
 
void clear_mesh_props ()
 
virtual size_t n_vertices () const =0
 Get number of vertices in mesh.
 
virtual size_t n_edges () const =0
 Get number of edges in mesh.
 
virtual size_t n_halfedges () const =0
 Get number of halfedges in mesh.
 
virtual size_t n_faces () const =0
 Get number of faces in mesh.
 
virtual size_t n_halffaces () const =0
 Get number of halffaces in mesh.
 
virtual size_t n_cells () const =0
 Get number of cells in mesh.
 
template<typename T , typename EntityTag >
PropertyTT< T, EntityTag > request_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
VertexPropertyT< T > request_vertex_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
EdgePropertyT< T > request_edge_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
HalfEdgePropertyT< T > request_halfedge_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
FacePropertyT< T > request_face_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
HalfFacePropertyT< T > request_halfface_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
CellPropertyT< T > request_cell_property (const std::string &_name=std::string(), const T _def=T())
 
template<class T >
MeshPropertyT< T > request_mesh_property (const std::string &_name=std::string(), const T _def=T())
 
size_t n_vertex_props () const
 
size_t n_edge_props () const
 
size_t n_halfedge_props () const
 
size_t n_face_props () const
 
size_t n_halfface_props () const
 
size_t n_cell_props () const
 
size_t n_mesh_props () const
 
template<typename T , class EntityTag >
void set_persistent (PropertyTT< T, EntityTag > &_prop, bool _flag=true)
 
Properties::const_iterator vertex_props_begin () const
 
Properties::const_iterator vertex_props_end () const
 
Properties::const_iterator edge_props_begin () const
 
Properties::const_iterator edge_props_end () const
 
Properties::const_iterator halfedge_props_begin () const
 
Properties::const_iterator halfedge_props_end () const
 
Properties::const_iterator face_props_begin () const
 
Properties::const_iterator face_props_end () const
 
Properties::const_iterator halfface_props_begin () const
 
Properties::const_iterator halfface_props_end () const
 
Properties::const_iterator cell_props_begin () const
 
Properties::const_iterator cell_props_end () const
 
Properties::const_iterator mesh_props_begin () const
 
Properties::const_iterator mesh_props_end () const
 
template<class PropT >
bool vertex_property_exists (const std::string &_name) const
 
template<class PropT >
bool edge_property_exists (const std::string &_name) const
 
template<class PropT >
bool halfedge_property_exists (const std::string &_name) const
 
template<class PropT >
bool face_property_exists (const std::string &_name) const
 
template<class PropT >
bool halfface_property_exists (const std::string &_name) const
 
template<class PropT >
bool cell_property_exists (const std::string &_name) const
 
template<class PropT >
bool mesh_property_exists (const std::string &_name) const
 

Protected Member Functions

void vertex_deleted (const VertexHandle &_h)
 
void edge_deleted (const EdgeHandle &_h)
 
void face_deleted (const FaceHandle &_h)
 
void cell_deleted (const CellHandle &_h)
 
void swap_cell_properties (CellHandle _h1, CellHandle _h2)
 
void swap_face_properties (FaceHandle _h1, FaceHandle _h2)
 
void swap_halfface_properties (HalfFaceHandle _h1, HalfFaceHandle _h2)
 
void swap_edge_properties (EdgeHandle _h1, EdgeHandle _h2)
 
void swap_halfedge_properties (HalfEdgeHandle _h1, HalfEdgeHandle _h2)
 
void swap_vertex_properties (VertexHandle _h1, VertexHandle _h2)
 
template<typename PropIterator , typename Handle >
void swap_property_elements (PropIterator _begin, PropIterator _end, Handle _h1, Handle _h2)
 
void delete_multiple_vertex_props (const std::vector< bool > &_tags)
 
void delete_multiple_edge_props (const std::vector< bool > &_tags)
 
void delete_multiple_face_props (const std::vector< bool > &_tags)
 
void delete_multiple_cell_props (const std::vector< bool > &_tags)
 

Private Member Functions

void release_property (VertexPropHandle _handle)
 
void release_property (EdgePropHandle _handle)
 
void release_property (HalfEdgePropHandle _handle)
 
void release_property (FacePropHandle _handle)
 
void release_property (HalfFacePropHandle _handle)
 
void release_property (CellPropHandle _handle)
 
void release_property (MeshPropHandle _handle)
 
template<class FullPropT , class PropIterT >
bool property_exists (const PropIterT &_begin, const PropIterT &_end, const std::string &_name) const
 
template<class StdVecT >
void resize_props (StdVecT &_vec, size_t _n)
 
template<class StdVecT >
void entity_deleted (StdVecT &_vec, const OpenVolumeMeshHandle &_h)
 
template<class StdVecT >
void remove_property (StdVecT &_vec, size_t _idx)
 
template<typename T , typename EntityTag >
PropertyTT< T, EntityTag > * internal_find_property (const std::string &_name)
 
template<typename T , typename EntityTag >
PropertyTT< T, EntityTag > internal_create_property (const std::string &_name, const T _def=T())
 
template<class StdVecT >
void clearVec (StdVecT &_vec)
 
template<class StdVecT >
void updatePropHandles (StdVecT &_vec)
 
template<bool Move>
void assignProperties (typename std::conditional< Move, Properties &, const Properties &>::type src, Properties &dest)
 
template<bool Move>
void assignAllPropertiesFrom (typename std::conditional< Move, ResourceManager *, const ResourceManager *>::type src)
 
template<typename Entity >
Propertiesentity_props ()
 
template<typename Entity >
size_t n ()
 

Private Attributes

Properties vertex_props_
 
Properties edge_props_
 
Properties halfedge_props_
 
Properties face_props_
 
Properties halfface_props_
 
Properties cell_props_
 
Properties mesh_props_
 

Friends

template<class PropT , class HandleT >
class PropertyPtr
 

Detailed Description

Definition at line 60 of file ResourceManager.hh.

Member Function Documentation

◆ request_property()

template<typename T , typename EntityTag >
PropertyTT< T, EntityTag > OpenVolumeMesh::ResourceManager::request_property ( const std::string &  _name = std::string(),
const T  _def = T() 
)

Get or create property: if the property does not exist yet, create it.

Definition at line 118 of file ResourceManagerT_impl.hh.


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