// $Id$
//
-// Copyright (C) 2006
-// Fraunhofer Institut fuer offene Kommunikationssysteme (FOKUS)
-// Kompetenzzentrum fuer Satelitenkommunikation (SatCom)
-// Stefan Bund <stefan.bund@fokus.fraunhofer.de>
+// Copyright (C) 2006
+// Fraunhofer Institute for Open Communication Systems (FOKUS)
+// Competence Center NETwork research (NET), St. Augustin, GERMANY
+// Stefan Bund <g0dil@berlios.de>
//
// 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
//#include "SocketPolicy.test.mpp"
///////////////////////////////hh.p////////////////////////////////////////
-namespace satcom {
-namespace lib {
+namespace senf {
namespace test {
- struct SomeAddressingPolicy : public satcom::lib::AddressingPolicyBase
+ struct SomeAddressingPolicy : public senf::AddressingPolicyBase
{
typedef unsigned Address;
-
+
static void peer(FileHandle handle, unsigned & addr)
{ addr=1; }
static void local(FileHandle, unsigned & addr)
{}
};
- struct SomeFramingPolicy : public satcom::lib::FramingPolicyBase
+ struct SomeFramingPolicy : public senf::FramingPolicyBase
{};
- struct SomeCommunicationPolicy : public satcom::lib::CommunicationPolicyBase
+ struct SomeCommunicationPolicy : public senf::CommunicationPolicyBase
{
static int accept(FileHandle handle, unsigned & addr)
{ addr = 3; return -1; }
+ static int accept(FileHandle handle)
+ { return -1; }
};
- struct SomeReadPolicy : public satcom::lib::ReadPolicyBase
+ struct SomeReadPolicy : public senf::ReadPolicyBase
{
static unsigned const TEST_SIZE = 9;
}
};
- struct SomeWritePolicy : public satcom::lib::WritePolicyBase
+ struct SomeWritePolicy : public senf::WritePolicyBase
{
static unsigned write(FileHandle handle, char const * buffer, unsigned size)
{
return write(handle,buffer,size);
}
};
-
- struct SomeBufferingPolicy : public satcom::lib::BufferingPolicyBase
- {
- static unsigned rcvbuf(FileHandle handle)
- { return 0; }
- static unsigned rcvbuf(FileHandle handle, unsigned size)
- { return 0; }
-
- static unsigned sndbuf(FileHandle handle)
- { return 0; }
- static unsigned sndbuf(FileHandle handle, unsigned size)
- { return 0; }
- };
- typedef satcom::lib::MakeSocketPolicy<
+ typedef senf::MakeSocketPolicy<
SomeAddressingPolicy,
SomeFramingPolicy,
SomeCommunicationPolicy,
SomeReadPolicy,
- SomeWritePolicy,
- SomeBufferingPolicy
+ SomeWritePolicy
>::policy SomeSocketPolicy;
-}}}
+}}
///////////////////////////////hh.e////////////////////////////////////////
//#include "SocketPolicy.test.cci"
\f
// Local Variables:
// mode: c++
-// c-file-style: "satcom"
+// fill-column: 100
+// c-file-style: "senf"
+// indent-tabs-mode: nil
+// ispell-local-dictionary: "american"
+// compile-command: "scons -u test"
+// comment-column: 40
// End: