public static final class NamedPort.Builder extends GeneratedMessage.Builder<NamedPort.Builder> implements NamedPortOrBuilderThe named port. For example: <"http", 80>.
Protobuf type google.cloud.compute.v1.NamedPort
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > NamedPort.BuilderImplements
NamedPortOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public NamedPort build()| Returns | |
|---|---|
| Type | Description |
NamedPort |
|
buildPartial()
public NamedPort buildPartial()| Returns | |
|---|---|
| Type | Description |
NamedPort |
|
clear()
public NamedPort.Builder clear()| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
|
clearName()
public NamedPort.Builder clearName()The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
This builder for chaining. |
clearPort()
public NamedPort.Builder clearPort()The port number, which can be a value between 1 and 65535.
optional int32 port = 3446913;
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
This builder for chaining. |
getDefaultInstanceForType()
public NamedPort getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
NamedPort |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getName()
public String getName()The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Returns | |
|---|---|
| Type | Description |
String |
The name. |
getNameBytes()
public ByteString getNameBytes()The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for name. |
getPort()
public int getPort()The port number, which can be a value between 1 and 65535.
optional int32 port = 3446913;
| Returns | |
|---|---|
| Type | Description |
int |
The port. |
hasName()
public boolean hasName()The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the name field is set. |
hasPort()
public boolean hasPort()The port number, which can be a value between 1 and 65535.
optional int32 port = 3446913;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the port field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(NamedPort other)
public NamedPort.Builder mergeFrom(NamedPort other)| Parameter | |
|---|---|
| Name | Description |
other |
NamedPort |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public NamedPort.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public NamedPort.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
|
setName(String value)
public NamedPort.Builder setName(String value)The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe name to set. |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
This builder for chaining. |
setNameBytes(ByteString value)
public NamedPort.Builder setNameBytes(ByteString value)The name for this named port. The name must be 1-63 characters long, and comply withRFC1035.
optional string name = 3373707;
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for name to set. |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
This builder for chaining. |
setPort(int value)
public NamedPort.Builder setPort(int value)The port number, which can be a value between 1 and 65535.
optional int32 port = 3446913;
| Parameter | |
|---|---|
| Name | Description |
value |
intThe port to set. |
| Returns | |
|---|---|
| Type | Description |
NamedPort.Builder |
This builder for chaining. |