summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/Naming/Persistent_Naming_Context.cpp
blob: 37959c4f5176f3e0b8fba3d2fb2ec67ac0ce1387 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
// $Id$
// ============================================================================
//
// = LIBRARY
//    cos
//
// = FILENAME
//   Persistent_Naming_Context.cpp
//
// = AUTHOR
//    Marina Spivak <marina@cs.wustl.edu>
//
// ============================================================================
#include "ace/Auto_Ptr.h"
#include "Persistent_Naming_Context.h"
#include "Persistent_Context_Index.h"
#include "Bindings_Iterator_T.h"

ACE_RCSID(Naming, Persistent_Naming_Context, "$Id$")

int
TAO_Persistent_Bindings_Map::unbind (const char *id,
                                     const char *kind)
{
  TAO_Persistent_ExtId name (id, kind);
  TAO_Persistent_IntId entry;
  if (this->map_->unbind (name, entry, this->allocator_) != 0)
    return -1;
  else
    {
      // Free up the memory we allocated in shared_bind().  Note that
      // this assumes that the "ref" pointer comes first and that
      // the ref, id and kind are contiguously allocated (see
      // shared_bind() for details).
      this->allocator_->free ((void *) (entry.ref_));
      return 0;
    }
}

int
TAO_Persistent_Bindings_Map::bind (const char *id,
                                   const char *kind,
                                   CORBA::Object_ptr obj,
                                   CosNaming::BindingType type)
{
  return this->shared_bind (id, kind, obj, type, 0);
}

int
TAO_Persistent_Bindings_Map::rebind (const char *id,
                                     const char *kind,
                                     CORBA::Object_ptr obj,
                                     CosNaming::BindingType type)
{
  return this->shared_bind (id, kind, obj, type, 1);
}

int
TAO_Persistent_Bindings_Map::find (const char *id,
                                   const char *kind,
                                   CORBA::Object_ptr & obj,
                                   CosNaming::BindingType &type)
{
  TAO_Persistent_ExtId name (id, kind);
  TAO_Persistent_IntId entry;

  if (this->map_->find (name,
                        entry,
                        this->allocator_) != 0)
    return -1;
  else
    {
      ACE_DECLARE_NEW_CORBA_ENV;
      obj = orb_->string_to_object (entry.ref_, ACE_TRY_ENV);
      ACE_CHECK_RETURN (-1);
      type = entry.type_;

      return 0;
    }
}

TAO_Persistent_Bindings_Map::TAO_Persistent_Bindings_Map (CORBA::ORB_ptr orb)
  : allocator_ (0),
    map_ (0),
    orb_ (CORBA::ORB::_duplicate (orb))
{
}

TAO_Persistent_Bindings_Map::~TAO_Persistent_Bindings_Map (void)
{
}

void
TAO_Persistent_Bindings_Map::destroy (void)
{
  this->map_->ACE_Hash_Map_With_Allocator<TAO_Persistent_ExtId, TAO_Persistent_IntId>::~ACE_Hash_Map_With_Allocator ();
  this->allocator_->free (map_);
}

TAO_Persistent_Bindings_Map::HASH_MAP *
TAO_Persistent_Bindings_Map::map (void)
{
  return this->map_;
}

size_t
TAO_Persistent_Bindings_Map::total_size (void)
{
  return this->map_->total_size ();
}

size_t
TAO_Persistent_Bindings_Map::current_size (void)
{
  return map_->current_size ();
}

int
TAO_Persistent_Bindings_Map::open (size_t hash_table_size,
                                   ACE_Allocator *alloc)
{
  allocator_ = alloc;

  // Use allocator to allocate space for the hash map.
  void *hash_map = 0;
  size_t map_size = sizeof (HASH_MAP);
  hash_map = this->allocator_->malloc (map_size);

  // If allocation failed ...
  if (hash_map == 0)
    return -1;

  // Initialize allocated hash map through placement new.
  if (open_helper (hash_table_size, hash_map) == -1)
    this->allocator_->free (hash_map);

  return 0;
}

