Fabcoin Core
0.16.2
P2P Digital Currency
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
src
cpp-ethereum
libp2p
UPnP.h
Go to the documentation of this file.
1
/*
2
This file is part of cpp-ethereum.
3
4
cpp-ethereum is free software: you can redistribute it and/or modify
5
it under the terms of the GNU General Public License as published by
6
the Free Software Foundation, either version 3 of the License, or
7
(at your option) any later version.
8
9
cpp-ethereum is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
GNU General Public License for more details.
13
14
You should have received a copy of the GNU General Public License
15
along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
16
*/
23
#pragma once
24
25
#include <set>
26
#include <string>
27
#include <memory>
28
#include <thread>
29
30
struct
UPNPUrls;
31
struct
IGDdatas;
32
33
namespace
dev
34
{
35
namespace
p2p
36
{
37
38
class
UPnP
39
{
40
public
:
41
UPnP
();
42
~UPnP
();
43
44
std::string
externalIP
();
45
int
addRedirect
(
char
const
* addr,
int
port);
46
void
removeRedirect
(
int
port);
47
48
bool
isValid
()
const
{
return
m_ok
; }
49
50
private
:
51
std::set<int>
m_reg
;
52
bool
m_ok
;
53
std::shared_ptr<UPNPUrls>
m_urls
;
54
std::shared_ptr<IGDdatas>
m_data
;
55
};
56
57
}
58
}
dev
Adapted from code found on http://stackoverflow.com/questions/180947/base64-decode-snippet-in-c Origi...
Definition:
Arith256.cpp:15
dev::p2p::UPnP::~UPnP
~UPnP()
Definition:
UPnP.cpp:103
dev::p2p::UPnP::isValid
bool isValid() const
Definition:
UPnP.h:48
dev::p2p::UPnP::m_reg
std::set< int > m_reg
Definition:
UPnP.h:51
dev::p2p::UPnP::m_ok
bool m_ok
Definition:
UPnP.h:52
dev::p2p::UPnP::m_urls
std::shared_ptr< UPNPUrls > m_urls
Definition:
UPnP.h:53
dev::p2p::UPnP::removeRedirect
void removeRedirect(int port)
Definition:
UPnP.cpp:179
dev::p2p::UPnP::m_data
std::shared_ptr< IGDdatas > m_data
Definition:
UPnP.h:54
dev::p2p::UPnP::externalIP
std::string externalIP()
Definition:
UPnP.cpp:110
dev::p2p::UPnP
Definition:
UPnP.h:38
dev::p2p::UPnP::UPnP
UPnP()
Definition:
UPnP.cpp:41
p2p
dev::p2p::UPnP::addRedirect
int addRedirect(char const *addr, int port)
Definition:
UPnP.cpp:121
Generated on Mon Oct 22 2018 15:15:29 for Fabcoin Core by
1.8.11