NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.0: NDN, CCN, CCNx, content centric networks
API Documentation
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
unix-transport.hpp
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
22
#ifndef NDN_TRANSPORT_UNIX_TRANSPORT_HPP
23
#define NDN_TRANSPORT_UNIX_TRANSPORT_HPP
24
25
#include "../common.hpp"
26
#include "
transport.hpp
"
27
#include "../util/config-file.hpp"
28
29
// forward declaration
30
namespace
boost
{
namespace
asio {
namespace
local {
class
stream_protocol; } } }
31
32
namespace
ndn
{
33
34
// forward declaration
35
template
<
class
T,
class
U>
36
class
StreamTransportImpl;
37
38
class
UnixTransport
:
public
Transport
39
{
40
public
:
41
48
UnixTransport
(
const
std::string& unixSocket);
49
50
~
UnixTransport
();
51
52
// from Transport
53
virtual
void
54
connect(boost::asio::io_service& ioService,
55
const
ReceiveCallback
& receiveCallback);
56
57
virtual
void
58
close();
59
60
virtual
void
61
pause();
62
63
virtual
void
64
resume();
65
66
virtual
void
67
send(
const
Block
& wire);
68
69
virtual
void
70
send(
const
Block
& header,
const
Block
& payload);
71
72
static
shared_ptr<UnixTransport>
73
create(
const
ConfigFile
& config);
74
75
NDN_CXX_PUBLIC_WITH_TESTS_ELSE_PRIVATE
:
82
static
std::string
83
getDefaultSocketName(
const
ConfigFile
& config);
84
85
private
:
86
std::string m_unixSocket;
87
88
typedef
StreamTransportImpl<UnixTransport, boost::asio::local::stream_protocol>
Impl
;
89
friend
class
StreamTransportImpl
<
UnixTransport
,
boost
::asio::local::stream_protocol>;
90
shared_ptr< Impl > m_impl;
91
};
92
93
}
// namespace ndn
94
95
#endif // NDN_TRANSPORT_UNIX_TRANSPORT_HPP
ndn::UnixTransport
Definition:
unix-transport.hpp:38
ndn
Copyright (c) 2011-2015 Regents of the University of California.
Definition:
ndn-strategy-choice-helper.hpp:34
boost
Copyright (c) 2013-2015 Regents of the University of California.
Definition:
ndn-content-store.hpp:209
NDN_CXX_PUBLIC_WITH_TESTS_ELSE_PRIVATE
#define NDN_CXX_PUBLIC_WITH_TESTS_ELSE_PRIVATE
Definition:
common.hpp:43
ndn::Block
Class representing a wire element of NDN-TLV packet format.
Definition:
block.hpp:43
ndn::StreamTransportImpl
Definition:
stream-transport.hpp:32
ndn::Transport::ReceiveCallback
function< void(const Block &wire)> ReceiveCallback
Definition:
transport.hpp:42
ndn::Transport
Definition:
transport.hpp:32
ndn::ConfigFile
Definition:
config-file.hpp:34
transport.hpp
ndnSIM
ndn-cxx
src
transport
unix-transport.hpp
Generated on Tue Feb 23 2016 22:18:44 for ndnSIM by
1.8.11