Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   Related Pages  

UnicastRequestEvent.cc

00001 /*
00002  * Copyright 2003 Michael A. Marsh, Cornell University. All rights reserved.
00003  * This software is released under the modified BSD license.
00004  * See the file LICENSE in the top-level directory for details.
00005  */
00006 //
00007 // $Id: UnicastRequestEvent.cc,v 1.3 2004/05/19 15:56:59 mmarsh Exp $
00008 //
00009 // $Log: UnicastRequestEvent.cc,v $
00010 // Revision 1.3  2004/05/19 15:56:59  mmarsh
00011 // *** empty log message ***
00012 //
00013 // Revision 1.2  2003/11/04 22:31:51  mmarsh
00014 // *** empty log message ***
00015 //
00016 //
00017 
00018 #include "UnicastRequestEvent.h"
00019 #include "ServerState.h"
00020 
00021 #include "ServerExceptions.h"
00022 
00023 using namespace CODEX_Server;
00024 
00025 UnicastRequestEvent::UnicastRequestEvent(
00026    CODEX_Events::Activity* source,
00027    UnicastRequestHandler* destination,
00028    const CODEX_Quorum::MessageVector& messages,
00029    const unsigned char* key,
00030    CODEX_Quorum::ResponseCallback* cb ) :
00031    CODEX_Events::EventBase( source ),
00032    m_destination( destination ),
00033    m_messages( messages ),
00034    m_cb( cb ),
00035    m_bcast( false ),
00036    m_time( 0 )
00037 {
00038    memcpy( m_key, key, ServerState::nMID );
00039    CODEX_Quorum::QuorumSystem* qs = ServerState::instance()->quorumSystem();
00040    if ( NULL == qs )
00041    {
00042       throw NoQuorumSystemException( __FILE__ , __LINE__ );
00043    }
00044    for ( unsigned int i = 0 ; i < qs->quorumSystemSize() ; ++i )
00045    {
00046       m_retVals.push_back(CODEX_Quorum::RemoteServerReturn());
00047    }
00048 }
00049 
00050 UnicastRequestEvent::~UnicastRequestEvent()
00051 {
00052 }

Generated on Wed Jun 2 16:32:57 2004 for COrnell Data EXchange (CODEX) by doxygen1.2.18