Examples of Allowed


Examples of com.google.api.services.compute.model.Firewall.Allowed

      if (matchingRule == null) {
        Firewall rule = new Firewall();
        rule.setSourceRanges(Arrays.asList("0.0.0.0/0"));
        rule.setName("pl-" + UUID.randomUUID().toString());

        Allowed allowed = new Allowed();
        allowed.setIPProtocol("tcp");
        allowed.setPorts(Arrays.asList("" + model.publicPort));
        rule.setAllowed(Arrays.asList(allowed));

        rule.setNetwork(client.buildNetworkUrl("default"));

        client.createFirewallRule(rule);
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.