int
TAO_Persistent_Bindings_Map::open_helper (size_t hash_table_size,
                                          void *buffer)
{
  ACE_NEW_RETURN (this->map_,
                  (buffer) HASH_MAP (hash_table_size, this->allocator_),
                  -1);
  return 0;
}

void
TAO_Persistent_Bindings_Map::set (HASH_MAP *map,
                                  ACE_Allocator *alloc)
{
  allocator_ = alloc;
  map_ = map;
}

int
TAO_Persistent_Bindings_Map::shared_bind (const char * id,
                                          const char * kind,
                                          CORBA::Object_ptr obj,
                                          CosNaming::BindingType type,
                                          int rebind)
{
  // Obtain a stringified ior of <obj> (i.e., the representation we can store).
  ACE_DECLARE_NEW_CORBA_ENV;
  CORBA::String_var ref = orb_->object_to_string (obj, ACE_TRY_ENV);
  ACE_CHECK_RETURN (-1);

  // Calculate and allocate the memory we need to store this name to
  // object binding.
  size_t id_len = ACE_OS::strlen (id) + 1;
  size_t kind_len = ACE_OS::strlen (kind) + 1;
  size_t ref_len = ACE_OS::strlen (ref.in ()) + 1;
  size_t total_len = id_len + kind_len + ref_len;
  char *ptr = (char *) this->allocator_->malloc (total_len);

  // Allocation failed - bail out.
  if (ptr == 0)
    return -1;

  // Allocation succeded - place the data into the allocated memory
  // and procceed.
  else
    {
      // Note that the <ref> *must* come first to make sure we can
      // retrieve this pointer later on in unbind().
      char * ref_ptr = ptr;
      char * id_ptr =  ptr + ref_len;
      char * kind_ptr = ptr + ref_len + id_len;
      ACE_OS::strcpy (ref_ptr, ref.in ());
      ACE_OS::strcpy (id_ptr, id);
      ACE_OS::strcpy (kind_ptr, kind);

      TAO_Persistent_ExtId new_name (id_ptr, kind_ptr);
      TAO_Persistent_IntId new_entry (ref_ptr, type);
      int result = -1;

      if (rebind == 0)
        {
          // Do a normal bind.  This will fail if there's already an
          // <new_internal> with the same name.
          result = this->map_->bind (new_name, new_entry, this->allocator_);

          if (result == 1)
            {
              // Entry already existed so bind failed. Free our
              // dynamically allocated  memory.
              this->allocator_->free ((void *) ptr);
              return result;
            }
        }
      else
        // Rebind.
        {
          TAO_Persistent_ExtId old_name;
          TAO_Persistent_IntId old_entry;

          // Check that the types of old and new entries match.
          if (this->map_->find (new_name,
                                old_entry,
                                this->allocator_) == 0
              && type != old_entry.type_)
            result = -2;

          // If types match, perform rebind.
          else
            result = this->map_->rebind (new_name, new_entry,
                                         old_name, old_entry,
                                         this->allocator_);
          if (result == 1)
            {
              // Free up the old binding's memory, if it was replaced.
              // Note, this assumes that the "ref" pointer comes
              // first, and that the id, kind, and ref are contiguously
              // allocated (see beginning of this method for details).
              this->allocator_->free ((void *) old_entry.ref_);
            }
        }

      // Check for failures, and clean up dynamically allocated memory
      // if necessary.
      if (result < 0)
        this->allocator_->free ((void *) ptr);

      else
        // If bind() or rebind() succeeded, they will automatically sync
        // up the map manager entry.  However, we must sync up our
        // name/value memory.
        this->allocator_->sync (ptr, total_len);

      return result;
    }
}

TAO_Persistent_Naming_Context::TAO_Persistent_Naming_Context (PortableServer::POA_ptr poa,
                                                              const char *poa_id,
                                                              TAO_Persistent_Context_Index *context_index)

  : TAO_Hash_Naming_Context (poa,
                             poa_id),
    counter_ (0),
    persistent_context_ (0),
    index_ (context_index)
{
  ACE_NEW (this->persistent_context_,
           TAO_Persistent_Bindings_Map (context_index->orb ()));

  // Set the superclass pointer.
  context_ = persistent_context_;
}

