Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: basic_types.proto
package com.hederahashgraph.api.proto.java;
/**
*
**
* Contains the IP address and the port representing a service endpoint of
* a Node in a network. Used to reach the Hedera API and submit transactions
* to the network.
* When the `domain_name` field is set, the `ipAddressV4` field
* MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field
* MUST NOT be set.
*
*
* Protobuf type {@code proto.ServiceEndpoint}
*/
public final class ServiceEndpoint extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:proto.ServiceEndpoint)
ServiceEndpointOrBuilder {
private static final long serialVersionUID = 0L;
// Use ServiceEndpoint.newBuilder() to construct.
private ServiceEndpoint(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ServiceEndpoint() {
ipAddressV4_ = com.google.protobuf.ByteString.EMPTY;
domainName_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ServiceEndpoint();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private ServiceEndpoint(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
ipAddressV4_ = input.readBytes();
break;
}
case 16: {
port_ = input.readInt32();
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
domainName_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hederahashgraph.api.proto.java.BasicTypes.internal_static_proto_ServiceEndpoint_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.BasicTypes.internal_static_proto_ServiceEndpoint_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.ServiceEndpoint.class, com.hederahashgraph.api.proto.java.ServiceEndpoint.Builder.class);
}
public static final int IPADDRESSV4_FIELD_NUMBER = 1;
private com.google.protobuf.ByteString ipAddressV4_;
/**
*
**
* The 4-byte IPv4 address of the endpoint encoded in left to right order
* (e.g. 127.0.0.1 has bytes [127, 0, 0, 1])
*
*
* bytes ipAddressV4 = 1;
* @return The ipAddressV4.
*/
@java.lang.Override
public com.google.protobuf.ByteString getIpAddressV4() {
return ipAddressV4_;
}
public static final int PORT_FIELD_NUMBER = 2;
private int port_;
/**
*
**
* The port of the service endpoint
*
*
* int32 port = 2;
* @return The port.
*/
@java.lang.Override
public int getPort() {
return port_;
}
public static final int DOMAIN_NAME_FIELD_NUMBER = 3;
private volatile java.lang.Object domainName_;
/**
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
**
* Contains the IP address and the port representing a service endpoint of
* a Node in a network. Used to reach the Hedera API and submit transactions
* to the network.
* When the `domain_name` field is set, the `ipAddressV4` field
* MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field
* MUST NOT be set.
*
*
* Protobuf type {@code proto.ServiceEndpoint}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:proto.ServiceEndpoint)
com.hederahashgraph.api.proto.java.ServiceEndpointOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hederahashgraph.api.proto.java.BasicTypes.internal_static_proto_ServiceEndpoint_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.BasicTypes.internal_static_proto_ServiceEndpoint_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.ServiceEndpoint.class, com.hederahashgraph.api.proto.java.ServiceEndpoint.Builder.class);
}
// Construct using com.hederahashgraph.api.proto.java.ServiceEndpoint.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
ipAddressV4_ = com.google.protobuf.ByteString.EMPTY;
port_ = 0;
domainName_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.hederahashgraph.api.proto.java.BasicTypes.internal_static_proto_ServiceEndpoint_descriptor;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.ServiceEndpoint getDefaultInstanceForType() {
return com.hederahashgraph.api.proto.java.ServiceEndpoint.getDefaultInstance();
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.ServiceEndpoint build() {
com.hederahashgraph.api.proto.java.ServiceEndpoint result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.ServiceEndpoint buildPartial() {
com.hederahashgraph.api.proto.java.ServiceEndpoint result = new com.hederahashgraph.api.proto.java.ServiceEndpoint(this);
result.ipAddressV4_ = ipAddressV4_;
result.port_ = port_;
result.domainName_ = domainName_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.hederahashgraph.api.proto.java.ServiceEndpoint) {
return mergeFrom((com.hederahashgraph.api.proto.java.ServiceEndpoint)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.hederahashgraph.api.proto.java.ServiceEndpoint other) {
if (other == com.hederahashgraph.api.proto.java.ServiceEndpoint.getDefaultInstance()) return this;
if (other.getIpAddressV4() != com.google.protobuf.ByteString.EMPTY) {
setIpAddressV4(other.getIpAddressV4());
}
if (other.getPort() != 0) {
setPort(other.getPort());
}
if (!other.getDomainName().isEmpty()) {
domainName_ = other.domainName_;
onChanged();
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
com.hederahashgraph.api.proto.java.ServiceEndpoint parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.hederahashgraph.api.proto.java.ServiceEndpoint) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private com.google.protobuf.ByteString ipAddressV4_ = com.google.protobuf.ByteString.EMPTY;
/**
*
**
* The 4-byte IPv4 address of the endpoint encoded in left to right order
* (e.g. 127.0.0.1 has bytes [127, 0, 0, 1])
*
**
* The 4-byte IPv4 address of the endpoint encoded in left to right order
* (e.g. 127.0.0.1 has bytes [127, 0, 0, 1])
*
*
* bytes ipAddressV4 = 1;
* @param value The ipAddressV4 to set.
* @return This builder for chaining.
*/
public Builder setIpAddressV4(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
ipAddressV4_ = value;
onChanged();
return this;
}
/**
*
**
* The 4-byte IPv4 address of the endpoint encoded in left to right order
* (e.g. 127.0.0.1 has bytes [127, 0, 0, 1])
*
*
* bytes ipAddressV4 = 1;
* @return This builder for chaining.
*/
public Builder clearIpAddressV4() {
ipAddressV4_ = getDefaultInstance().getIpAddressV4();
onChanged();
return this;
}
private int port_ ;
/**
*
**
* The port of the service endpoint
*
*
* int32 port = 2;
* @return The port.
*/
@java.lang.Override
public int getPort() {
return port_;
}
/**
*
**
* The port of the service endpoint
*
*
* int32 port = 2;
* @param value The port to set.
* @return This builder for chaining.
*/
public Builder setPort(int value) {
port_ = value;
onChanged();
return this;
}
/**
*
**
* The port of the service endpoint
*
*
* int32 port = 2;
* @return This builder for chaining.
*/
public Builder clearPort() {
port_ = 0;
onChanged();
return this;
}
private java.lang.Object domainName_ = "";
/**
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
*
* string domain_name = 3;
* @return The bytes for domainName.
*/
public com.google.protobuf.ByteString
getDomainNameBytes() {
java.lang.Object ref = domainName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
domainName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
*
* string domain_name = 3;
* @param value The domainName to set.
* @return This builder for chaining.
*/
public Builder setDomainName(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
domainName_ = value;
onChanged();
return this;
}
/**
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
*
* string domain_name = 3;
* @return This builder for chaining.
*/
public Builder clearDomainName() {
domainName_ = getDefaultInstance().getDomainName();
onChanged();
return this;
}
/**
*
**
* A node domain name.<br/>
* This MUST be the fully qualified domain(DNS) name of the node.<br/>
* This value MUST NOT be more than 253 characters.
* domain_name and ipAddressV4 are mutually exclusive.
* When the `domain_name` field is set, the `ipAddressV4` field MUST NOT be set.<br/>
* When the `ipAddressV4` field is set, the `domain_name` field MUST NOT be set.
*
*
* string domain_name = 3;
* @param value The bytes for domainName to set.
* @return This builder for chaining.
*/
public Builder setDomainNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
domainName_ = value;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:proto.ServiceEndpoint)
}
// @@protoc_insertion_point(class_scope:proto.ServiceEndpoint)
private static final com.hederahashgraph.api.proto.java.ServiceEndpoint DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.hederahashgraph.api.proto.java.ServiceEndpoint();
}
public static com.hederahashgraph.api.proto.java.ServiceEndpoint getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ServiceEndpoint parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new ServiceEndpoint(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.ServiceEndpoint getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}