Dangerous SNMP
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Pages
tcp.hpp
1 #pragma once
2 
3 #include "dangerous/snmp/exception.hpp"
4 
5 #include "basicsockettransport.hpp"
6 
7 
8 namespace dangerous { namespace snmp { namespace transport {
9 
13 class Tcp : public BasicSocketTransport {
14 public:
15  const unsigned int MINIMUM_MESSAGE_SIZE = 8192; //< See http://tools.ietf.org/html/rfc3430, section 2.2.
16  const unsigned int RECOMMENDED_MESSAGE_SIZE = 8192; //< TODO:???
17 
18 public:
28  Tcp( std::weak_ptr<Context::PrivateData> context, const std::string& connectionString ) throw( Exception );
29 
30 protected:
31  virtual int socketOptions() const;
32  virtual int protocolNumber() const;
33 };
34 
35 } } }
36 
virtual int protocolNumber() const
When creating a socket, this is called to set the protocol that should be passed to the call...
This is the base class of both the UDP and TCP transports.
Definition: basicsockettransport.hpp:16
This defines the base exception class for Dangerous SNMP.
Definition: exception.hpp:10
This is the TCP transport (see http://tools.ietf.org/html/rfc3430).
Definition: tcp.hpp:13
virtual int socketOptions() const
When creating a socket, this is called to set the options that should be passed to the call...
Tcp(std::weak_ptr< Context::PrivateData > context, const std::string &connectionString)
This instantiates a new TCP transport instance.