X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Socket%2FReadWritePolicy.cti;h=edb7915c94deafbdfe5b7a5e21cf565b481681ca;hb=6927c87144ca23845065e3c23e37c75f5f059cf3;hp=d9c065de014d054182ae281050aefc6c38065486;hpb=d0006132bfcb3ab442cf66b600ed3fad36f1ac2c;p=senf.git diff --git a/Socket/ReadWritePolicy.cti b/Socket/ReadWritePolicy.cti index d9c065d..edb7915 100644 --- a/Socket/ReadWritePolicy.cti +++ b/Socket/ReadWritePolicy.cti @@ -1,9 +1,9 @@ // $Id$ // -// Copyright (C) 2006 -// Fraunhofer Institut fuer offene Kommunikationssysteme (FOKUS) -// Kompetenzzentrum fuer Satelitenkommunikation (SatCom) -// Stefan Bund +// Copyright (C) 2006 +// 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 @@ -31,32 +31,56 @@ #define prefix_ inline ///////////////////////////////cti.p/////////////////////////////////////// -template +#ifndef DOXYGEN +template prefix_ unsigned senf::ReadablePolicy:: -readfrom(ClientSocketHandle handle, char * buffer, unsigned size, - typename Policy::AddressingPolicy::Address & address, - typename IfCommunicationPolicyIs::type *) +readfrom(ClientSocketHandle handle, char * buffer, unsigned size, + typename SPolicy::AddressingPolicy::Address & address, + typename IfCommunicationPolicyIs::type *) { - return do_rcvfrom(handle, buffer, size, address.sockaddr_p(), address.sockaddr_len()); + return do_readfrom(handle, buffer, size, address.sockaddr_p(), address.socklen_p()); } +#else +template +prefix_ unsigned senf::ReadablePolicy:: +readfrom(ClientSocketHandle handle, char * buffer, unsigned size, + typename Policy::AddressingPolicy::Address & address) +{} +#endif -template +#ifndef DOXYGEN +template prefix_ unsigned senf::WriteablePolicy:: -write(ClientSocketHandle handle, char const * buffer, unsigned size, - typename IfCommunicationPolicyIs::type *) +write(ClientSocketHandle handle, char const * buffer, unsigned size, + typename IfCommunicationPolicyIs::type *) { return do_write(handle,buffer,size); } +#else +template +prefix_ unsigned senf::WriteablePolicy:: +write(ClientSocketHandle handle, char const * buffer, unsigned size) +{} +#endif -template +#ifndef DOXYGEN +template prefix_ unsigned senf::WriteablePolicy:: -writeto(ClientSocketHandle handle, - typename boost::call_traits::param_type addr, +writeto(ClientSocketHandle handle, + typename boost::call_traits::param_type addr, char const * buffer, unsigned size, - typename IfCommunicationPolicyIs::type *) + typename IfCommunicationPolicyIs::type *) { - return do_writeto(handle, buffer, size, addr.sockaddr_p(), addr.sockaddr_len()); + return do_writeto(handle, buffer, size, addr.sockaddr_p(), addr.socklen()); } +#else +template +prefix_ unsigned senf::WriteablePolicy:: +writeto(ClientSocketHandle handle, + typename Policy::AddressingPolicy::Address const & addr, + char const * buffer, unsigned size) +{} +#endif ///////////////////////////////cti.e/////////////////////////////////////// #undef prefix_ @@ -64,5 +88,10 @@ writeto(ClientSocketHandle handle, // Local Variables: // mode: c++ +// fill-column: 100 // c-file-style: "senf" +// indent-tabs-mode: nil +// ispell-local-dictionary: "american" +// compile-command: "scons -u test" +// comment-column: 40 // End: