48 for( MapType::iterator i =
mData.begin(); i !=
mData.end(); ++i )
56 #ifdef MOAB_HAVE_UNORDERED_MAP
57 MapType::iterator iter =
mData.find( entity_handle );
59 MapType::iterator iter =
mData.lower_bound( entity_handle );
63 if( iter !=
mData.end() && iter->first == entity_handle ) memcpy( iter->second, data,
get_size() );
68 memcpy( new_data, data,
get_size() );
76 MapType::const_iterator iter =
mData.find( entity_handle );
78 if( iter !=
mData.end() )
108 MapType::iterator i =
mData.find( entity_handle );
124 unsigned char* ptr =
reinterpret_cast< unsigned char*
>( data );
125 for(
size_t i = 0; i < num_entities; ++i, ptr +=
get_size() )
137 unsigned char* ptr =
reinterpret_cast< unsigned char*
>( data );
152 const void** pointers,
153 int* data_lengths )
const
162 for(
size_t i = 0; i < num_entities; ++i, ++pointers )
181 const void** pointers,
182 int* data_lengths )
const
216 const unsigned char* ptr =
reinterpret_cast< const unsigned char*
>( data );
217 for(
size_t i = 0; i < num_entities; ++i, ptr +=
get_size() )
229 const unsigned char* ptr =
reinterpret_cast< const unsigned char*
>( data );
241 void const*
const* pointers,
248 for(
size_t i = 0; i < num_entities; ++i, ++pointers )
259 void const*
const* pointers,
279 const void* value_ptr,
282 if( value_len && value_len !=
get_size() )
285 <<
" of size " << value_len );
290 for(
size_t i = 0; i < num_entities; ++i )
301 const void* value_ptr,
304 if( value_len && value_len !=
get_size() )
307 <<
" of size " << value_len );
324 size_t num_entities )
327 for(
size_t i = 0; i < num_entities; ++i )
366 const void* ptr = NULL;
369 data_ptr =
const_cast< void*
>( ptr );
373 data_ptr =
const_cast< void*
>( ptr );
388 template <
class Container >
391 SparseTag::MapType::const_iterator iter;
392 typename Container::iterator hint = output_range.begin();
395 for( iter = mData.begin(); iter != mData.end(); ++iter )
396 hint = output_range.insert( hint, iter->first );
400 #ifdef MOAB_HAVE_UNORDERED_MAP
401 for( iter = mData.begin(); iter != mData.end(); ++iter )
402 if(
TYPE_FROM_HANDLE( iter->first ) == type ) hint = output_range.insert( hint, iter->first );
405 SparseTag::MapType::const_iterator end = mData.lower_bound(
LAST_HANDLE( type ) + 1 );
406 for( ; iter != end; ++iter )
407 hint = output_range.insert( hint, iter->first );
412 template <
class Container >
416 Container& output_range )
418 typename Container::iterator hint = output_range.begin();
420 if( mData.find( *i ) != mData.end() ) hint = output_range.insert( hint, *i );
423 template <
class Container >
430 get_tagged< Container >( mData, type,
entities );
435 std::pair< Range::iterator, Range::iterator > r =
intersect->equal_range( type );
436 get_tagged< Container >( mData, r.first, r.second,
entities );
452 size_t& output_count,
458 output_count = counter.
end();
469 Range& output_entities,
473 const Range* intersect_entities )
const
475 if( value_bytes && value_bytes !=
get_size() )
478 <<
" of size " << value_bytes );
481 MapType::const_iterator iter, end;
482 #ifdef MOAB_HAVE_UNORDERED_MAP
483 if( intersect_entities )
485 std::pair< Range::iterator, Range::iterator > r;
488 r.first = intersect_entities->
begin();
489 r.second = intersect_entities->
end();
505 seqman->get_entities( type, tmp );
509 if( intersect_entities )
513 iter =
mData.lower_bound( p->first );
514 end =
mData.upper_bound( p->second );
522 iter =
mData.begin();
545 per_entity =
get_size() + 4 *
sizeof(
void* );