Class IpPermission
- java.lang.Object
-
- com.amazonaws.services.gamelift.model.IpPermission
-
- All Implemented Interfaces:
Serializable,Cloneable
public class IpPermission extends Object implements Serializable, Cloneable
IP addresses and port settings used to limit access by incoming traffic (players) to a fleet. Permissions specify a range of IP addresses and port settings that must be used to gain access to a game server on a fleet machine.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description IpPermission()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IpPermissionclone()booleanequals(Object obj)IntegergetFromPort()Starting value for a range of allowed port numbers.StringgetIpRange()Range of allowed IP addresses.StringgetProtocol()Network communication protocol used by the fleet.IntegergetToPort()Ending value for a range of allowed port numbers.inthashCode()voidsetFromPort(Integer fromPort)Starting value for a range of allowed port numbers.voidsetIpRange(String ipRange)Range of allowed IP addresses.voidsetProtocol(IpProtocol protocol)Network communication protocol used by the fleet.voidsetProtocol(String protocol)Network communication protocol used by the fleet.voidsetToPort(Integer toPort)Ending value for a range of allowed port numbers.StringtoString()Returns a string representation of this object; useful for testing and debugging.IpPermissionwithFromPort(Integer fromPort)Starting value for a range of allowed port numbers.IpPermissionwithIpRange(String ipRange)Range of allowed IP addresses.IpPermissionwithProtocol(IpProtocol protocol)Network communication protocol used by the fleet.IpPermissionwithProtocol(String protocol)Network communication protocol used by the fleet.IpPermissionwithToPort(Integer toPort)Ending value for a range of allowed port numbers.
-
-
-
Method Detail
-
setFromPort
public void setFromPort(Integer fromPort)
Starting value for a range of allowed port numbers.
- Parameters:
fromPort- Starting value for a range of allowed port numbers.
-
getFromPort
public Integer getFromPort()
Starting value for a range of allowed port numbers.
- Returns:
- Starting value for a range of allowed port numbers.
-
withFromPort
public IpPermission withFromPort(Integer fromPort)
Starting value for a range of allowed port numbers.
- Parameters:
fromPort- Starting value for a range of allowed port numbers.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setToPort
public void setToPort(Integer toPort)
Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.
- Parameters:
toPort- Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.
-
getToPort
public Integer getToPort()
Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.
- Returns:
- Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.
-
withToPort
public IpPermission withToPort(Integer toPort)
Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.
- Parameters:
toPort- Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setIpRange
public void setIpRange(String ipRange)
Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "
000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".- Parameters:
ipRange- Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".
-
getIpRange
public String getIpRange()
Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "
000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".- Returns:
- Range of allowed IP addresses. This value must be expressed in CIDR notation. Example:
"
000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".
-
withIpRange
public IpPermission withIpRange(String ipRange)
Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "
000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".- Parameters:
ipRange- Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "000.000.000.000/[subnet mask]" or optionally the shortened version "0.0.0.0/[subnet mask]".- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setProtocol
public void setProtocol(String protocol)
Network communication protocol used by the fleet.
- Parameters:
protocol- Network communication protocol used by the fleet.- See Also:
IpProtocol
-
getProtocol
public String getProtocol()
Network communication protocol used by the fleet.
- Returns:
- Network communication protocol used by the fleet.
- See Also:
IpProtocol
-
withProtocol
public IpPermission withProtocol(String protocol)
Network communication protocol used by the fleet.
- Parameters:
protocol- Network communication protocol used by the fleet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
IpProtocol
-
setProtocol
public void setProtocol(IpProtocol protocol)
Network communication protocol used by the fleet.
- Parameters:
protocol- Network communication protocol used by the fleet.- See Also:
IpProtocol
-
withProtocol
public IpPermission withProtocol(IpProtocol protocol)
Network communication protocol used by the fleet.
- Parameters:
protocol- Network communication protocol used by the fleet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
IpProtocol
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toStringin classObject- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public IpPermission clone()
-
-