public class Port
extends java.lang.Object
Constructor and Description |
---|
Port() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getName() |
int |
getNodePort() |
int |
getPort() |
java.lang.String |
getProtocol() |
java.lang.String |
getTargetPort() |
boolean |
isSecure()
Attempts to guess whether this port should be connected to using SSL.
|
void |
setName(java.lang.String name) |
void |
setNodePort(int nodePort) |
void |
setPort(int port) |
void |
setProtocol(java.lang.String protocol) |
void |
setTargetPort(java.lang.String targetPort) |
java.lang.String |
toString() |
public java.lang.String getName()
public void setName(java.lang.String name)
name
- The name of this port within the servicepublic java.lang.String getProtocol()
public java.lang.String getTargetPort()
public void setProtocol(java.lang.String protocol)
protocol
- The IP protocol for this port.public void setNodePort(int nodePort)
nodePort
- The port on each node on which this service is exposed when type=NodePort or LoadBalancer.public int getPort()
public void setPort(int port)
port
- The port that will be exposed by this service.public void setTargetPort(java.lang.String targetPort)
targetPort
- Number or name of the port to access on the pods targeted by the service.public int getNodePort()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean isSecure()