TAO_Persistent_Naming_Context::TAO_Persistent_Naming_Context (PortableServer::POA_ptr poa,
                                                              const char *poa_id,
                                                              TAO_Persistent_Context_Index *context_index,
                                                              HASH_MAP *map,
                                                              ACE_UINT32 *counter)
  : TAO_Hash_Naming_Context (poa,
                             poa_id),
    counter_ (counter),
    persistent_context_ (0),
    index_ (context_index)
{
  ACE_NEW (this->persistent_context_,
           TAO_Persistent_Bindings_Map (context_index->orb ()));

  // Set the superclass pointer.
  context_ = persistent_context_;

  persistent_context_->set (map, index_->allocator ());
}

int
TAO_Persistent_Naming_Context::init (size_t hash_table_size)
{
  return persistent_context_->open (hash_table_size, index_->allocator ());
}

TAO_Persistent_Naming_Context::~TAO_Persistent_Naming_Context (void)
{
  // Perform appropriate cleanup based on the destruction level specified.

  if (this->destroyed_ > 1)
    {
      // Remove ourselves from context index.
      index_->unbind (poa_id_.c_str ());
      // Remove the underlying data structure from persistent storage.
      persistent_context_->destroy ();
    }
  else if (this->destroyed_ == 1)
    // Remove the underlying data structure from persistent storage.
    persistent_context_->destroy ();
}

void
TAO_Persistent_Naming_Context::set_cleanup_level (int level)
{
  this->destroyed_ = level;
}

CosNaming::NamingContext_ptr
TAO_Persistent_Naming_Context::make_new_context (PortableServer::POA_ptr poa,
                                                 const char *poa_id,
                                                 size_t context_size,
                                                 TAO_Persistent_Context_Index * ind,
                                                 CORBA::Environment &ACE_TRY_ENV)
{
  // Store the stub we will return here.
  CosNaming::NamingContext_var result;

  // Put together a servant for the new Naming Context.

  TAO_Persistent_Naming_Context *context_impl = 0;
  ACE_NEW_THROW_EX (context_impl,
                    TAO_Persistent_Naming_Context (poa,
                                                   poa_id,
                                                   ind),
                    CORBA::NO_MEMORY ());
  ACE_CHECK_RETURN (result._retn ());

  // Put <context_impl> into the auto pointer temporarily, in case next
  // allocation fails.
  ACE_Auto_Basic_Ptr<TAO_Persistent_Naming_Context> temp (context_impl);

  if (context_impl->init (context_size) == -1)
    ACE_THROW_RETURN (CORBA::NO_MEMORY (), result._retn ());

  // Insure appropriate cleanup in case of exception conditions ahead.
  context_impl->set_cleanup_level (1);

  // Register with the index of Naming Contexts.
  if (ind->bind (context_impl->poa_id_.c_str (),
                 context_impl->counter_,
                 context_impl->persistent_context_->map ()) == -1)
    ACE_THROW_RETURN (CORBA::INTERNAL (), result._retn ());

  // Insure appropriate cleanup in case of exception conditions ahead.
  context_impl->set_cleanup_level (2);

  TAO_Naming_Context *context = 0;
  ACE_NEW_THROW_EX (context,
                    TAO_Naming_Context (context_impl),
                    CORBA::NO_MEMORY ());
  ACE_CHECK_RETURN (result._retn ());

  // Let <implementation> know about it's <interface>.
  context_impl->interface (context);

  // Release auto pointer, and start using reference counting to
  // control our servant.
  temp.release ();
  PortableServer::ServantBase_var s = context;

  // Register the new context with the POA.
  PortableServer::ObjectId_var id =
    PortableServer::string_to_ObjectId (poa_id);

  poa->activate_object_with_id (id.in (),
                                context,
                                ACE_TRY_ENV);
  ACE_CHECK_RETURN (result._retn ());

  result = context->_this (ACE_TRY_ENV);
  ACE_CHECK_RETURN (CosNaming::NamingContext::_nil ());

  // Everything went smoothly, without errors - we don't need any cleanup.
  context_impl->set_cleanup_level (0);

  return result._retn ();
}

