X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;f=src%2Ffilter_z3950_client.cpp;h=95207d9ae4163f4426fd1961158e9e177ac55929;hb=8a595f41f5eaaa7ef846a697cfe4466ea57d224a;hp=8a5c30c9358cbe55299380567c5b304f00cb539c;hpb=b3a5a3535ff97f71581c9b496f95e0820120f743;p=metaproxy-moved-to-github.git diff --git a/src/filter_z3950_client.cpp b/src/filter_z3950_client.cpp index 8a5c30c..95207d9 100644 --- a/src/filter_z3950_client.cpp +++ b/src/filter_z3950_client.cpp @@ -1,4 +1,4 @@ -/* $Id: filter_z3950_client.cpp,v 1.5 2005-10-25 21:32:01 adam Exp $ +/* $Id: filter_z3950_client.cpp,v 1.6 2005-10-29 15:54:29 adam Exp $ Copyright (c) 2005, Index Data. %LICENSE% @@ -31,7 +31,7 @@ namespace yf = yp2::filter; namespace yp2 { namespace filter { class Z3950Client::Assoc : public yazpp_1::Z_Assoc{ - friend class Pimpl; + friend class Rep; public: Assoc(yazpp_1::SocketManager *socket_manager, yazpp_1::IPDU_Observable *PDU_Observable, @@ -54,7 +54,7 @@ namespace yp2 { std::string m_host; }; - class Z3950Client::Pimpl { + class Z3950Client::Rep { public: boost::mutex m_mutex; std::map m_clients; @@ -144,15 +144,14 @@ yazpp_1::IPDU_Observer *yf::Z3950Client::Assoc::sessionNotify( } -yf::Z3950Client::Z3950Client() { - m_p = new yf::Z3950Client::Pimpl; +yf::Z3950Client::Z3950Client() : m_p(new yf::Z3950Client::Rep) +{ } yf::Z3950Client::~Z3950Client() { - delete m_p; } -yf::Z3950Client::Assoc *yf::Z3950Client::Pimpl::get_assoc(Package &package) +yf::Z3950Client::Assoc *yf::Z3950Client::Rep::get_assoc(Package &package) { // only one thread messes with the clients list at a time boost::mutex::scoped_lock lock(m_mutex); @@ -218,7 +217,7 @@ yf::Z3950Client::Assoc *yf::Z3950Client::Pimpl::get_assoc(Package &package) return as; } -void yf::Z3950Client::Pimpl::send_and_receive(Package &package, +void yf::Z3950Client::Rep::send_and_receive(Package &package, yf::Z3950Client::Assoc *c) { Z_GDU *gdu = package.request().get(); @@ -253,7 +252,7 @@ void yf::Z3950Client::Pimpl::send_and_receive(Package &package, ; } -void yf::Z3950Client::Pimpl::release_assoc(Package &package, +void yf::Z3950Client::Rep::release_assoc(Package &package, yf::Z3950Client::Assoc *c) { if (package.session().is_closed())