Class Port
java.lang.Object
com.azure.resourcemanager.containerinstance.models.Port
The port exposed on the container group.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintport()Get the port property: The port number.protocol()Get the protocol property: The protocol associated with the port.voidvalidate()Validates the instance.withPort(int port) Set the port property: The port number.withProtocol(ContainerGroupNetworkProtocol protocol) Set the protocol property: The protocol associated with the port.
-
Constructor Details
-
Port
public Port()Creates an instance of Port class.
-
-
Method Details
-
protocol
Get the protocol property: The protocol associated with the port.- Returns:
- the protocol value.
-
withProtocol
Set the protocol property: The protocol associated with the port.- Parameters:
protocol- the protocol value to set.- Returns:
- the Port object itself.
-
port
public int port()Get the port property: The port number.- Returns:
- the port value.
-
withPort
Set the port property: The port number.- Parameters:
port- the port value to set.- Returns:
- the Port object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-