Mesh Oriented datABase  (version 5.5.0)
An array-based unstructured mesh library
moab::MeshTag Class Reference

Tag with only a global/mesh value. More...

#include <MeshTag.hpp>

+ Inheritance diagram for moab::MeshTag:
+ Collaboration diagram for moab::MeshTag:

Public Member Functions

 MeshTag (const char *name, int size, DataType type, const void *default_value, int default_value_size)
 constructor that takes all parameters More...
 
virtual ~MeshTag ()
 
virtual TagType get_storage_type () const
 
virtual ErrorCode release_all_data (SequenceManager *seqman, Error *error_handler, bool delete_pending)
 Remove/clear tag data for all entities. More...
 
virtual ErrorCode get_data (const SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities, void *data) const
 Get tag value for passed entities. More...
 
virtual ErrorCode get_data (const SequenceManager *seqman, Error *error_handler, const Range &entities, void *data) const
 Get tag value for passed entities. More...
 
virtual ErrorCode get_data (const SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities, const void **data_ptrs, int *data_lengths) const
 Get tag value for passed entities. More...
 
virtual ErrorCode get_data (const SequenceManager *seqman, Error *error_handler, const Range &entities, const void **data_ptrs, int *data_lengths) const
 Get tag value for passed entities. More...
 
virtual ErrorCode set_data (SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities, const void *data)
 Set tag value for passed entities. More...
 
virtual ErrorCode set_data (SequenceManager *seqman, Error *error_handler, const Range &entities, const void *data)
 Set tag value for passed entities. More...
 
virtual ErrorCode set_data (SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities, void const *const *data_ptrs, const int *data_lengths)
 Set tag value for passed entities. More...
 
virtual ErrorCode set_data (SequenceManager *seqman, Error *error_handler, const Range &entities, void const *const *data_ptrs, const int *data_lengths)
 Set tag value for passed entities. More...
 
virtual ErrorCode clear_data (SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities, const void *value_ptr, int value_len=0)
 Set tag value for passed entities. More...
 
virtual ErrorCode clear_data (SequenceManager *seqman, Error *error_handler, const Range &entities, const void *value_ptr, int value_len=0)
 Set tag value for passed entities. More...
 
virtual ErrorCode remove_data (SequenceManager *seqman, Error *error_handler, const EntityHandle *entities, size_t num_entities)
 Remove/clear tag data for entities. More...
 
virtual ErrorCode remove_data (SequenceManager *seqman, Error *error_handler, const Range &entities)
 Remove/clear tag data for entities. More...
 
virtual ErrorCode tag_iterate (SequenceManager *seqman, Error *error_handler, Range::iterator &iter, const Range::iterator &end, void *&data_ptr, bool allocate=true)
 Access tag data via direct pointer into contiguous blocks. More...
 
virtual ErrorCode get_tagged_entities (const SequenceManager *seqman, Range &output_entities, EntityType type=MBMAXTYPE, const Range *intersect=0) const
 Get all tagged entities. More...
 
virtual ErrorCode num_tagged_entities (const SequenceManager *seqman, size_t &output_count, EntityType type=MBMAXTYPE, const Range *intersect=0) const
 Count all tagged entities. More...
 
virtual ErrorCode find_entities_with_value (const SequenceManager *seqman, Error *error_handler, Range &output_entities, const void *value, int value_bytes=0, EntityType type=MBMAXTYPE, const Range *intersect_entities=0) const
 Get all tagged entities with tag value. More...
 
virtual bool is_tagged (const SequenceManager *, EntityHandle h) const
 Check if entity is tagged. More...
 
virtual ErrorCode get_memory_use (const SequenceManager *seqman, unsigned long &total, unsigned long &per_entity) const
 Get memory use for tag data. More...
 
- Public Member Functions inherited from moab::TagInfo
 TagInfo ()
 constructor More...
 
 TagInfo (const char *name, int size, DataType type, const void *default_value, int default_value_size)
 constructor that takes all parameters More...
 
