public ToSourceSelection to(int port) { return new ToSourceSelection(getIpProtocol(), getFromPort(), port); } }
public ToSourceSelection port(int port) { return new ToSourceSelection(getIpProtocol(), port, port); } }
public ToSourceSelection andCode(int code) { return new ToSourceSelection(getIpProtocol(), getFromPort(), code); }
public IpPermissions originatingFromSecurityGroupIds(Iterable<String> groupIds) { return new IpPermissions(getIpProtocol(), getFromPort(), getToPort(), getTenantIdGroupNamePairs(), groupIds, ImmutableSet.<String> of()); } }
public IpPermissions toTenantsGroupsNamed(Multimap<String, String> tenantIdGroupNamePairs) { return new IpPermissions(getIpProtocol(), getFromPort(), getToPort(), tenantIdGroupNamePairs, getGroupIds(), ImmutableSet.<String> of()); } }
public void testProtocolFromAndToPortAndGroupIds() { IpPermissions authorization = IpPermissions.permit(IpProtocol.UDP).fromPort(11).to(53) .originatingFromSecurityGroupId("groupId"); assertEquals(authorization, IpPermission.builder().ipProtocol(IpProtocol.UDP).fromPort(11).toPort(53) .groupId("groupId").build()); }
public ToPortSelection fromPort(int port) { return new ToPortSelection(getIpProtocol(), port); }
public void testProtocolICMPTypeCode() { IpPermissions authorization = IpPermissions.permitICMP().type(8).andCode(0).originatingFromSecurityGroupId( "groupId"); assertEquals(authorization, IpPermission.builder().ipProtocol(IpProtocol.ICMP).fromPort(8).toPort(0).groupId( "groupId").build()); }
/** * @param type ex. 8 for ECHO (i.e. Ping) * @see <a href="http://www.iana.org/assignments/icmp-parameters/icmp-parameters.xml"> ICMP Types</a> */ public AndCodeSelection type(int type) { return new AndCodeSelection(type); } }
public ToSourceSelection to(int port) { return new ToSourceSelection(getIpProtocol(), getFromPort(), port); } }
public ToSourceSelection andCode(int code) { return new ToSourceSelection(getIpProtocol(), getFromPort(), code); }
public ToSourceSelection port(int port) { return new ToSourceSelection(getIpProtocol(), port, port); } }
public ToPortSelection fromPort(int port) { return new ToPortSelection(getIpProtocol(), port); }
/** * @param type ex. 8 for ECHO (i.e. Ping) * @see <a href="http://www.iana.org/assignments/icmp-parameters/icmp-parameters.xml"> ICMP Types</a> */ public AndCodeSelection type(int type) { return new AndCodeSelection(type); } }
public ToSourceSelection to(int port) { return new ToSourceSelection(getIpProtocol(), getFromPort(), port); } }
public ToSourceSelection andCode(int code) { return new ToSourceSelection(getIpProtocol(), getFromPort(), code); }
public ToSourceSelection port(int port) { return new ToSourceSelection(getIpProtocol(), port, port); } }
public ToPortSelection fromPort(int port) { return new ToPortSelection(getIpProtocol(), port); }
public ToSourceSelection to(int port) { return new ToSourceSelection(getIpProtocol(), getFromPort(), port); } }
public ToSourceSelection port(int port) { return new ToSourceSelection(getIpProtocol(), port, port); } }