#include <SequenceManager.hpp>
Public Member Functions | |
SequenceManager (double default_seq_multiplier=1.0) | |
~SequenceManager () | |
void | clear () |
ErrorCode | find (EntityHandle handle, EntitySequence *&sequence_out) |
ErrorCode | find (EntityHandle handle, const EntitySequence *&sequence_out) const |
void | get_entities (EntityType type, Range &entities_out) const |
void | get_entities (Range &entities_out) const |
void | get_entities (EntityType type, std::vector< EntityHandle > &entities_out) const |
void | get_entities (std::vector< EntityHandle > &entities_out) const |
EntityID | get_number_entities (EntityType type) const |
EntityID | get_number_entities () const |
const EntitySequence * | get_last_accessed_sequence (EntityType type) const |
ErrorCode | replace_subsequence (EntitySequence *new_seq) |
Replace subset of existing sequence with new sequence (splits existing sequence) More... | |
ErrorCode | check_valid_entities (Error *error_handler, const Range &entities) const |
ErrorCode | check_valid_entities (Error *error_handler, const EntityHandle entities[], size_t num_entities, bool root_set_okay=false) const |
ErrorCode | delete_entity (Error *error_handler, EntityHandle entity) |
ErrorCode | delete_entities (Error *error_handler, const Range &entities) |
ErrorCode | create_vertex (const double coords[3], EntityHandle &handle_out) |
ErrorCode | create_element (EntityType type, const EntityHandle *conn_array, unsigned num_vertices, EntityHandle &handle_out) |
ErrorCode | create_mesh_set (unsigned flags, EntityHandle &handle_out) |
ErrorCode | allocate_mesh_set (EntityHandle at_this_handle, unsigned flags) |
ErrorCode | create_entity_sequence (EntityType type, EntityID num_entities, int nodes_per_entity, EntityID start_id_hint, EntityHandle &first_handle_out, EntitySequence *&sequence_out, int sequence_size) |
Allocate a block of consecutive entity handles. More... | |
ErrorCode | create_meshset_sequence (EntityID num_sets, EntityID start_id_hint, const unsigned *flags, EntityHandle &first_handle_out, EntitySequence *&sequence_out) |
Allocate a block of consecutive mesh sets. More... | |
ErrorCode | create_meshset_sequence (EntityID num_sets, EntityID start_id_hint, unsigned flags, EntityHandle &first_handle_out, EntitySequence *&sequence_out) |
Allocate a block of consecutive mesh sets. More... | |
ErrorCode | create_scd_sequence (int imin, int jmin, int kmin, int imax, int jmax, int kmax, EntityType type, EntityID start_id_hint, EntityHandle &first_handle_out, EntitySequence *&sequence_out, int *is_periodic=NULL) |
ErrorCode | create_scd_sequence (const HomCoord &coord_min, const HomCoord &coord_max, EntityType type, EntityID start_id_hint, EntityHandle &first_handle_out, EntitySequence *&sequence_out, int *is_periodic=NULL) |
ErrorCode | create_sweep_sequence (int imin, int jmin, int kmin, int imax, int jmax, int kmax, int *Cq, EntityType type, EntityID start_id_hint, EntityHandle &first_handle_out, EntitySequence *&sequence_out) |
ErrorCode | create_sweep_sequence (const HomCoord &coord_min, const HomCoord &coord_max, int *Cq, EntityType type, EntityID start_id_hint, EntityHandle &first_handle_out, EntitySequence *&sequence_out) |
ErrorCode | add_vsequence (EntitySequence *vert_seq, EntitySequence *elem_seq, const HomCoord &p1, const HomCoord &q1, const HomCoord &p2, const HomCoord &q2, const HomCoord &p3, const HomCoord &q3, bool bb_input=false, const HomCoord *bb_min=NULL, const HomCoord *bb_max=NULL) |
TypeSequenceManager & | entity_map (EntityType type) |
const TypeSequenceManager & | entity_map (EntityType type) const |
void | get_memory_use (unsigned long long &total_entity_storage, unsigned long long &total_storage) const |
void | get_memory_use (EntityType type, unsigned long long &total_entity_storage, unsigned long long &total_storage) const |
void | get_memory_use (const Range &entities, unsigned long long &total_entity_storage, unsigned long long &total_amortized_storage) const |
ErrorCode | reserve_tag_array (Error *error_handler, int tag_size, int &array_id_out) |
ErrorCode | release_tag_array (Error *error_handler, int id, bool release_id) |
EntityID | new_sequence_size (EntityHandle start_handle, EntityID requested_size, int sequence_size) const |
Size to allocate for new SquenceData THIS FUNCTION SHOULD ONLY BE CALLED WHEN ALLOCATING FROM ReadUtil IN BULK (since it will allocate lesser of requested_size and default_size) If sequence_size != -1, will try to allocate that, unless there isn't available space. More... | |
double | get_sequence_multiplier () const |
Interface to control memory allocation for sequences Provide a factor that controls the size of the sequence that gets allocated. This is typically useful in the parallel setting when a-priori, the number of ghost entities and the memory required for them within the same sequence as the owned entities are unknown. The default factor is 1.0 but this can be appropriately updated at runtime so that we do not have broken sequences. More... | |
void | set_sequence_multiplier (double factor) |
Interface to control memory allocation for sequences Provide a factor that controls the size of the sequence that gets allocated. This is typically useful in the parallel setting when a-priori, the number of ghost entities and the memory required for them within the same sequence as the owned entities are unknown. The default factor is 1.0 but this can be appropriately updated at runtime so that we do not have broken sequences. More... | |
Static Public Member Functions | |
static EntityID | default_poly_sequence_size (int entity_connectivity_length) |
Get default size of POLYGON and POLYHEDRON SequenceData. More... | |
Static Public Attributes | |
static const EntityID | DEFAULT_VERTEX_SEQUENCE_SIZE = 16 * 1024 |
Default allocation size for vertices. More... | |
static const EntityID | DEFAULT_ELEMENT_SEQUENCE_SIZE = DEFAULT_VERTEX_SEQUENCE_SIZE |
Default allocation size for elements. More... | |
static const EntityID | DEFAULT_POLY_SEQUENCE_SIZE = 16 * 1024 |
Default allocation size for poly's. More... | |
static const EntityID | DEFAULT_MESHSET_SEQUENCE_SIZE = DEFAULT_VERTEX_SEQUENCE_SIZE |
Default allocation size for meshsets. More... | |
Private Member Functions | |
void | trim_sequence_block (EntityHandle start_handle, EntityHandle &end_handle_in_out, unsigned maximum_sequence_size) |
Utility function for allocate_mesh_set (and similar) More... | |
EntityHandle | sequence_start_handle (EntityType type, EntityID entity_count, int values_per_entity, EntityID start_id_hint, SequenceData *&data_out, EntityID &data_size) |
Get range of handles in which to create an entity sequence. More... | |
Private Attributes | |
TypeSequenceManager | typeData [MBMAXTYPE] |
std::vector< int > | tagSizes |
double | sequence_multiplier |
The over-allocation factor for entities in a sequence (strictly >= 1.0) More... | |
Definition at line 14 of file SequenceManager.hpp.
|
inline |
Definition at line 17 of file SequenceManager.hpp.
moab::SequenceManager::~SequenceManager | ( | ) |
Definition at line 36 of file SequenceManager.cpp.
References MB_VARIABLE_LENGTH, release_tag_array(), and tagSizes.
ErrorCode moab::SequenceManager::add_vsequence | ( | EntitySequence * | vert_seq, |
EntitySequence * | elem_seq, | ||
const HomCoord & | p1, | ||
const HomCoord & | q1, | ||
const HomCoord & | p2, | ||
const HomCoord & | q2, | ||
const HomCoord & | p3, | ||
const HomCoord & | q3, | ||
bool | bb_input = false , |
||
const HomCoord * | bb_min = NULL , |
||
const HomCoord * | bb_max = NULL |
||
) |
Add a structured vertex sequence to this structured element sequence; see comments in ScdElementData
Definition at line 736 of file SequenceManager.cpp.
References moab::ScdElementData::add_vsequence(), moab::EntitySequence::data(), and moab::HomCoord::unitv.
ErrorCode moab::SequenceManager::allocate_mesh_set | ( | EntityHandle | at_this_handle, |
unsigned | flags | ||
) |
Allocate an entity set with the specified handle.
Definition at line 340 of file SequenceManager.cpp.
References moab::EntitySequence::data(), DEFAULT_MESHSET_SEQUENCE_SIZE, moab::EntitySequence::end_handle(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), moab::TypeSequenceManager::is_free_handle(), MB_SUCCESS, MBENTITYSET, moab::TypeSequenceManager::notify_appended(), moab::TypeSequenceManager::notify_prepended(), moab::MeshSetSequence::pop_back(), moab::MeshSetSequence::pop_front(), moab::MeshSetSequence::push_back(), moab::MeshSetSequence::push_front(), moab::EntitySequence::start_handle(), trim_sequence_block(), and typeData.
ErrorCode moab::SequenceManager::check_valid_entities | ( | Error * | error_handler, |
const EntityHandle | entities[], | ||
size_t | num_entities, | ||
bool | root_set_okay = false |
||
) | const |
Check if passed entity handles are valid
root_set_okay | If true, do not returnan error if the passed array contains one or more zero-valued handles |
ErrorCode moab::SequenceManager::check_valid_entities | ( | Error * | error_handler, |
const Range & | entities | ||
) | const |
Check if passed entity handles are valid
Definition at line 78 of file SequenceManager.cpp.
References moab::TypeSequenceManager::check_valid_handles(), moab::CREATE_HANDLE(), entities, ErrorCode, MB_SUCCESS, split, moab::TYPE_FROM_HANDLE(), and typeData.
Referenced by moab::BitTag::clear_data(), moab::SparseTag::clear_data(), moab::VarLenSparseTag::clear_data(), delete_entities(), moab::BitTag::set_data(), moab::SparseTag::set_data(), moab::VarLenSparseTag::set_data(), and moab::SparseTag::tag_iterate().
void moab::SequenceManager::clear | ( | ) |
Delete all contained data
Definition at line 43 of file SequenceManager.cpp.
References MBMAXTYPE, MBVERTEX, sequence_multiplier, and typeData.
ErrorCode moab::SequenceManager::create_element | ( | EntityType | type, |
const EntityHandle * | conn_array, | ||
unsigned | num_vertices, | ||
EntityHandle & | handle_out | ||
) |
Allocate a element (possibly in an existing sequence) and assign it the passed connectivity.
Definition at line 219 of file SequenceManager.cpp.
References moab::CREATE_HANDLE(), moab::EntitySequence::data(), DEFAULT_ELEMENT_SEQUENCE_SIZE, default_poly_sequence_size(), moab::EntitySequence::end_handle(), ErrorCode, moab::TypeSequenceManager::find_free_handle(), moab::TypeSequenceManager::find_free_sequence(), moab::TypeSequenceManager::insert_sequence(), MB_END_ID, MB_START_ID, MB_SUCCESS, MB_TYPE_OUT_OF_RANGE, MBENTITYSET, MBPOLYGON, MBPOLYHEDRON, moab::TypeSequenceManager::notify_appended(), moab::TypeSequenceManager::notify_prepended(), moab::UnstructuredElemSeq::push_back(), moab::UnstructuredElemSeq::push_front(), moab::UnstructuredElemSeq::set_connectivity(), size, moab::EntitySequence::start_handle(), and typeData.
ErrorCode moab::SequenceManager::create_entity_sequence | ( | EntityType | type, |
EntityID | num_entities, | ||
int | nodes_per_entity, | ||
EntityID | start_id_hint, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out, | ||
int | sequence_size | ||
) |
Allocate a block of consecutive entity handles.
Allocate a block of consecutive entity handles. Handles may be appended or prepended to an existing entity sequence.
type | The type of of entity for which to allocate handles |
num_entities | Number of entities to allocate |
nodes_per_entity | Number of nodes in connectivity for elements, ignored MBVERTEX, MBPOLYGON, MBPOLYHEDRON, and MBENTITYSET types. |
start_id_hint | Preferred ID portion for first handle. May be ignored if not available. |
first_handle_out | First allocated handle. Allocated handles are [first_handle_out, first_handle_out+num_entities-1]. |
sequence_out | The sequence in which the entities were allocated. NOTE: first_handle_out may not be first handle in sequence. |
sequence_size | If specified, allocate this sequence size instead of DEFAULT_***_SEQUENCE_SIZE |
Definition at line 451 of file SequenceManager.cpp.
References moab::EntitySequence::data(), default_poly_sequence_size(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), MB_INDEX_OUT_OF_RANGE, MB_MEMORY_ALLOCATION_FAILED, MB_SUCCESS, MB_TYPE_OUT_OF_RANGE, MBENTITYSET, MBMAXTYPE, MBPOLYGON, MBPOLYHEDRON, MBVERTEX, new_sequence_size(), sequence_start_handle(), size, and typeData.
Referenced by moab::ReadUtil::get_element_connect(), and moab::ReadUtil::get_node_coords().
ErrorCode moab::SequenceManager::create_mesh_set | ( | unsigned | flags, |
EntityHandle & | handle_out | ||
) |
Allocate an entity set (possibly in an existing sequence)
Definition at line 289 of file SequenceManager.cpp.
References moab::CREATE_HANDLE(), moab::EntitySequence::data(), DEFAULT_MESHSET_SEQUENCE_SIZE, moab::EntitySequence::end_handle(), ErrorCode, moab::TypeSequenceManager::find_free_handle(), moab::TypeSequenceManager::find_free_sequence(), moab::TypeSequenceManager::insert_sequence(), MB_END_ID, MB_START_ID, MB_SUCCESS, MBENTITYSET, moab::TypeSequenceManager::notify_appended(), moab::TypeSequenceManager::notify_prepended(), moab::MeshSetSequence::push_back(), moab::MeshSetSequence::push_front(), moab::EntitySequence::start_handle(), and typeData.
ErrorCode moab::SequenceManager::create_meshset_sequence | ( | EntityID | num_sets, |
EntityID | start_id_hint, | ||
const unsigned * | flags, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out | ||
) |
Allocate a block of consecutive mesh sets.
Allocate a block of consecutive entity handles. Handles may be appended or prepended to an existing entity sequence.
type | The type of of entity for which to allocate handles |
num_sets | Number of entities to allocate |
start_id_hint | Preferred ID portion for first handle. May be ignored if not available. |
processor_id | Processor ID to embed in handles |
flags | Array of length 'num_sets' containing entity set creating flags. |
first_handle_out | First allocated handle. Allocated handles are [first_handle_out, first_handle_out+num_entities-1]. |
sequence_out | The sequence in which the entities were allocated. NOTE: first_handle_out may not be first handle in sequence. |
Definition at line 527 of file SequenceManager.cpp.
References moab::EntitySequence::data(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), MB_MEMORY_ALLOCATION_FAILED, MB_SUCCESS, MBENTITYSET, sequence_start_handle(), and typeData.
Referenced by moab::ReadUtil::create_entity_sets().
ErrorCode moab::SequenceManager::create_meshset_sequence | ( | EntityID | num_sets, |
EntityID | start_id_hint, | ||
unsigned | flags, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out | ||
) |
Allocate a block of consecutive mesh sets.
Alternate form that creates all mesh sets with same flags.
Definition at line 558 of file SequenceManager.cpp.
References moab::EntitySequence::data(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), MB_MEMORY_ALLOCATION_FAILED, MB_SUCCESS, MBENTITYSET, sequence_start_handle(), and typeData.
ErrorCode moab::SequenceManager::create_scd_sequence | ( | const HomCoord & | coord_min, |
const HomCoord & | coord_max, | ||
EntityType | type, | ||
EntityID | start_id_hint, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out, | ||
int * | is_periodic = NULL |
||
) |
Create structured mesh
Definition at line 653 of file SequenceManager.cpp.
References create_scd_sequence(), moab::HomCoord::i(), moab::HomCoord::j(), and moab::HomCoord::k().
ErrorCode moab::SequenceManager::create_scd_sequence | ( | int | imin, |
int | jmin, | ||
int | kmin, | ||
int | imax, | ||
int | jmax, | ||
int | kmax, | ||
EntityType | type, | ||
EntityID | start_id_hint, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out, | ||
int * | is_periodic = NULL |
||
) |
Create structured mesh
Definition at line 588 of file SequenceManager.cpp.
References moab::EntitySequence::data(), moab::CN::Dimension(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), MB_MEMORY_ALLOCATION_FAILED, MB_SUCCESS, MB_TYPE_OUT_OF_RANGE, MBEDGE, MBHEX, MBQUAD, MBVERTEX, sequence_start_handle(), moab::SequenceData::size(), and typeData.
Referenced by moab::ScdInterface::construct_box(), create_scd_sequence(), and moab::ScdInterface::create_scd_sequence().
ErrorCode moab::SequenceManager::create_sweep_sequence | ( | const HomCoord & | coord_min, |
const HomCoord & | coord_max, | ||
int * | Cq, | ||
EntityType | type, | ||
EntityID | start_id_hint, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out | ||
) |
Create swept mesh
Definition at line 724 of file SequenceManager.cpp.
References create_sweep_sequence(), moab::HomCoord::i(), moab::HomCoord::j(), and moab::HomCoord::k().
ErrorCode moab::SequenceManager::create_sweep_sequence | ( | int | imin, |
int | jmin, | ||
int | kmin, | ||
int | imax, | ||
int | jmax, | ||
int | kmax, | ||
int * | Cq, | ||
EntityType | type, | ||
EntityID | start_id_hint, | ||
EntityHandle & | first_handle_out, | ||
EntitySequence *& | sequence_out | ||
) |
Create swept mesh
Definition at line 665 of file SequenceManager.cpp.
References moab::EntitySequence::data(), moab::CN::Dimension(), ErrorCode, moab::TypeSequenceManager::insert_sequence(), MB_MEMORY_ALLOCATION_FAILED, MB_SUCCESS, MB_TYPE_OUT_OF_RANGE, MBEDGE, MBHEX, MBQUAD, MBVERTEX, sequence_start_handle(), moab::SequenceData::size(), and typeData.
Referenced by create_sweep_sequence().
ErrorCode moab::SequenceManager::create_vertex | ( | const double | coords[3], |
EntityHandle & | handle_out | ||
) |
Allocate a vertex (possibly in an existing sequence) and assign it the passed coordinate values.
Definition at line 168 of file SequenceManager.cpp.
References moab::CREATE_HANDLE(), moab::EntitySequence::data(), DEFAULT_VERTEX_SEQUENCE_SIZE, moab::EntitySequence::end_handle(), ErrorCode, moab::TypeSequenceManager::find_free_handle(), moab::TypeSequenceManager::find_free_sequence(), moab::TypeSequenceManager::insert_sequence(), MB_END_ID, MB_START_ID, MB_SUCCESS, MBVERTEX, moab::TypeSequenceManager::notify_appended(), moab::TypeSequenceManager::notify_prepended(), moab::VertexSequence::push_back(), moab::VertexSequence::push_front(), moab::VertexSequence::set_coordinates(), moab::EntitySequence::start_handle(), and typeData.
|
static |
Get default size of POLYGON and POLYHEDRON SequenceData.
Definition at line 31 of file SequenceManager.cpp.
References DEFAULT_POLY_SEQUENCE_SIZE.
Referenced by create_element(), and create_entity_sequence().
Delete entities
Definition at line 138 of file SequenceManager.cpp.
References check_valid_entities(), moab::CREATE_HANDLE(), entities, moab::TypeSequenceManager::erase(), ErrorCode, MB_SUCCESS, split, moab::TYPE_FROM_HANDLE(), and typeData.
ErrorCode moab::SequenceManager::delete_entity | ( | Error * | error_handler, |
EntityHandle | entity | ||
) |
Delete an entity. Deletes sequence if only contained entity.
Definition at line 133 of file SequenceManager.cpp.
References moab::TypeSequenceManager::erase(), moab::TYPE_FROM_HANDLE(), and typeData.
|
inline |
Get data for a specific EntityType
Definition at line 246 of file SequenceManager.hpp.
References typeData.
Referenced by moab::VarLenDenseTag::find_entities_with_value(), moab::DenseTag::find_entities_with_value(), moab::RangeSeqIntersectIter::find_invalid_range(), moab::WriteUtil::get_element_connect(), moab::ReorderTool::get_entities(), moab::DenseTag::get_memory_use(), moab::VarLenDenseTag::get_memory_use(), moab::AEntityFactory::get_memory_use(), moab::WriteUtil::get_node_coords(), moab::get_tagged(), moab::DenseTag::get_tagged_entities(), moab::ReorderTool::handle_order_from_int_tag(), moab::operator<<(), release_tag_array(), moab::ReorderTool::reorder_entities(), and moab::AEntityFactory::~AEntityFactory().
|
inline |
Get data for a specific EntityType
Definition at line 252 of file SequenceManager.hpp.
References typeData.
|
inline |
Find entity sequence containing specified handle.
Definition at line 35 of file SequenceManager.hpp.
References moab::TypeSequenceManager::find(), moab::TYPE_FROM_HANDLE(), and typeData.
|
inline |
Find entity sequence containing specified handle.
Definition at line 27 of file SequenceManager.hpp.
References moab::TypeSequenceManager::find(), moab::TYPE_FROM_HANDLE(), and typeData.
Referenced by moab::HigherOrderFactory::add_mid_edge_nodes(), moab::HigherOrderFactory::add_mid_face_nodes(), moab::HigherOrderFactory::add_mid_volume_nodes(), moab::HigherOrderFactory::convert(), moab::AEntityFactory::get_adjacency_ptr(), moab::VarLenDenseTag::get_array(), moab::DenseTag::get_array_private(), moab::WriteUtil::get_entity_list_pointers(), moab::get_mesh_set(), moab::MeshSetSequence::get_parent_child_meshsets(), moab::ParallelComm::pack_entities(), moab::MeshSetSequence::recursive_get_sets(), moab::AEntityFactory::set_adjacency_ptr(), and moab::RangeSeqIntersectIter::update_entity_sequence().
|
inline |
Get all entities of a given EntityType, return all entities if type == MBMAXTYPE
Definition at line 42 of file SequenceManager.hpp.
References moab::TypeSequenceManager::get_entities(), MBMAXTYPE, and typeData.
Referenced by get_entities(), and moab::VarLenDenseTag::release_all_data().
|
inline |
Get all entities of a given EntityType, return all entities if type == MBMAXTYPE
Definition at line 54 of file SequenceManager.hpp.
References get_entities(), moab::TypeSequenceManager::get_entities(), MBMAXTYPE, and typeData.
void moab::SequenceManager::get_entities | ( | Range & | entities_out | ) | const |
Definition at line 57 of file SequenceManager.cpp.
References get_entities(), MBENTITYSET, MBVERTEX, and typeData.
void moab::SequenceManager::get_entities | ( | std::vector< EntityHandle > & | entities_out | ) | const |
Definition at line 63 of file SequenceManager.cpp.
References get_entities(), MBMAXTYPE, MBVERTEX, and typeData.
|
inline |
Get most recently accessed sequence for a given type
Definition at line 74 of file SequenceManager.hpp.
References moab::TypeSequenceManager::get_last_accessed(), and typeData.
void moab::SequenceManager::get_memory_use | ( | const Range & | entities, |
unsigned long long & | total_entity_storage, | ||
unsigned long long & | total_amortized_storage | ||
) | const |
Definition at line 791 of file SequenceManager.cpp.
References moab::CREATE_HANDLE(), entities, moab::TypeSequenceManager::get_memory_use(), MB_END_ID, MB_START_ID, moab::TYPE_FROM_HANDLE(), and typeData.
void moab::SequenceManager::get_memory_use | ( | EntityType | type, |
unsigned long long & | total_entity_storage, | ||
unsigned long long & | total_storage | ||
) | const |
Definition at line 784 of file SequenceManager.cpp.
References moab::TypeSequenceManager::get_memory_use(), and typeData.
void moab::SequenceManager::get_memory_use | ( | unsigned long long & | total_entity_storage, |
unsigned long long & | total_storage | ||
) | const |
Definition at line 768 of file SequenceManager.cpp.
EntityID moab::SequenceManager::get_number_entities | ( | ) | const |
Count entities of a given EntityType
Definition at line 69 of file SequenceManager.cpp.
References MBMAXTYPE, MBVERTEX, moab::sum(), and typeData.
Referenced by get_number_entities().
|
inline |
Count entities of a given EntityType
Definition at line 65 of file SequenceManager.hpp.
References get_number_entities(), moab::TypeSequenceManager::get_number_entities(), MBMAXTYPE, and typeData.
|
inline |
Interface to control memory allocation for sequences Provide a factor that controls the size of the sequence that gets allocated. This is typically useful in the parallel setting when a-priori, the number of ghost entities and the memory required for them within the same sequence as the owned entities are unknown. The default factor is 1.0 but this can be appropriately updated at runtime so that we do not have broken sequences.
Definition at line 296 of file SequenceManager.hpp.
References sequence_multiplier.
EntityID moab::SequenceManager::new_sequence_size | ( | EntityHandle | start_handle, |
EntityID | requested_size, | ||
int | sequence_size | ||
) | const |
Size to allocate for new SquenceData THIS FUNCTION SHOULD ONLY BE CALLED WHEN ALLOCATING FROM ReadUtil IN BULK (since it will allocate lesser of requested_size and default_size) If sequence_size != -1, will try to allocate that, unless there isn't available space.
Definition at line 430 of file SequenceManager.cpp.
References moab::TypeSequenceManager::last_free_handle(), sequence_multiplier, moab::TYPE_FROM_HANDLE(), and typeData.
Referenced by create_entity_sequence().
ErrorCode moab::SequenceManager::release_tag_array | ( | Error * | error_handler, |
int | id, | ||
bool | release_id | ||
) |
Release any storage assocociated with a tag ID, and optionally, release the reserved tag ID.
Definition at line 849 of file SequenceManager.cpp.
References moab::TypeSequenceManager::begin(), moab::TypeSequenceManager::end(), entity_map(), MB_SUCCESS, MB_TAG_NOT_FOUND, MBENTITYSET, MBVERTEX, tagSizes, and moab::UNUSED_SIZE.
Referenced by moab::DenseTag::release_all_data(), moab::VarLenDenseTag::release_all_data(), and ~SequenceManager().
ErrorCode moab::SequenceManager::replace_subsequence | ( | EntitySequence * | new_seq | ) |
Replace subset of existing sequence with new sequence (splits existing sequence)
Used for converting number of nodes for fixed-connectivity-length elements. Input sequence must be a non-strict subset of an existing sequence. Existing sequence will be removed, modified, or split into two prevent it from overlapping the new sequence.
Definition at line 762 of file SequenceManager.cpp.
References moab::TypeSequenceManager::replace_subsequence(), moab::EntitySequence::start_handle(), tagSizes, moab::TYPE_FROM_HANDLE(), and typeData.
Referenced by moab::HigherOrderFactory::convert_sequence().
ErrorCode moab::SequenceManager::reserve_tag_array | ( | Error * | error_handler, |
int | tag_size, | ||
int & | array_id_out | ||
) |
Allocate a tag ID
tag_size | The size of the tag value for each entity |
Definition at line 827 of file SequenceManager.cpp.
References MB_INVALID_SIZE, MB_SET_ERR, MB_SUCCESS, MB_VARIABLE_LENGTH, size, tagSizes, and moab::UNUSED_SIZE.
Referenced by moab::DenseTag::create_tag(), and moab::VarLenDenseTag::create_tag().
|
private |
Get range of handles in which to create an entity sequence.
Get range of handles in whcih to place a new entity sequence.
type | The EntityType for the contents of the sequence |
entity_count | The number of entities in the range |
values_per_entity | Vertices per element, zero for other types |
start_id_hint | Preferred id of first handle |
processor_rank | MPI processor ID |
data_out | Output: Either NULL or an existing SequenceData with a sufficiently large block to accomodate the handle range. |
Definition at line 410 of file SequenceManager.cpp.
References moab::CREATE_HANDLE(), moab::TypeSequenceManager::find_free_sequence(), moab::TypeSequenceManager::is_free_sequence(), MB_END_ID, MB_START_ID, size, and typeData.
Referenced by create_entity_sequence(), create_meshset_sequence(), create_scd_sequence(), and create_sweep_sequence().
|
inline |
Interface to control memory allocation for sequences Provide a factor that controls the size of the sequence that gets allocated. This is typically useful in the parallel setting when a-priori, the number of ghost entities and the memory required for them within the same sequence as the owned entities are unknown. The default factor is 1.0 but this can be appropriately updated at runtime so that we do not have broken sequences.
meshset | User specified multiplier (should be greater than 1.0) |
Definition at line 310 of file SequenceManager.hpp.
References sequence_multiplier.
|
private |
Utility function for allocate_mesh_set (and similar)
Given a block of available handles, determine the non-strict subset at which to create a new EntitySequence.
Definition at line 401 of file SequenceManager.cpp.
Referenced by allocate_mesh_set().
|
static |
Default allocation size for elements.
Definition at line 319 of file SequenceManager.hpp.
Referenced by create_element(), and moab::Tqdcfr::read_elements().
|
static |
Default allocation size for meshsets.
Definition at line 325 of file SequenceManager.hpp.
Referenced by allocate_mesh_set(), and create_mesh_set().
|
static |
Default allocation size for poly's.
Definition at line 322 of file SequenceManager.hpp.
Referenced by default_poly_sequence_size().
|
static |
Default allocation size for vertices.
Definition at line 316 of file SequenceManager.hpp.
Referenced by create_vertex(), and moab::Tqdcfr::read_nodes().
|
private |
The over-allocation factor for entities in a sequence (strictly >= 1.0)
Definition at line 362 of file SequenceManager.hpp.
Referenced by clear(), get_sequence_multiplier(), new_sequence_size(), and set_sequence_multiplier().
|
private |
Definition at line 359 of file SequenceManager.hpp.
Referenced by release_tag_array(), replace_subsequence(), reserve_tag_array(), and ~SequenceManager().
|
private |
Definition at line 357 of file SequenceManager.hpp.
Referenced by allocate_mesh_set(), check_valid_entities(), clear(), create_element(), create_entity_sequence(), create_mesh_set(), create_meshset_sequence(), create_scd_sequence(), create_sweep_sequence(), create_vertex(), delete_entities(), delete_entity(), entity_map(), find(), get_entities(), get_last_accessed_sequence(), get_memory_use(), get_number_entities(), new_sequence_size(), replace_subsequence(), and sequence_start_handle().