Merge pull request #1844 from jrw972/monterey
[ACE_TAO.git] / TAO / orbsvcs / ImplRepo_Service / Iterator.cpp
blobf802ef93c63b5f312199b3915ddeb9a4021fffca
1 //=============================================================================
2 /**
3 * @file Iterator.cpp
5 * @brief This file declares ImR's iterator.
7 * @author Darrell Brunsch <brunsch@cs.wustl.edu>
8 */
9 //=============================================================================
11 #include "Iterator.h"
14 ImR_AsyncIterator::ImR_AsyncIterator (CORBA::ULong start,
15 AsyncListManager *lister)
16 :count_ (start),
17 lister_ (lister->_add_ref ())
21 void
22 ImR_AsyncIterator::next_n
23 (ImplementationRepository::AMH_ServerInformationIteratorResponseHandler_ptr _tao_rh,
24 CORBA::ULong how_many)
26 this->count_ = this->lister_->list (_tao_rh, this->count_, how_many);
29 void
30 ImR_AsyncIterator::destroy
31 (ImplementationRepository::AMH_ServerInformationIteratorResponseHandler_ptr _tao_rh)
33 PortableServer::POA_var poa = this->lister_->poa ();
34 PortableServer::ObjectId_var oid = poa->servant_to_id (this);
35 poa->deactivate_object (oid.in());
36 _tao_rh->destroy ();