X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Socket%2FSocketHandle.cc;h=aa0cf61fef20b4dc9d9380cb2f993492516aa751;hb=a1fdb7bb122f0b05be809a922d4b7ef5e125fa67;hp=3878a362c77c57d833ad09716d45ce5022a9113e;hpb=171b7d9c23896219fc63a6c4a75fc86dfd4bb042;p=senf.git diff --git a/Socket/SocketHandle.cc b/Socket/SocketHandle.cc index 3878a36..aa0cf61 100644 --- a/Socket/SocketHandle.cc +++ b/Socket/SocketHandle.cc @@ -1,9 +1,9 @@ // $Id$ // // Copyright (C) 2006 -// Fraunhofer Institut fuer offene Kommunikationssysteme (FOKUS) -// Kompetenzzentrum fuer Satelitenkommunikation (SatCom) -// Stefan Bund +// Fraunhofer Institute for Open Communication Systems (FOKUS) +// Competence Center NETwork research (NET), St. Augustin, GERMANY +// Stefan Bund // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by @@ -36,6 +36,19 @@ #define prefix_ ///////////////////////////////cc.p//////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////// +// senf::SocketBody + +prefix_ void senf::SocketBody::state(SocketStateMap & map, unsigned lod) +{ + map["file.handle"] << fd(); + map["file.refcount"] << refcount(); + map["socket.server"] << isServer(); + map["socket.protocol"] << v_protocolName(); + map["socket.protocol.policy"] << prettyName(typeid(protocol().policy())); + protocol().state(map,lod); +} + prefix_ void senf::SocketBody::v_close() { protocol().close(); @@ -52,16 +65,6 @@ prefix_ bool senf::SocketBody::v_eof() return protocol().eof(); } -prefix_ void senf::SocketBody::state(SocketStateMap & map, unsigned lod) -{ - map["file.handle"] = fd(); - map["file.refcount"] = refcount(); - map["socket.server"] = isServer(); - map["socket.protocol"] = prettyName(typeid(protocol())); - map["socket.policy"] = prettyName(typeid(protocol().policy())); - protocol().state(map,lod); -} - /////////////////////////////////////////////////////////////////////////// // senf::detail::StateMapOrdering @@ -85,13 +88,6 @@ prefix_ std::string senf::detail::dumpState(SocketStateMap const & map) return s.str(); } -template -prefix_ std::ostream & senf::operator<<(std::ostream & os, SocketHandle handle) -{ - os << handle.dumpState(); - return os; -} - ///////////////////////////////cc.e//////////////////////////////////////// #undef prefix_ //#include "SocketHandle.mpp"