Equalizer 1.0
|
00001 00002 /* Copyright (c) 2005-2010, Stefan Eilemann <eile@equalizergraphics.com> 00003 * 2010, Cedric Stalder <cedric.stalder@gmail.com> 00004 * 00005 * This library is free software; you can redistribute it and/or modify it under 00006 * the terms of the GNU Lesser General Public License version 2.1 as published 00007 * by the Free Software Foundation. 00008 * 00009 * This library is distributed in the hope that it will be useful, but WITHOUT 00010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 00011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 00012 * details. 00013 * 00014 * You should have received a copy of the GNU Lesser General Public License 00015 * along with this library; if not, write to the Free Software Foundation, Inc., 00016 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 00017 */ 00018 00019 #ifndef EQFABRIC_SERVERPACKETS_H 00020 #define EQFABRIC_SERVERPACKETS_H 00021 00022 #include <eq/fabric/packets.h> // base structs 00023 00025 namespace eq 00026 { 00027 namespace fabric 00028 { 00029 struct ServerCreateConfigPacket : public ServerPacket 00030 { 00031 ServerCreateConfigPacket() 00032 : requestID( EQ_UNDEFINED_UINT32 ) 00033 { 00034 command = CMD_SERVER_CREATE_CONFIG; 00035 size = sizeof( ServerCreateConfigPacket ); 00036 } 00037 00038 co::ObjectVersion configVersion; 00039 uint32_t requestID; 00040 }; 00041 00042 struct ServerDestroyConfigPacket : public ServerPacket 00043 { 00044 ServerDestroyConfigPacket() 00045 : requestID ( EQ_UNDEFINED_UINT32 ) 00046 { 00047 command = CMD_SERVER_DESTROY_CONFIG; 00048 size = sizeof( ServerDestroyConfigPacket ); 00049 } 00050 00051 co::base::UUID configID; 00052 uint32_t requestID; 00053 }; 00054 00055 struct ServerDestroyConfigReplyPacket : public ServerPacket 00056 { 00057 ServerDestroyConfigReplyPacket( 00058 const ServerDestroyConfigPacket* request ) 00059 { 00060 command = CMD_SERVER_DESTROY_CONFIG_REPLY; 00061 size = sizeof( ServerDestroyConfigReplyPacket ); 00062 requestID = request->requestID; 00063 } 00064 00065 uint32_t requestID; 00066 }; 00067 00068 inline std::ostream& operator << ( std::ostream& os, 00069 const ServerCreateConfigPacket* packet ) 00070 { 00071 os << (ServerPacket*)packet << " config version " 00072 << packet->configVersion << " request " << packet->requestID; 00073 return os; 00074 } 00075 } 00076 } 00078 #endif //EQFABRIC_SERVERPACKETS_H