Interface FirewallPolicyRuleMatcherLayer4ConfigOrBuilder (1.58.0)

public interface FirewallPolicyRuleMatcherLayer4ConfigOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getIpProtocol()

public abstract String getIpProtocol()

The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.

optional string ip_protocol = 475958960;

Returns
Type Description
String

The ipProtocol.

getIpProtocolBytes()

public abstract ByteString getIpProtocolBytes()

The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.

optional string ip_protocol = 475958960;

Returns
Type Description
ByteString

The bytes for ipProtocol.

getPorts(int index)

public abstract String getPorts(int index)

An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: ["22"], ["80","443"], and ["12345-12349"].

repeated string ports = 106854418;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The ports at the given index.

getPortsBytes(int index)

public abstract ByteString getPortsBytes(int index)

An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: ["22"], ["80","443"], and ["12345-12349"].

repeated string ports = 106854418;

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the ports at the given index.

getPortsCount()

public abstract int getPortsCount()

An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: ["22"], ["80","443"], and ["12345-12349"].

repeated string ports = 106854418;

Returns
Type Description
int

The count of ports.

getPortsList()

public abstract List<String> getPortsList()

An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: ["22"], ["80","443"], and ["12345-12349"].

repeated string ports = 106854418;

Returns
Type Description
List<String>

A list containing the ports.

hasIpProtocol()

public abstract boolean hasIpProtocol()

The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.

optional string ip_protocol = 475958960;

Returns
Type Description
boolean

Whether the ipProtocol field is set.