All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
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.
io.provenance.metadata.v0.Recital Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: provenance/metadata/v0/contract.proto
package io.provenance.metadata.v0;
/**
* Protobuf type {@code contract.Recital}
*/
public final class Recital extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:contract.Recital)
RecitalOrBuilder {
private static final long serialVersionUID = 0L;
// Use Recital.newBuilder() to construct.
private Recital(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Recital() {
signerRole_ = 0;
address_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Recital(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
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 8: {
int rawValue = input.readEnum();
signerRole_ = rawValue;
break;
}
case 18: {
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder subBuilder = null;
if (signer_ != null) {
subBuilder = signer_.toBuilder();
}
signer_ = input.readMessage(io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(signer_);
signer_ = subBuilder.buildPartial();
}
break;
}
case 26: {
address_ = input.readBytes();
break;
}
default: {
if (!parseUnknownFieldProto3(
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 io.provenance.metadata.v0.ContractOuterClass.internal_static_contract_Recital_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.provenance.metadata.v0.ContractOuterClass.internal_static_contract_Recital_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.provenance.metadata.v0.Recital.class, io.provenance.metadata.v0.Recital.Builder.class);
}
public static final int SIGNER_ROLE_FIELD_NUMBER = 1;
private int signerRole_;
/**
* .types.PartyType signer_role = 1;
*/
public int getSignerRoleValue() {
return signerRole_;
}
/**
* .types.PartyType signer_role = 1;
*/
public io.provenance.metadata.v0.PartyType getSignerRole() {
@SuppressWarnings("deprecation")
io.provenance.metadata.v0.PartyType result = io.provenance.metadata.v0.PartyType.valueOf(signerRole_);
return result == null ? io.provenance.metadata.v0.PartyType.UNRECOGNIZED : result;
}
public static final int SIGNER_FIELD_NUMBER = 2;
private io.provenance.metadata.v0.SigningAndEncryptionPublicKeys signer_;
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public boolean hasSigner() {
return signer_ != null;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public io.provenance.metadata.v0.SigningAndEncryptionPublicKeys getSigner() {
return signer_ == null ? io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.getDefaultInstance() : signer_;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public io.provenance.metadata.v0.SigningAndEncryptionPublicKeysOrBuilder getSignerOrBuilder() {
return getSigner();
}
public static final int ADDRESS_FIELD_NUMBER = 3;
private com.google.protobuf.ByteString address_;
/**
* bytes address = 3;
*/
public com.google.protobuf.ByteString getAddress() {
return address_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (signerRole_ != io.provenance.metadata.v0.PartyType.PARTY_TYPE_UNKNOWN.getNumber()) {
output.writeEnum(1, signerRole_);
}
if (signer_ != null) {
output.writeMessage(2, getSigner());
}
if (!address_.isEmpty()) {
output.writeBytes(3, address_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (signerRole_ != io.provenance.metadata.v0.PartyType.PARTY_TYPE_UNKNOWN.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, signerRole_);
}
if (signer_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getSigner());
}
if (!address_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(3, address_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.provenance.metadata.v0.Recital)) {
return super.equals(obj);
}
io.provenance.metadata.v0.Recital other = (io.provenance.metadata.v0.Recital) obj;
boolean result = true;
result = result && signerRole_ == other.signerRole_;
result = result && (hasSigner() == other.hasSigner());
if (hasSigner()) {
result = result && getSigner()
.equals(other.getSigner());
}
result = result && getAddress()
.equals(other.getAddress());
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SIGNER_ROLE_FIELD_NUMBER;
hash = (53 * hash) + signerRole_;
if (hasSigner()) {
hash = (37 * hash) + SIGNER_FIELD_NUMBER;
hash = (53 * hash) + getSigner().hashCode();
}
hash = (37 * hash) + ADDRESS_FIELD_NUMBER;
hash = (53 * hash) + getAddress().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.provenance.metadata.v0.Recital parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.provenance.metadata.v0.Recital parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.provenance.metadata.v0.Recital parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.provenance.metadata.v0.Recital parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.provenance.metadata.v0.Recital parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.provenance.metadata.v0.Recital parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.provenance.metadata.v0.Recital parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.provenance.metadata.v0.Recital parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.provenance.metadata.v0.Recital parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.provenance.metadata.v0.Recital parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.provenance.metadata.v0.Recital parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.provenance.metadata.v0.Recital parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.provenance.metadata.v0.Recital prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code contract.Recital}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:contract.Recital)
io.provenance.metadata.v0.RecitalOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.provenance.metadata.v0.ContractOuterClass.internal_static_contract_Recital_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.provenance.metadata.v0.ContractOuterClass.internal_static_contract_Recital_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.provenance.metadata.v0.Recital.class, io.provenance.metadata.v0.Recital.Builder.class);
}
// Construct using io.provenance.metadata.v0.Recital.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();
signerRole_ = 0;
if (signerBuilder_ == null) {
signer_ = null;
} else {
signer_ = null;
signerBuilder_ = null;
}
address_ = com.google.protobuf.ByteString.EMPTY;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.provenance.metadata.v0.ContractOuterClass.internal_static_contract_Recital_descriptor;
}
@java.lang.Override
public io.provenance.metadata.v0.Recital getDefaultInstanceForType() {
return io.provenance.metadata.v0.Recital.getDefaultInstance();
}
@java.lang.Override
public io.provenance.metadata.v0.Recital build() {
io.provenance.metadata.v0.Recital result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.provenance.metadata.v0.Recital buildPartial() {
io.provenance.metadata.v0.Recital result = new io.provenance.metadata.v0.Recital(this);
result.signerRole_ = signerRole_;
if (signerBuilder_ == null) {
result.signer_ = signer_;
} else {
result.signer_ = signerBuilder_.build();
}
result.address_ = address_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return (Builder) super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.provenance.metadata.v0.Recital) {
return mergeFrom((io.provenance.metadata.v0.Recital)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.provenance.metadata.v0.Recital other) {
if (other == io.provenance.metadata.v0.Recital.getDefaultInstance()) return this;
if (other.signerRole_ != 0) {
setSignerRoleValue(other.getSignerRoleValue());
}
if (other.hasSigner()) {
mergeSigner(other.getSigner());
}
if (other.getAddress() != com.google.protobuf.ByteString.EMPTY) {
setAddress(other.getAddress());
}
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 {
io.provenance.metadata.v0.Recital parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.provenance.metadata.v0.Recital) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int signerRole_ = 0;
/**
* .types.PartyType signer_role = 1;
*/
public int getSignerRoleValue() {
return signerRole_;
}
/**
* .types.PartyType signer_role = 1;
*/
public Builder setSignerRoleValue(int value) {
signerRole_ = value;
onChanged();
return this;
}
/**
* .types.PartyType signer_role = 1;
*/
public io.provenance.metadata.v0.PartyType getSignerRole() {
@SuppressWarnings("deprecation")
io.provenance.metadata.v0.PartyType result = io.provenance.metadata.v0.PartyType.valueOf(signerRole_);
return result == null ? io.provenance.metadata.v0.PartyType.UNRECOGNIZED : result;
}
/**
* .types.PartyType signer_role = 1;
*/
public Builder setSignerRole(io.provenance.metadata.v0.PartyType value) {
if (value == null) {
throw new NullPointerException();
}
signerRole_ = value.getNumber();
onChanged();
return this;
}
/**
* .types.PartyType signer_role = 1;
*/
public Builder clearSignerRole() {
signerRole_ = 0;
onChanged();
return this;
}
private io.provenance.metadata.v0.SigningAndEncryptionPublicKeys signer_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys, io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder, io.provenance.metadata.v0.SigningAndEncryptionPublicKeysOrBuilder> signerBuilder_;
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public boolean hasSigner() {
return signerBuilder_ != null || signer_ != null;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public io.provenance.metadata.v0.SigningAndEncryptionPublicKeys getSigner() {
if (signerBuilder_ == null) {
return signer_ == null ? io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.getDefaultInstance() : signer_;
} else {
return signerBuilder_.getMessage();
}
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public Builder setSigner(io.provenance.metadata.v0.SigningAndEncryptionPublicKeys value) {
if (signerBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
signer_ = value;
onChanged();
} else {
signerBuilder_.setMessage(value);
}
return this;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public Builder setSigner(
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder builderForValue) {
if (signerBuilder_ == null) {
signer_ = builderForValue.build();
onChanged();
} else {
signerBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public Builder mergeSigner(io.provenance.metadata.v0.SigningAndEncryptionPublicKeys value) {
if (signerBuilder_ == null) {
if (signer_ != null) {
signer_ =
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.newBuilder(signer_).mergeFrom(value).buildPartial();
} else {
signer_ = value;
}
onChanged();
} else {
signerBuilder_.mergeFrom(value);
}
return this;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public Builder clearSigner() {
if (signerBuilder_ == null) {
signer_ = null;
onChanged();
} else {
signer_ = null;
signerBuilder_ = null;
}
return this;
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder getSignerBuilder() {
onChanged();
return getSignerFieldBuilder().getBuilder();
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
public io.provenance.metadata.v0.SigningAndEncryptionPublicKeysOrBuilder getSignerOrBuilder() {
if (signerBuilder_ != null) {
return signerBuilder_.getMessageOrBuilder();
} else {
return signer_ == null ?
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.getDefaultInstance() : signer_;
}
}
/**
* .types.SigningAndEncryptionPublicKeys signer = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys, io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder, io.provenance.metadata.v0.SigningAndEncryptionPublicKeysOrBuilder>
getSignerFieldBuilder() {
if (signerBuilder_ == null) {
signerBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.provenance.metadata.v0.SigningAndEncryptionPublicKeys, io.provenance.metadata.v0.SigningAndEncryptionPublicKeys.Builder, io.provenance.metadata.v0.SigningAndEncryptionPublicKeysOrBuilder>(
getSigner(),
getParentForChildren(),
isClean());
signer_ = null;
}
return signerBuilder_;
}
private com.google.protobuf.ByteString address_ = com.google.protobuf.ByteString.EMPTY;
/**
* bytes address = 3;
*/
public com.google.protobuf.ByteString getAddress() {
return address_;
}
/**
* bytes address = 3;
*/
public Builder setAddress(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
address_ = value;
onChanged();
return this;
}
/**
* bytes address = 3;
*/
public Builder clearAddress() {
address_ = getDefaultInstance().getAddress();
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:contract.Recital)
}
// @@protoc_insertion_point(class_scope:contract.Recital)
private static final io.provenance.metadata.v0.Recital DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.provenance.metadata.v0.Recital();
}
public static io.provenance.metadata.v0.Recital getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Recital parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new Recital(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 io.provenance.metadata.v0.Recital getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}