virtual ~TagInfo ()
 
void set_name (const std::string &name)
 set the name of the tag More...
 
const std::string & get_name () const
 get the name of the tag More...
 
int get_default_value_size () const
 get length of default value More...
 
const void * get_default_value () const
 get the default data More...
 
bool equals_default_value (const void *data, int size=-1) const
 compare the passed value to the default value. returns false if no default value. More...
 
DataType get_data_type () const
 
int get_size () const
 get the size of the data in bytes More...
 
bool variable_length () const
 Check if variable-length tag. More...
 
bool check_valid_sizes (const int *sizes, int num_sizes) const
 
ErrorCode validate_lengths (Error *error_handler, const int *lengths, size_t num_lengths) const
 

Private Member Functions

 MeshTag (const MeshTag &)
 
MeshTagoperator= (const MeshTag &)
 

Private Attributes

std::vector< unsigned char > mValue
 

Additional Inherited Members

- Static Public Member Functions inherited from moab::TagInfo
static int size_from_data_type (DataType t)
 
- Protected Member Functions inherited from moab::TagInfo
unsigned long get_memory_use () const
 

Detailed Description

Tag with only a global/mesh value.

Trivial tag implementation. No per-entity values. Only the global mesh value which is handled by the TagInfo base class.

Definition at line 20 of file MeshTag.hpp.

Constructor & Destructor Documentation

◆ MeshTag() [1/2]

moab::MeshTag::MeshTag ( const char *  name,
int  size,
DataType  type,
const void *  default_value,
int  default_value_size 
)

constructor that takes all parameters

Definition at line 51 of file MeshTag.cpp.

52  : TagInfo( name, size, type, default_value, default_value_size )
53 {
54 }

◆ ~MeshTag()

moab::MeshTag::~MeshTag ( )
virtual

Definition at line 56 of file MeshTag.cpp.

56 {}

◆ MeshTag() [2/2]

moab::MeshTag::MeshTag ( const MeshTag )
private

Member Function Documentation

◆ clear_data() [1/2]

