summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2012-07-15 07:42:42 (GMT)
committerRemko Tronçon <git@el-tramo.be>2012-07-15 07:42:42 (GMT)
commit562e37bca8ec283a382964e29ccb0ec0e4ba9d0f (patch)
tree1bbeaf3c935be8baa86fac3ef8f54e4dadc948f7 /Swiften/Network/MiniUPnPInterface.h
parent7a591138e89ad71ee1dd9825d7705c94f9bb50d2 (diff)
downloadswift-contrib-562e37bca8ec283a382964e29ccb0ec0e4ba9d0f.zip
swift-contrib-562e37bca8ec283a382964e29ccb0ec0e4ba9d0f.tar.bz2
Hide libminiupnp and libnatpmp.
Diffstat (limited to 'Swiften/Network/MiniUPnPInterface.h')
-rw-r--r--Swiften/Network/MiniUPnPInterface.h15
1 files changed, 5 insertions, 10 deletions
diff --git a/Swiften/Network/MiniUPnPInterface.h b/Swiften/Network/MiniUPnPInterface.h
index ae9be66..ced7db2 100644
--- a/Swiften/Network/MiniUPnPInterface.h
+++ b/Swiften/Network/MiniUPnPInterface.h
@@ -7,30 +7,25 @@
#pragma once
#include <boost/optional.hpp>
-#include <miniupnpc.h>
+#include <boost/noncopyable.hpp>
#include <Swiften/Network/NATPortMapping.h>
#include <Swiften/Network/NATTraversalInterface.h>
namespace Swift {
- class MiniUPnPInterface : public NATTraversalInterface {
+ class MiniUPnPInterface : public NATTraversalInterface, boost::noncopyable {
public:
MiniUPnPInterface();
~MiniUPnPInterface();
- virtual bool isAvailable() {
- return isValid;
- }
+ virtual bool isAvailable();
boost::optional<HostAddress> getPublicIP();
boost::optional<NATPortMapping> addPortForward(int localPort, int publicPort);
bool removePortForward(const NATPortMapping&);
private:
- bool isValid;
- std::string localAddress;
- UPNPDev* deviceList;
- UPNPUrls urls;
- IGDdatas data;
+ class Private;
+ boost::shared_ptr<Private> p;
};
}