CosNaming::NamingContext_ptr
TAO_Persistent_Naming_Context::new_context (CORBA::Environment &ACE_TRY_ENV)
{
  ACE_GUARD_THROW_EX (ACE_SYNCH_RECURSIVE_MUTEX,
                      ace_mon,
                      this->lock_,
                      CORBA::INTERNAL ());
  ACE_CHECK_RETURN (CosNaming::NamingContext::_nil ());

  // Check to make sure this object didn't have <destroy> method
  // invoked on it.
  if (this->destroyed_)
    ACE_THROW_RETURN (CORBA::OBJECT_NOT_EXIST (),
                      CosNaming::NamingContext::_nil ());

  // Generate a POA id for the new context.
  char poa_id[BUFSIZ];
  ACE_OS::sprintf (poa_id,
                   "%s_%d",
                   this->poa_id_.c_str (),
                   (*this->counter_)++);

  CosNaming::NamingContext_var result =
    make_new_context (this->poa_.in (),
                      poa_id,
                      this->persistent_context_->total_size (),
                      this->index_,
                      ACE_TRY_ENV);
  ACE_CHECK_RETURN (CosNaming::NamingContext::_nil ());

  return result._retn ();
}

void
TAO_Persistent_Naming_Context::list (CORBA::ULong how_many,
                                     CosNaming::BindingList_out &bl,
                                     CosNaming::BindingIterator_out &bi,
                                     CORBA::Environment &ACE_TRY_ENV)
{
  // Allocate nil out parameters in case we won't be able to complete
  // the operation.
  bi = CosNaming::BindingIterator::_nil ();
  ACE_NEW_THROW_EX (bl,
                    CosNaming::BindingList (0),
                    CORBA::NO_MEMORY ());
  ACE_CHECK;

  // Obtain a lock before we proceed with the operation.
  ACE_GUARD_THROW_EX (ACE_SYNCH_RECURSIVE_MUTEX,
                      ace_mon,
                      this->lock_,
                      CORBA::INTERNAL ());
  ACE_CHECK;

  // Check to make sure this object didn't have <destroy> method
  // invoked on it.
  if (this->destroyed_)
    ACE_THROW (CORBA::OBJECT_NOT_EXIST ());

  // Dynamically allocate hash map iterator.
  HASH_MAP::ITERATOR *hash_iter = 0;
  ACE_NEW_THROW_EX (hash_iter,
                    HASH_MAP::ITERATOR
                    (*persistent_context_->map ()),
                    CORBA::NO_MEMORY ());
  ACE_CHECK;

  // Store <hash_iter temporarily in auto pointer, in case we'll have
  // some failures and throw an exception.
  ACE_Auto_Basic_Ptr<HASH_MAP::ITERATOR> temp (hash_iter);

  // Silliness below is required because of broken old g++!!!  E.g.,
  // without it, we could have just said HASH_MAP::ITERATOR everywhere we use ITER_DEF.
  typedef ACE_Hash_Map_With_Allocator<TAO_Persistent_ExtId, TAO_Persistent_IntId>::ITERATOR ITER_DEF;
  typedef ACE_Hash_Map_With_Allocator<TAO_Persistent_ExtId, TAO_Persistent_IntId>::ENTRY ENTRY_DEF;

  // Typedef to the type of BindingIterator servant for ease of use.
  typedef TAO_Bindings_Iterator<ITER_DEF, ENTRY_DEF> ITER_SERVANT;

  // A pointer to BindingIterator servant.
  ITER_SERVANT *bind_iter = 0;

  // Number of bindings that will go into the BindingList.
  CORBA::ULong n;

  // Calculate number of bindings that will go into bl.
  if (this->context_->current_size () > how_many)
    n = how_many;
  else
    n = this->context_->current_size ();

  // Use hash iterator to populate a BindingList with bindings.
  bl->length (n);

  ENTRY_DEF *hash_entry;

  for (CORBA::ULong i = 0; i < n; i++)
    {
      hash_iter->next (hash_entry);
      hash_iter->advance ();

      if (ITER_SERVANT::populate_binding (hash_entry, bl[i]) == 0)
          ACE_THROW (CORBA::NO_MEMORY());
    }

  // Now we are done with the BindingsList, and we can follow up on
  // the iterator business.

  // If we do not need to pass back BindingIterator.
  if (this->context_->current_size () <= how_many)
    return;
  else
    {
      // Create a BindingIterator for return.
      ACE_NEW_THROW_EX (bind_iter,
                        ITER_SERVANT (this, hash_iter, this->poa_.in (), this->lock_),
                        CORBA::NO_MEMORY ());

      // Release <hash_iter> from auto pointer, and start using the
      // reference counting to control our servant.
      temp.release ();
      PortableServer::ServantBase_var iter = bind_iter;

      // Increment reference count on this Naming Context, so it doesn't get
      // deleted before the BindingIterator servant gets deleted.
      interface_->_add_ref (ACE_TRY_ENV);
      ACE_CHECK;

      // Register with the POA.
      char poa_id[BUFSIZ];
      ACE_OS::sprintf (poa_id,
                       "%s_%ld",
                       this->poa_id_.c_str (),
                       ACE_reinterpret_cast (long,
                                             this->counter_++));
      PortableServer::ObjectId_var id =
        PortableServer::string_to_ObjectId (poa_id);

      this->poa_->activate_object_with_id (id.in (),
                                           bind_iter,
                                           ACE_TRY_ENV);
      ACE_CHECK;

      bi = bind_iter->_this (ACE_TRY_ENV);
      ACE_CHECK;
    }
}

