Package net.sbbi.upnp.impls

Examples of net.sbbi.upnp.impls.InternetGatewayDevice.addPortMapping()


                InternetGatewayDevice testIGD = IGDs[0];
                System.out.println("Found device " + testIGD.getIGDRootDevice().getModelName());
                // now let's open the port
                String localHostIP = InetAddress.getLocalHost().getHostAddress();
                // we assume that localHostIP is something else than 127.0.0.1
                boolean mapped = testIGD.addPortMapping("Some mapping description",
                        null, port, port,
                        localHostIP, 0, "TCP");
                if (mapped) {
                    System.out.println("Port " + port + " mapped to " + localHostIP);
                }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.