ErrorCode moab::MeshTag::clear_data ( SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities,
const void *  value_ptr,
int  value_len = 0 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
num_entitiesLength of entities array
value_ptrPointer to a single tag value which is to be stored for each of the passed entities.
value_lenLength of tag value in bytes. Ignored for fixed-length tags. Required for variable- length tags.

Implements moab::TagInfo.

Definition at line 215 of file MeshTag.cpp.

221 {
222  if( !all_root_set( get_name(), entities, num_entities ) ) return MB_TAG_NOT_FOUND;
223 
224  ErrorCode valid = validate_lengths( NULL, value_len ? &value_len : 0, 1 );MB_CHK_ERR( valid );
225 
226  if( num_entities > 0 )
227  {
228  mValue.resize( value_len );
229  memcpy( &mValue[0], value_ptr, value_len );
230  }
231 
232  return MB_SUCCESS;
233 }

References moab::all_root_set(), entities, ErrorCode, moab::TagInfo::get_name(), MB_CHK_ERR, MB_SUCCESS, MB_TAG_NOT_FOUND, mValue, and moab::TagInfo::validate_lengths().

◆ clear_data() [2/2]

ErrorCode moab::MeshTag::clear_data ( SequenceManager seqman,
Error error_handler,
const Range entities,
const void *  value_ptr,
int  value_len = 0 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
value_ptrPointer to a single tag value which is to be stored for each of the passed entities.
value_lenLength of tag value in bytes. Ignored for fixed-length tags. Required for variable- length tags.

Implements moab::TagInfo.

Definition at line 235 of file MeshTag.cpp.

236 {
237  if( range.empty() )
238  return MB_SUCCESS;
239  else
240  return not_root_set( get_name(), range.front() );
241 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SUCCESS, and moab::not_root_set().

◆ find_entities_with_value()

ErrorCode moab::MeshTag::find_entities_with_value ( const SequenceManager seqman,
Error error_handler,
Range output_entities,
const void *  value,
int  value_bytes = 0,
EntityType  type = MBMAXTYPE,
const Range intersect_entities = 0 
) const
virtual

Get all tagged entities with tag value.

Get the list of entities which have the specified tag value.

Parameters
seqmanPointer to entity storage database
output_entitiesResults appended to this range
valuePointer to tag value
value_bytesSize of tag value in bytes.
typeOptional entity type. If specified, search is limited to entities of specified type.
intersect_entitiesOptional intersect list. If specified, search is restricted to entities in this list.

Implements moab::TagInfo.

Definition at line 286 of file MeshTag.cpp.

293 {
294  return MB_SUCCESS;
295 }

References MB_SUCCESS.

◆ get_data() [1/4]

ErrorCode moab::MeshTag::get_data ( const SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities,
const void **  data_ptrs,
int *  data_lengths 
) const
virtual

Get tag value for passed entities.

Get tag values for specified entities.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to retrieve tag data
num_entitiesLength of entities array
data_ptrsArray of pointers to tag values, one pointer for each passed entity.
data_lengthsOne value for each entity specifying the length of the tag value for the corresponding entity.

Implements moab::TagInfo.

Definition at line 110 of file MeshTag.cpp.

116 {
117  const void* ptr;
118  int len;
119 
120  if( !mValue.empty() )
121  {
122  ptr = &mValue[0];
123  len = mValue.size();
124  }
125  else if( get_default_value() )
126  {
127  ptr = get_default_value();
128  len = get_default_value_size();
129  }
130  else
131  {
132  return not_found( get_name() );
133  }
134 
135  for( size_t i = 0; i < num_entities; ++i )
136  {
137  if( entities[i] ) return not_root_set( get_name(), entities[i] ); // Not root set
138  data_ptrs[i] = ptr;
139  if( data_lengths ) data_lengths[i] = len;
140  }
141 
142  return MB_SUCCESS;
143 }

References entities, moab::TagInfo::get_default_value(), moab::TagInfo::get_default_value_size(), moab::TagInfo::get_name(), MB_SUCCESS, mValue, moab::not_found(), and moab::not_root_set().

◆ get_data() [2/4]

ErrorCode moab::MeshTag::get_data ( const SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities,
void *  data 
) const
virtual

Get tag value for passed entities.

Get tag values for specified entities.

\Note Will fail for variable-length data.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to retrieve tag data
num_entitiesLength of entities array
dataPointer to memory in which to store consecutive tag values, one for each passed entity.

Implements moab::TagInfo.

Definition at line 68 of file MeshTag.cpp.

73 {
74  if( !all_root_set( get_name(), entities, num_entities ) ) return MB_TAG_NOT_FOUND;
75 
76  const void* ptr;
77  int len;
78 
79  if( !mValue.empty() )
80  {
81  ptr = &mValue[0];
82  len = mValue.size();
83  }
84  else if( get_default_value() )
85  {
86  ptr = get_default_value();
87  len = get_default_value_size();
88  }
89  else
90  {
91  return not_found( get_name() );
92  }
93 
94  SysUtil::setmem( data, ptr, len, num_entities );
95  return MB_SUCCESS;
96 }

References moab::all_root_set(), entities, moab::TagInfo::get_default_value(), moab::TagInfo::get_default_value_size(), moab::TagInfo::get_name(), MB_SUCCESS, MB_TAG_NOT_FOUND, mValue, moab::not_found(), and moab::SysUtil::setmem().

◆ get_data() [3/4]

ErrorCode moab::MeshTag::get_data ( const SequenceManager seqman,
Error error_handler,
const Range entities,
const void **  data_ptrs,
int *  data_lengths 
) const
virtual

Get tag value for passed entities.

Get tag values for specified entities.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to retrieve tag data
data_ptrsArray of pointers to tag values, one pointer for each passed entity.
data_lengthsOne value for each entity specifying the length of the tag value for the corresponding entity.

Implements moab::TagInfo.

Definition at line 145 of file MeshTag.cpp.

146 {
147  if( range.empty() )
148  return MB_SUCCESS;
149  else
150  return not_root_set( get_name(), range.front() );
151 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SUCCESS, and moab::not_root_set().

◆ get_data() [4/4]

ErrorCode moab::MeshTag::get_data ( const SequenceManager seqman,
Error error_handler,
const Range entities,
void *  data 
) const
virtual

Get tag value for passed entities.

Get tag values for specified entities.

\Note Will fail for variable-length data.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to retrieve tag data
dataPointer to memory in which to store consecutive tag values, one for each passed entity.

Implements moab::TagInfo.

Definition at line 98 of file MeshTag.cpp.

99 {
100  if( variable_length() )
101  {
102  MB_SET_ERR( MB_VARIABLE_DATA_LENGTH, "No length specified for variable-length tag " << get_name() << " value" );
103  }
104  else if( r.empty() )
105  return MB_SUCCESS;
106  else
107  return not_root_set( get_name(), r.front() );
108 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SET_ERR, MB_SUCCESS, MB_VARIABLE_DATA_LENGTH, moab::not_root_set(), and moab::TagInfo::variable_length().

◆ get_memory_use()

ErrorCode moab::MeshTag::get_memory_use ( const SequenceManager seqman,
unsigned long &  total,
unsigned long &  per_entity 
) const
virtual

Get memory use for tag data.

Implements moab::TagInfo.

Definition at line 302 of file MeshTag.cpp.

303 {
304  total = TagInfo::get_memory_use() + sizeof( *this ) + mValue.size();
305  per_entity = 0;
306  return MB_SUCCESS;
307 }

References moab::TagInfo::get_memory_use(), MB_SUCCESS, and mValue.

◆ get_storage_type()

TagType moab::MeshTag::get_storage_type ( ) const
virtual

Implements moab::TagInfo.

Definition at line 58 of file MeshTag.cpp.

59 {
60  return MB_TAG_MESH;
61 }

References MB_TAG_MESH.

◆ get_tagged_entities()

ErrorCode moab::MeshTag::get_tagged_entities ( const SequenceManager seqman,
Range output_entities,
EntityType  type = MBMAXTYPE,
const Range intersect = 0 
) const
virtual

Get all tagged entities.

Get the list of entities for which the a tag value has been set, or a close approximation if the tag storage scheme cannot accurately determine exactly which entities have explicit values.

Parameters
seqmanPointer to entity storage database
output_entitiesResults appended to this range
typeOptional entity type. If specified, search is limited to entities of specified type.
intersectOptional intersect list. If specified, search is restricted to entities in this list.

Implements moab::TagInfo.

Definition at line 276 of file MeshTag.cpp.

277 {
278  return MB_SUCCESS;
279 }

References MB_SUCCESS.

◆ is_tagged()

bool moab::MeshTag::is_tagged ( const SequenceManager ,
EntityHandle  h 
) const
virtual

Check if entity is tagged.

Implements moab::TagInfo.

Definition at line 297 of file MeshTag.cpp.

298 {
299  return ( 0 == h ) && ( !mValue.empty() );
300 }

References mValue.

◆ num_tagged_entities()

ErrorCode moab::MeshTag::num_tagged_entities ( const SequenceManager seqman,
size_t &  output_count,
EntityType  type = MBMAXTYPE,
const Range intersect = 0 
) const
virtual

Count all tagged entities.

Count the entities for which the a tag value has been set, or a close approximation if the tag storage scheme cannot accurately determine exactly which entities have explicit values.

Parameters
seqmanPointer to entity storage database
output_countThis is incremented for each detected entity.
typeOptional entity type. If specified, search is limited to entities of specified type.
intersectOptional intersect list. If specified, search is restricted to entities in this list.

Implements moab::TagInfo.

Definition at line 281 of file MeshTag.cpp.

282 {
283  return MB_SUCCESS;
284 }

References MB_SUCCESS.

◆ operator=()

MeshTag& moab::MeshTag::operator= ( const MeshTag )
private

◆ release_all_data()

ErrorCode moab::MeshTag::release_all_data ( SequenceManager seqman,
Error error_handler,
bool  delete_pending 
)
virtual

Remove/clear tag data for all entities.

Remove tag values from entities.

Parameters
delete_pendingIf true, then release any global data associated with the tag in preparation for deleting the tag itself.

\Note Invalidates tag if tag_delete_pending is true. The only valid method that can be invoked that is is the destructor.

Parameters
seqmanPointer to mesh entity database

Implements moab::TagInfo.

Definition at line 63 of file MeshTag.cpp.

64 {
65  return MB_SUCCESS;
66 }

References MB_SUCCESS.

◆ remove_data() [1/2]

ErrorCode moab::MeshTag::remove_data ( SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities 
)
virtual

Remove/clear tag data for entities.

Remove tag values from entities.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
num_entitiesLength of entities array

Implements moab::TagInfo.

Definition at line 243 of file MeshTag.cpp.

247 {
248  if( !all_root_set( get_name(), entities, num_entities ) ) return MB_TAG_NOT_FOUND;
249 
250  if( num_entities ) mValue.clear();
251 
252  return MB_SUCCESS;
253 }

References moab::all_root_set(), entities, moab::TagInfo::get_name(), MB_SUCCESS, MB_TAG_NOT_FOUND, and mValue.

◆ remove_data() [2/2]

ErrorCode moab::MeshTag::remove_data ( SequenceManager seqman,
Error error_handler,
const Range entities 
)
virtual

Remove/clear tag data for entities.

Remove tag values from entities.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data

Implements moab::TagInfo.

Definition at line 255 of file MeshTag.cpp.

256 {
257  if( range.empty() )
258  return MB_SUCCESS;
259  else
260  return not_root_set( get_name(), range.front() );
261 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SUCCESS, and moab::not_root_set().

◆ set_data() [1/4]

ErrorCode moab::MeshTag::set_data ( SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities,
const void *  data 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values \Note Will fail for variable-length data.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
num_entitiesLength of entities array
dataPointer to memory holding consecutive tag values, one for each passed entity.

Implements moab::TagInfo.

Definition at line 153 of file MeshTag.cpp.

158 {
159  if( variable_length() )
160  {
161  MB_SET_ERR( MB_VARIABLE_DATA_LENGTH, "No length specified for variable-length tag " << get_name() << " value" );
162  }
163  if( !all_root_set( get_name(), entities, num_entities ) ) return MB_TAG_NOT_FOUND;
164 
165  if( num_entities > 0 )
166  {
167  mValue.resize( get_size() );
168  const unsigned char* bytes = reinterpret_cast< const unsigned char* >( data );
169  memcpy( &mValue[0], bytes + get_size() * ( num_entities - 1 ), get_size() );
170  }
171 
172  return MB_SUCCESS;
173 }

References moab::all_root_set(), entities, moab::TagInfo::get_name(), moab::TagInfo::get_size(), MB_SET_ERR, MB_SUCCESS, MB_TAG_NOT_FOUND, MB_VARIABLE_DATA_LENGTH, mValue, and moab::TagInfo::variable_length().

◆ set_data() [2/4]

ErrorCode moab::MeshTag::set_data ( SequenceManager seqman,
Error error_handler,
const EntityHandle entities,
size_t  num_entities,
void const *const *  data_ptrs,
const int *  data_lengths 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
num_entitiesLength of entities array
data_ptrsArray of pointers to tag values, one pointer for each passed entity.
data_lengthsOne value for each entity specifying the length of the tag value for the corresponding entity. Array is required for variable-length tags and is ignored for fixed-length tags.

Implements moab::TagInfo.

Definition at line 187 of file MeshTag.cpp.

193 {
194  if( !all_root_set( get_name(), entities, num_entities ) ) return MB_TAG_NOT_FOUND;
195 
196  ErrorCode valid = validate_lengths( NULL, data_lengths, num_entities );MB_CHK_ERR( valid );
197 
198  if( num_entities > 0 )
199  {
200  mValue.resize( data_lengths[num_entities - 1] );
201  memcpy( &mValue[0], data_ptrs[num_entities - 1], mValue.size() );
202  }
203 
204  return MB_SUCCESS;
205 }

References moab::all_root_set(), entities, ErrorCode, moab::TagInfo::get_name(), MB_CHK_ERR, MB_SUCCESS, MB_TAG_NOT_FOUND, mValue, and moab::TagInfo::validate_lengths().

◆ set_data() [3/4]

ErrorCode moab::MeshTag::set_data ( SequenceManager seqman,
Error error_handler,
const Range entities,
const void *  data 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values \Note Will fail for variable-length data.

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
dataPointer to memory holding consecutive tag values, one for each passed entity.

Implements moab::TagInfo.

Definition at line 175 of file MeshTag.cpp.

176 {
177  if( variable_length() )
178  {
179  MB_SET_ERR( MB_VARIABLE_DATA_LENGTH, "No length specified for variable-length tag " << get_name() << " value" );
180  }
181  else if( range.empty() )
182  return MB_SUCCESS;
183  else
184  return not_root_set( get_name(), range.front() );
185 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SET_ERR, MB_SUCCESS, MB_VARIABLE_DATA_LENGTH, moab::not_root_set(), and moab::TagInfo::variable_length().

◆ set_data() [4/4]

ErrorCode moab::MeshTag::set_data ( SequenceManager seqman,
Error error_handler,
const Range entities,
void const *const *  data_ptrs,
const int *  data_lengths 
)
virtual

Set tag value for passed entities.

Store tag data or update stored tag values

Parameters
seqmanPointer to mesh entity database
entitiesEntity handles for which to store tag data
data_ptrsArray of pointers to tag values, one pointer for each passed entity.
data_lengthsOne value for each entity specifying the length of the tag value for the corresponding entity. Array is required for variable-length tags and is ignored for fixed-length tags.

Implements moab::TagInfo.

Definition at line 207 of file MeshTag.cpp.

208 {
209  if( range.empty() )
210  return MB_SUCCESS;
211  else
212  return not_root_set( get_name(), range.front() );
213 }

References moab::Range::empty(), moab::Range::front(), moab::TagInfo::get_name(), MB_SUCCESS, and moab::not_root_set().

◆ tag_iterate()

ErrorCode moab::MeshTag::tag_iterate ( SequenceManager seqman,
Error error_handler,
Range::iterator iter,
const Range::iterator end,
void *&  data_ptr,
bool  allocate = true 
)
virtual

Access tag data via direct pointer into contiguous blocks.

Iteratively obtain direct access to contiguous blocks of tag storage. This function cannot be used with bit tags because of the compressed bit storage. This function cannot be used with variable length tags because it does not provide a mechanism to determine the length of the value for each entity. This function may be used with sparse tags, but if it is used, it will return data for a single entity at a time.

Parameters
iterAs input, the first entity for which to return data. As output, one past the last entity for which data was returned.
endOne past the last entity for which data is desired
data_ptrOutput: pointer to tag storage.
allocateIf true, allocate space for this tag as part of this call, else don't

\Note If this function is called for entities for which no tag value has been set, but for which a default value exists, it will force the allocation of explicit storage for each such entity even though MOAB would normally not explicitly store tag values for such entities.

Implements moab::TagInfo.

Definition at line 263 of file MeshTag.cpp.

269 {
270  if( beg == end )
271  return MB_SUCCESS;
272  else
273  return not_root_set( get_name(), *beg );
274 }

References moab::TagInfo::get_name(), MB_SUCCESS, and moab::not_root_set().

Member Data Documentation

◆ mValue

std::vector< unsigned char > moab::MeshTag::mValue
private

Definition at line 345 of file MeshTag.hpp.

Referenced by clear_data(), get_data(), get_memory_use(), is_tagged(), remove_data(), and set_data().


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