#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) || \
    defined (ACE_HAS_GNU_REPO)

template class ACE_Hash_Map_With_Allocator<TAO_Persistent_ExtId, TAO_Persistent_IntId>;
template class ACE_Hash_Map_Manager<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>;
template class ACE_Hash_Map_Manager_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>;
template class ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId>;
template class ACE_Hash<TAO_Persistent_ExtId>;
template class ACE_Equal_To<TAO_Persistent_ExtId>;
template class ACE_Hash_Map_Iterator_Base_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>;
template class ACE_Hash_Map_Iterator<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>;
template class ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>;
template class ACE_Hash_Map_Reverse_Iterator<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>;
template class ACE_Hash_Map_Reverse_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>;
template class ACE_Auto_Basic_Ptr<TAO_Persistent_Naming_Context>;
template class ACE_Auto_Basic_Ptr<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex > >;
template class TAO_Bindings_Iterator<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>, ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId> >;
template class ACE_Auto_Basic_Ptr<TAO_Bindings_Iterator<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>, ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId> > >;

#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA)

#pragma instantiate ACE_Hash_Map_With_Allocator<TAO_Persistent_ExtId, TAO_Persistent_IntId>
#pragma instantiate ACE_Hash_Map_Manager<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Manager_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId>
#pragma instantiate ACE_Hash<TAO_Persistent_ExtId>
#pragma instantiate ACE_Equal_To<TAO_Persistent_ExtId>
#pragma instantiate ACE_Hash_Map_Iterator_Base_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Iterator<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Reverse_Iterator<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Null_Mutex>
#pragma instantiate ACE_Hash_Map_Reverse_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>
#pragma instantiate ACE_Auto_Basic_Ptr<TAO_Persistent_Naming_Context>
#pragma instantiate ACE_Auto_Basic_Ptr<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex> >
#pragma instantiate TAO_Bindings_Iterator<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>, ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId> >
#pragma instantiate ACE_Auto_Basic_Ptr<TAO_Bindings_Iterator<ACE_Hash_Map_Iterator_Ex<TAO_Persistent_ExtId, TAO_Persistent_IntId, ACE_Hash<TAO_Persistent_ExtId>, ACE_Equal_To<TAO_Persistent_ExtId>, ACE_Null_Mutex>, ACE_Hash_Map_Entry<TAO_Persistent_ExtId, TAO_Persistent_IntId> > >
#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */