1 /* $Id: p2_frontend.cpp,v 1.1 2005-10-06 09:37:25 marc Exp $
2 Copyright (c) 1998-2005, Index Data.
4 This file is part of the yaz-proxy.
6 YAZ proxy is free software; you can redistribute it and/or modify it under
7 the terms of the GNU General Public License as published by the Free
8 Software Foundation; either version 2, or (at your option) any later
11 YAZ proxy is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16 You should have received a copy of the GNU General Public License
17 along with YAZ proxy; see the file LICENSE. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
23 #include <yaz/diagbib1.h>
24 #include "p2_frontend.h"
26 using namespace yazpp_1;
29 P2_Frontend::P2_Frontend(IPDU_Observable *the_PDU_Observable,
30 Msg_Thread *my_thread, P2_Server *server)
31 : Z_Assoc(the_PDU_Observable)
33 m_my_thread = my_thread;
37 yaz_log(YLOG_LOG, "Construct P2_Frontend=%p", this);
41 IPDU_Observer *P2_Frontend::sessionNotify(IPDU_Observable
42 *the_PDU_Observable, int fd)
47 P2_Frontend::~P2_Frontend()
49 yaz_log(YLOG_LOG, "Destroy P2_Frontend=%p", this);
51 list<P2_FrontResultSet *>::iterator it;
53 for (it = m_resultSets.begin(); it != m_resultSets.end(); it++)
60 void P2_Frontend::recv_GDU(Z_GDU *z_pdu, int len)
62 GDU *gdu = new GDU(z_pdu);
64 P2_Msg *m = new P2_Msg(gdu, this, m_server);
69 void P2_Frontend::failNotify()
72 if (m_no_requests == 0)
77 void P2_Frontend::timeoutNotify()
80 if (m_no_requests == 0)
84 void P2_Frontend::connectNotify()
92 * indent-tabs-mode: nil
94 * vim: shiftwidth=4 tabstop=8 expandtab