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.
org.hyperledger.fabric.protos.ledger.rwset.Rwset Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: ledger/rwset/rwset.proto
package org.hyperledger.fabric.protos.ledger.rwset;
public final class Rwset {
private Rwset() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface TxReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.TxReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
int getDataModelValue();
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel();
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
java.util.List
getNsRwsetList();
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getNsRwset(int index);
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
int getNsRwsetCount();
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
java.util.List
getNsRwsetOrBuilderList();
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder getNsRwsetOrBuilder(
int index);
}
/**
*
* TxReadWriteSet encapsulates a read-write set for a transaction
* DataModel specifies the enum value of the data model
* ns_rwset field specifies a list of chaincode specific read-write set (one for each chaincode)
*
*
* Protobuf type {@code rwset.TxReadWriteSet}
*/
public static final class TxReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.TxReadWriteSet)
TxReadWriteSetOrBuilder {
// Use TxReadWriteSet.newBuilder() to construct.
private TxReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private TxReadWriteSet() {
dataModel_ = 0;
nsRwset_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private TxReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 8: {
int rawValue = input.readEnum();
dataModel_ = rawValue;
break;
}
case 18: {
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
nsRwset_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
nsRwset_.add(
input.readMessage(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.parser(), extensionRegistry));
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 {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
nsRwset_ = java.util.Collections.unmodifiableList(nsRwset_);
}
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.Builder.class);
}
/**
* Protobuf enum {@code rwset.TxReadWriteSet.DataModel}
*/
public enum DataModel
implements com.google.protobuf.ProtocolMessageEnum {
/**
* KV = 0;
*/
KV(0),
UNRECOGNIZED(-1),
;
/**
* KV = 0;
*/
public static final int KV_VALUE = 0;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static DataModel valueOf(int value) {
return forNumber(value);
}
public static DataModel forNumber(int value) {
switch (value) {
case 0: return KV;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
DataModel> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public DataModel findValueByNumber(int number) {
return DataModel.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.getDescriptor().getEnumTypes().get(0);
}
private static final DataModel[] VALUES = values();
public static DataModel valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private DataModel(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:rwset.TxReadWriteSet.DataModel)
}
private int bitField0_;
public static final int DATA_MODEL_FIELD_NUMBER = 1;
private int dataModel_;
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public int getDataModelValue() {
return dataModel_;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel result = org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.valueOf(dataModel_);
return result == null ? org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.UNRECOGNIZED : result;
}
public static final int NS_RWSET_FIELD_NUMBER = 2;
private java.util.List nsRwset_;
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public java.util.List getNsRwsetList() {
return nsRwset_;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public java.util.List
getNsRwsetOrBuilderList() {
return nsRwset_;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public int getNsRwsetCount() {
return nsRwset_.size();
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getNsRwset(int index) {
return nsRwset_.get(index);
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder getNsRwsetOrBuilder(
int index) {
return nsRwset_.get(index);
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (dataModel_ != org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.KV.getNumber()) {
output.writeEnum(1, dataModel_);
}
for (int i = 0; i < nsRwset_.size(); i++) {
output.writeMessage(2, nsRwset_.get(i));
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (dataModel_ != org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.KV.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, dataModel_);
}
for (int i = 0; i < nsRwset_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, nsRwset_.get(i));
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet) obj;
boolean result = true;
result = result && dataModel_ == other.dataModel_;
result = result && getNsRwsetList()
.equals(other.getNsRwsetList());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + DATA_MODEL_FIELD_NUMBER;
hash = (53 * hash) + dataModel_;
if (getNsRwsetCount() > 0) {
hash = (37 * hash) + NS_RWSET_FIELD_NUMBER;
hash = (53 * hash) + getNsRwsetList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* TxReadWriteSet encapsulates a read-write set for a transaction
* DataModel specifies the enum value of the data model
* ns_rwset field specifies a list of chaincode specific read-write set (one for each chaincode)
*
*
* Protobuf type {@code rwset.TxReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.TxReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getNsRwsetFieldBuilder();
}
}
public Builder clear() {
super.clear();
dataModel_ = 0;
if (nsRwsetBuilder_ == null) {
nsRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
} else {
nsRwsetBuilder_.clear();
}
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.dataModel_ = dataModel_;
if (nsRwsetBuilder_ == null) {
if (((bitField0_ & 0x00000002) == 0x00000002)) {
nsRwset_ = java.util.Collections.unmodifiableList(nsRwset_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.nsRwset_ = nsRwset_;
} else {
result.nsRwset_ = nsRwsetBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.getDefaultInstance()) return this;
if (other.dataModel_ != 0) {
setDataModelValue(other.getDataModelValue());
}
if (nsRwsetBuilder_ == null) {
if (!other.nsRwset_.isEmpty()) {
if (nsRwset_.isEmpty()) {
nsRwset_ = other.nsRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureNsRwsetIsMutable();
nsRwset_.addAll(other.nsRwset_);
}
onChanged();
}
} else {
if (!other.nsRwset_.isEmpty()) {
if (nsRwsetBuilder_.isEmpty()) {
nsRwsetBuilder_.dispose();
nsRwsetBuilder_ = null;
nsRwset_ = other.nsRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
nsRwsetBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getNsRwsetFieldBuilder() : null;
} else {
nsRwsetBuilder_.addAllMessages(other.nsRwset_);
}
}
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private int dataModel_ = 0;
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public int getDataModelValue() {
return dataModel_;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder setDataModelValue(int value) {
dataModel_ = value;
onChanged();
return this;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel result = org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.valueOf(dataModel_);
return result == null ? org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.UNRECOGNIZED : result;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder setDataModel(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel value) {
if (value == null) {
throw new NullPointerException();
}
dataModel_ = value.getNumber();
onChanged();
return this;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder clearDataModel() {
dataModel_ = 0;
onChanged();
return this;
}
private java.util.List nsRwset_ =
java.util.Collections.emptyList();
private void ensureNsRwsetIsMutable() {
if (!((bitField0_ & 0x00000002) == 0x00000002)) {
nsRwset_ = new java.util.ArrayList(nsRwset_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder> nsRwsetBuilder_;
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public java.util.List getNsRwsetList() {
if (nsRwsetBuilder_ == null) {
return java.util.Collections.unmodifiableList(nsRwset_);
} else {
return nsRwsetBuilder_.getMessageList();
}
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public int getNsRwsetCount() {
if (nsRwsetBuilder_ == null) {
return nsRwset_.size();
} else {
return nsRwsetBuilder_.getCount();
}
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getNsRwset(int index) {
if (nsRwsetBuilder_ == null) {
return nsRwset_.get(index);
} else {
return nsRwsetBuilder_.getMessage(index);
}
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder setNsRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet value) {
if (nsRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsRwsetIsMutable();
nsRwset_.set(index, value);
onChanged();
} else {
nsRwsetBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder setNsRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder builderForValue) {
if (nsRwsetBuilder_ == null) {
ensureNsRwsetIsMutable();
nsRwset_.set(index, builderForValue.build());
onChanged();
} else {
nsRwsetBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder addNsRwset(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet value) {
if (nsRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsRwsetIsMutable();
nsRwset_.add(value);
onChanged();
} else {
nsRwsetBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder addNsRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet value) {
if (nsRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsRwsetIsMutable();
nsRwset_.add(index, value);
onChanged();
} else {
nsRwsetBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder addNsRwset(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder builderForValue) {
if (nsRwsetBuilder_ == null) {
ensureNsRwsetIsMutable();
nsRwset_.add(builderForValue.build());
onChanged();
} else {
nsRwsetBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder addNsRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder builderForValue) {
if (nsRwsetBuilder_ == null) {
ensureNsRwsetIsMutable();
nsRwset_.add(index, builderForValue.build());
onChanged();
} else {
nsRwsetBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder addAllNsRwset(
java.lang.Iterable values) {
if (nsRwsetBuilder_ == null) {
ensureNsRwsetIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, nsRwset_);
onChanged();
} else {
nsRwsetBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder clearNsRwset() {
if (nsRwsetBuilder_ == null) {
nsRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
nsRwsetBuilder_.clear();
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public Builder removeNsRwset(int index) {
if (nsRwsetBuilder_ == null) {
ensureNsRwsetIsMutable();
nsRwset_.remove(index);
onChanged();
} else {
nsRwsetBuilder_.remove(index);
}
return this;
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder getNsRwsetBuilder(
int index) {
return getNsRwsetFieldBuilder().getBuilder(index);
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder getNsRwsetOrBuilder(
int index) {
if (nsRwsetBuilder_ == null) {
return nsRwset_.get(index); } else {
return nsRwsetBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public java.util.List
getNsRwsetOrBuilderList() {
if (nsRwsetBuilder_ != null) {
return nsRwsetBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(nsRwset_);
}
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder addNsRwsetBuilder() {
return getNsRwsetFieldBuilder().addBuilder(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder addNsRwsetBuilder(
int index) {
return getNsRwsetFieldBuilder().addBuilder(
index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.NsReadWriteSet ns_rwset = 2;
*/
public java.util.List
getNsRwsetBuilderList() {
return getNsRwsetFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder>
getNsRwsetFieldBuilder() {
if (nsRwsetBuilder_ == null) {
nsRwsetBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder>(
nsRwset_,
((bitField0_ & 0x00000002) == 0x00000002),
getParentForChildren(),
isClean());
nsRwset_ = null;
}
return nsRwsetBuilder_;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.TxReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.TxReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public TxReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new TxReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface NsReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.NsReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional string namespace = 1;
*/
java.lang.String getNamespace();
/**
* optional string namespace = 1;
*/
com.google.protobuf.ByteString
getNamespaceBytes();
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
com.google.protobuf.ByteString getRwset();
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
java.util.List
getCollectionHashedRwsetList();
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getCollectionHashedRwset(int index);
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
int getCollectionHashedRwsetCount();
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
java.util.List
getCollectionHashedRwsetOrBuilderList();
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder getCollectionHashedRwsetOrBuilder(
int index);
}
/**
*
* NsReadWriteSet encapsulates the read-write set for a chaincode
*
*
* Protobuf type {@code rwset.NsReadWriteSet}
*/
public static final class NsReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.NsReadWriteSet)
NsReadWriteSetOrBuilder {
// Use NsReadWriteSet.newBuilder() to construct.
private NsReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private NsReadWriteSet() {
namespace_ = "";
rwset_ = com.google.protobuf.ByteString.EMPTY;
collectionHashedRwset_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private NsReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 10: {
java.lang.String s = input.readStringRequireUtf8();
namespace_ = s;
break;
}
case 18: {
rwset_ = input.readBytes();
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
collectionHashedRwset_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000004;
}
collectionHashedRwset_.add(
input.readMessage(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.parser(), extensionRegistry));
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 {
if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
collectionHashedRwset_ = java.util.Collections.unmodifiableList(collectionHashedRwset_);
}
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder.class);
}
private int bitField0_;
public static final int NAMESPACE_FIELD_NUMBER = 1;
private volatile java.lang.Object namespace_;
/**
* optional string namespace = 1;
*/
public java.lang.String getNamespace() {
java.lang.Object ref = namespace_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
namespace_ = s;
return s;
}
}
/**
* optional string namespace = 1;
*/
public com.google.protobuf.ByteString
getNamespaceBytes() {
java.lang.Object ref = namespace_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
namespace_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int RWSET_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString rwset_;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public com.google.protobuf.ByteString getRwset() {
return rwset_;
}
public static final int COLLECTION_HASHED_RWSET_FIELD_NUMBER = 3;
private java.util.List collectionHashedRwset_;
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public java.util.List getCollectionHashedRwsetList() {
return collectionHashedRwset_;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public java.util.List
getCollectionHashedRwsetOrBuilderList() {
return collectionHashedRwset_;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public int getCollectionHashedRwsetCount() {
return collectionHashedRwset_.size();
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getCollectionHashedRwset(int index) {
return collectionHashedRwset_.get(index);
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder getCollectionHashedRwsetOrBuilder(
int index) {
return collectionHashedRwset_.get(index);
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!getNamespaceBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, namespace_);
}
if (!rwset_.isEmpty()) {
output.writeBytes(2, rwset_);
}
for (int i = 0; i < collectionHashedRwset_.size(); i++) {
output.writeMessage(3, collectionHashedRwset_.get(i));
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getNamespaceBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, namespace_);
}
if (!rwset_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(2, rwset_);
}
for (int i = 0; i < collectionHashedRwset_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, collectionHashedRwset_.get(i));
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet) obj;
boolean result = true;
result = result && getNamespace()
.equals(other.getNamespace());
result = result && getRwset()
.equals(other.getRwset());
result = result && getCollectionHashedRwsetList()
.equals(other.getCollectionHashedRwsetList());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + NAMESPACE_FIELD_NUMBER;
hash = (53 * hash) + getNamespace().hashCode();
hash = (37 * hash) + RWSET_FIELD_NUMBER;
hash = (53 * hash) + getRwset().hashCode();
if (getCollectionHashedRwsetCount() > 0) {
hash = (37 * hash) + COLLECTION_HASHED_RWSET_FIELD_NUMBER;
hash = (53 * hash) + getCollectionHashedRwsetList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* NsReadWriteSet encapsulates the read-write set for a chaincode
*
*
* Protobuf type {@code rwset.NsReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.NsReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCollectionHashedRwsetFieldBuilder();
}
}
public Builder clear() {
super.clear();
namespace_ = "";
rwset_ = com.google.protobuf.ByteString.EMPTY;
if (collectionHashedRwsetBuilder_ == null) {
collectionHashedRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
} else {
collectionHashedRwsetBuilder_.clear();
}
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.namespace_ = namespace_;
result.rwset_ = rwset_;
if (collectionHashedRwsetBuilder_ == null) {
if (((bitField0_ & 0x00000004) == 0x00000004)) {
collectionHashedRwset_ = java.util.Collections.unmodifiableList(collectionHashedRwset_);
bitField0_ = (bitField0_ & ~0x00000004);
}
result.collectionHashedRwset_ = collectionHashedRwset_;
} else {
result.collectionHashedRwset_ = collectionHashedRwsetBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet.getDefaultInstance()) return this;
if (!other.getNamespace().isEmpty()) {
namespace_ = other.namespace_;
onChanged();
}
if (other.getRwset() != com.google.protobuf.ByteString.EMPTY) {
setRwset(other.getRwset());
}
if (collectionHashedRwsetBuilder_ == null) {
if (!other.collectionHashedRwset_.isEmpty()) {
if (collectionHashedRwset_.isEmpty()) {
collectionHashedRwset_ = other.collectionHashedRwset_;
bitField0_ = (bitField0_ & ~0x00000004);
} else {
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.addAll(other.collectionHashedRwset_);
}
onChanged();
}
} else {
if (!other.collectionHashedRwset_.isEmpty()) {
if (collectionHashedRwsetBuilder_.isEmpty()) {
collectionHashedRwsetBuilder_.dispose();
collectionHashedRwsetBuilder_ = null;
collectionHashedRwset_ = other.collectionHashedRwset_;
bitField0_ = (bitField0_ & ~0x00000004);
collectionHashedRwsetBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getCollectionHashedRwsetFieldBuilder() : null;
} else {
collectionHashedRwsetBuilder_.addAllMessages(other.collectionHashedRwset_);
}
}
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private java.lang.Object namespace_ = "";
/**
* optional string namespace = 1;
*/
public java.lang.String getNamespace() {
java.lang.Object ref = namespace_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
namespace_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string namespace = 1;
*/
public com.google.protobuf.ByteString
getNamespaceBytes() {
java.lang.Object ref = namespace_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
namespace_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string namespace = 1;
*/
public Builder setNamespace(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
namespace_ = value;
onChanged();
return this;
}
/**
* optional string namespace = 1;
*/
public Builder clearNamespace() {
namespace_ = getDefaultInstance().getNamespace();
onChanged();
return this;
}
/**
* optional string namespace = 1;
*/
public Builder setNamespaceBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
namespace_ = value;
onChanged();
return this;
}
private com.google.protobuf.ByteString rwset_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public com.google.protobuf.ByteString getRwset() {
return rwset_;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public Builder setRwset(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
rwset_ = value;
onChanged();
return this;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public Builder clearRwset() {
rwset_ = getDefaultInstance().getRwset();
onChanged();
return this;
}
private java.util.List collectionHashedRwset_ =
java.util.Collections.emptyList();
private void ensureCollectionHashedRwsetIsMutable() {
if (!((bitField0_ & 0x00000004) == 0x00000004)) {
collectionHashedRwset_ = new java.util.ArrayList(collectionHashedRwset_);
bitField0_ |= 0x00000004;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder> collectionHashedRwsetBuilder_;
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public java.util.List getCollectionHashedRwsetList() {
if (collectionHashedRwsetBuilder_ == null) {
return java.util.Collections.unmodifiableList(collectionHashedRwset_);
} else {
return collectionHashedRwsetBuilder_.getMessageList();
}
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public int getCollectionHashedRwsetCount() {
if (collectionHashedRwsetBuilder_ == null) {
return collectionHashedRwset_.size();
} else {
return collectionHashedRwsetBuilder_.getCount();
}
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getCollectionHashedRwset(int index) {
if (collectionHashedRwsetBuilder_ == null) {
return collectionHashedRwset_.get(index);
} else {
return collectionHashedRwsetBuilder_.getMessage(index);
}
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder setCollectionHashedRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet value) {
if (collectionHashedRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.set(index, value);
onChanged();
} else {
collectionHashedRwsetBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder setCollectionHashedRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder builderForValue) {
if (collectionHashedRwsetBuilder_ == null) {
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.set(index, builderForValue.build());
onChanged();
} else {
collectionHashedRwsetBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder addCollectionHashedRwset(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet value) {
if (collectionHashedRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.add(value);
onChanged();
} else {
collectionHashedRwsetBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder addCollectionHashedRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet value) {
if (collectionHashedRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.add(index, value);
onChanged();
} else {
collectionHashedRwsetBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder addCollectionHashedRwset(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder builderForValue) {
if (collectionHashedRwsetBuilder_ == null) {
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.add(builderForValue.build());
onChanged();
} else {
collectionHashedRwsetBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder addCollectionHashedRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder builderForValue) {
if (collectionHashedRwsetBuilder_ == null) {
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.add(index, builderForValue.build());
onChanged();
} else {
collectionHashedRwsetBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder addAllCollectionHashedRwset(
java.lang.Iterable values) {
if (collectionHashedRwsetBuilder_ == null) {
ensureCollectionHashedRwsetIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, collectionHashedRwset_);
onChanged();
} else {
collectionHashedRwsetBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder clearCollectionHashedRwset() {
if (collectionHashedRwsetBuilder_ == null) {
collectionHashedRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
} else {
collectionHashedRwsetBuilder_.clear();
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public Builder removeCollectionHashedRwset(int index) {
if (collectionHashedRwsetBuilder_ == null) {
ensureCollectionHashedRwsetIsMutable();
collectionHashedRwset_.remove(index);
onChanged();
} else {
collectionHashedRwsetBuilder_.remove(index);
}
return this;
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder getCollectionHashedRwsetBuilder(
int index) {
return getCollectionHashedRwsetFieldBuilder().getBuilder(index);
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder getCollectionHashedRwsetOrBuilder(
int index) {
if (collectionHashedRwsetBuilder_ == null) {
return collectionHashedRwset_.get(index); } else {
return collectionHashedRwsetBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public java.util.List
getCollectionHashedRwsetOrBuilderList() {
if (collectionHashedRwsetBuilder_ != null) {
return collectionHashedRwsetBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(collectionHashedRwset_);
}
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder addCollectionHashedRwsetBuilder() {
return getCollectionHashedRwsetFieldBuilder().addBuilder(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder addCollectionHashedRwsetBuilder(
int index) {
return getCollectionHashedRwsetFieldBuilder().addBuilder(
index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.CollectionHashedReadWriteSet collection_hashed_rwset = 3;
*/
public java.util.List
getCollectionHashedRwsetBuilderList() {
return getCollectionHashedRwsetFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder>
getCollectionHashedRwsetFieldBuilder() {
if (collectionHashedRwsetBuilder_ == null) {
collectionHashedRwsetBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder>(
collectionHashedRwset_,
((bitField0_ & 0x00000004) == 0x00000004),
getParentForChildren(),
isClean());
collectionHashedRwset_ = null;
}
return collectionHashedRwsetBuilder_;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.NsReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.NsReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public NsReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new NsReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface CollectionHashedReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.CollectionHashedReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional string collection_name = 1;
*/
java.lang.String getCollectionName();
/**
* optional string collection_name = 1;
*/
com.google.protobuf.ByteString
getCollectionNameBytes();
/**
*
* Data model specific serialized proto message (e.g., kvrwset.HashedRWSet for KV and Document data models)
*
*
* optional bytes hashed_rwset = 2;
*/
com.google.protobuf.ByteString getHashedRwset();
/**
*
* Hash of entire private read-write set for a specific collection. This helps in authenticating the private read-write set efficiently
*
*
* optional bytes pvt_rwset_hash = 3;
*/
com.google.protobuf.ByteString getPvtRwsetHash();
}
/**
*
* CollectionHashedReadWriteSet encapsulate the hashed representation for the private read-write set for a collection
*
*
* Protobuf type {@code rwset.CollectionHashedReadWriteSet}
*/
public static final class CollectionHashedReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.CollectionHashedReadWriteSet)
CollectionHashedReadWriteSetOrBuilder {
// Use CollectionHashedReadWriteSet.newBuilder() to construct.
private CollectionHashedReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private CollectionHashedReadWriteSet() {
collectionName_ = "";
hashedRwset_ = com.google.protobuf.ByteString.EMPTY;
pvtRwsetHash_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private CollectionHashedReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 10: {
java.lang.String s = input.readStringRequireUtf8();
collectionName_ = s;
break;
}
case 18: {
hashedRwset_ = input.readBytes();
break;
}
case 26: {
pvtRwsetHash_ = input.readBytes();
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 {
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionHashedReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionHashedReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder.class);
}
public static final int COLLECTION_NAME_FIELD_NUMBER = 1;
private volatile java.lang.Object collectionName_;
/**
* optional string collection_name = 1;
*/
public java.lang.String getCollectionName() {
java.lang.Object ref = collectionName_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
collectionName_ = s;
return s;
}
}
/**
* optional string collection_name = 1;
*/
public com.google.protobuf.ByteString
getCollectionNameBytes() {
java.lang.Object ref = collectionName_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
collectionName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int HASHED_RWSET_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString hashedRwset_;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.HashedRWSet for KV and Document data models)
*
*
* optional bytes hashed_rwset = 2;
*/
public com.google.protobuf.ByteString getHashedRwset() {
return hashedRwset_;
}
public static final int PVT_RWSET_HASH_FIELD_NUMBER = 3;
private com.google.protobuf.ByteString pvtRwsetHash_;
/**
*
* Hash of entire private read-write set for a specific collection. This helps in authenticating the private read-write set efficiently
*
*
* optional bytes pvt_rwset_hash = 3;
*/
public com.google.protobuf.ByteString getPvtRwsetHash() {
return pvtRwsetHash_;
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!getCollectionNameBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, collectionName_);
}
if (!hashedRwset_.isEmpty()) {
output.writeBytes(2, hashedRwset_);
}
if (!pvtRwsetHash_.isEmpty()) {
output.writeBytes(3, pvtRwsetHash_);
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getCollectionNameBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, collectionName_);
}
if (!hashedRwset_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(2, hashedRwset_);
}
if (!pvtRwsetHash_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(3, pvtRwsetHash_);
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet) obj;
boolean result = true;
result = result && getCollectionName()
.equals(other.getCollectionName());
result = result && getHashedRwset()
.equals(other.getHashedRwset());
result = result && getPvtRwsetHash()
.equals(other.getPvtRwsetHash());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + COLLECTION_NAME_FIELD_NUMBER;
hash = (53 * hash) + getCollectionName().hashCode();
hash = (37 * hash) + HASHED_RWSET_FIELD_NUMBER;
hash = (53 * hash) + getHashedRwset().hashCode();
hash = (37 * hash) + PVT_RWSET_HASH_FIELD_NUMBER;
hash = (53 * hash) + getPvtRwsetHash().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* CollectionHashedReadWriteSet encapsulate the hashed representation for the private read-write set for a collection
*
*
* Protobuf type {@code rwset.CollectionHashedReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.CollectionHashedReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionHashedReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionHashedReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
public Builder clear() {
super.clear();
collectionName_ = "";
hashedRwset_ = com.google.protobuf.ByteString.EMPTY;
pvtRwsetHash_ = com.google.protobuf.ByteString.EMPTY;
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionHashedReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet(this);
result.collectionName_ = collectionName_;
result.hashedRwset_ = hashedRwset_;
result.pvtRwsetHash_ = pvtRwsetHash_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet.getDefaultInstance()) return this;
if (!other.getCollectionName().isEmpty()) {
collectionName_ = other.collectionName_;
onChanged();
}
if (other.getHashedRwset() != com.google.protobuf.ByteString.EMPTY) {
setHashedRwset(other.getHashedRwset());
}
if (other.getPvtRwsetHash() != com.google.protobuf.ByteString.EMPTY) {
setPvtRwsetHash(other.getPvtRwsetHash());
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private java.lang.Object collectionName_ = "";
/**
* optional string collection_name = 1;
*/
public java.lang.String getCollectionName() {
java.lang.Object ref = collectionName_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
collectionName_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string collection_name = 1;
*/
public com.google.protobuf.ByteString
getCollectionNameBytes() {
java.lang.Object ref = collectionName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
collectionName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string collection_name = 1;
*/
public Builder setCollectionName(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
collectionName_ = value;
onChanged();
return this;
}
/**
* optional string collection_name = 1;
*/
public Builder clearCollectionName() {
collectionName_ = getDefaultInstance().getCollectionName();
onChanged();
return this;
}
/**
* optional string collection_name = 1;
*/
public Builder setCollectionNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
collectionName_ = value;
onChanged();
return this;
}
private com.google.protobuf.ByteString hashedRwset_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.HashedRWSet for KV and Document data models)
*
*
* optional bytes hashed_rwset = 2;
*/
public com.google.protobuf.ByteString getHashedRwset() {
return hashedRwset_;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.HashedRWSet for KV and Document data models)
*
*
* optional bytes hashed_rwset = 2;
*/
public Builder setHashedRwset(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
hashedRwset_ = value;
onChanged();
return this;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.HashedRWSet for KV and Document data models)
*
*
* optional bytes hashed_rwset = 2;
*/
public Builder clearHashedRwset() {
hashedRwset_ = getDefaultInstance().getHashedRwset();
onChanged();
return this;
}
private com.google.protobuf.ByteString pvtRwsetHash_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Hash of entire private read-write set for a specific collection. This helps in authenticating the private read-write set efficiently
*
*
* optional bytes pvt_rwset_hash = 3;
*/
public com.google.protobuf.ByteString getPvtRwsetHash() {
return pvtRwsetHash_;
}
/**
*
* Hash of entire private read-write set for a specific collection. This helps in authenticating the private read-write set efficiently
*
*
* optional bytes pvt_rwset_hash = 3;
*/
public Builder setPvtRwsetHash(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
pvtRwsetHash_ = value;
onChanged();
return this;
}
/**
*
* Hash of entire private read-write set for a specific collection. This helps in authenticating the private read-write set efficiently
*
*
* optional bytes pvt_rwset_hash = 3;
*/
public Builder clearPvtRwsetHash() {
pvtRwsetHash_ = getDefaultInstance().getPvtRwsetHash();
onChanged();
return this;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.CollectionHashedReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.CollectionHashedReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public CollectionHashedReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new CollectionHashedReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionHashedReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface TxPvtReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.TxPvtReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
int getDataModelValue();
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel();
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
java.util.List
getNsPvtRwsetList();
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getNsPvtRwset(int index);
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
int getNsPvtRwsetCount();
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
java.util.List
getNsPvtRwsetOrBuilderList();
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder getNsPvtRwsetOrBuilder(
int index);
}
/**
*
* TxPvtReadWriteSet encapsulate the private read-write set for a transaction
*
*
* Protobuf type {@code rwset.TxPvtReadWriteSet}
*/
public static final class TxPvtReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.TxPvtReadWriteSet)
TxPvtReadWriteSetOrBuilder {
// Use TxPvtReadWriteSet.newBuilder() to construct.
private TxPvtReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private TxPvtReadWriteSet() {
dataModel_ = 0;
nsPvtRwset_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private TxPvtReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 8: {
int rawValue = input.readEnum();
dataModel_ = rawValue;
break;
}
case 18: {
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
nsPvtRwset_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
nsPvtRwset_.add(
input.readMessage(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.parser(), extensionRegistry));
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 {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
nsPvtRwset_ = java.util.Collections.unmodifiableList(nsPvtRwset_);
}
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.Builder.class);
}
private int bitField0_;
public static final int DATA_MODEL_FIELD_NUMBER = 1;
private int dataModel_;
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public int getDataModelValue() {
return dataModel_;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel result = org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.valueOf(dataModel_);
return result == null ? org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.UNRECOGNIZED : result;
}
public static final int NS_PVT_RWSET_FIELD_NUMBER = 2;
private java.util.List nsPvtRwset_;
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public java.util.List getNsPvtRwsetList() {
return nsPvtRwset_;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public java.util.List
getNsPvtRwsetOrBuilderList() {
return nsPvtRwset_;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public int getNsPvtRwsetCount() {
return nsPvtRwset_.size();
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getNsPvtRwset(int index) {
return nsPvtRwset_.get(index);
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder getNsPvtRwsetOrBuilder(
int index) {
return nsPvtRwset_.get(index);
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (dataModel_ != org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.KV.getNumber()) {
output.writeEnum(1, dataModel_);
}
for (int i = 0; i < nsPvtRwset_.size(); i++) {
output.writeMessage(2, nsPvtRwset_.get(i));
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (dataModel_ != org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.KV.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, dataModel_);
}
for (int i = 0; i < nsPvtRwset_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, nsPvtRwset_.get(i));
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet) obj;
boolean result = true;
result = result && dataModel_ == other.dataModel_;
result = result && getNsPvtRwsetList()
.equals(other.getNsPvtRwsetList());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + DATA_MODEL_FIELD_NUMBER;
hash = (53 * hash) + dataModel_;
if (getNsPvtRwsetCount() > 0) {
hash = (37 * hash) + NS_PVT_RWSET_FIELD_NUMBER;
hash = (53 * hash) + getNsPvtRwsetList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* TxPvtReadWriteSet encapsulate the private read-write set for a transaction
*
*
* Protobuf type {@code rwset.TxPvtReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.TxPvtReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getNsPvtRwsetFieldBuilder();
}
}
public Builder clear() {
super.clear();
dataModel_ = 0;
if (nsPvtRwsetBuilder_ == null) {
nsPvtRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
} else {
nsPvtRwsetBuilder_.clear();
}
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_TxPvtReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.dataModel_ = dataModel_;
if (nsPvtRwsetBuilder_ == null) {
if (((bitField0_ & 0x00000002) == 0x00000002)) {
nsPvtRwset_ = java.util.Collections.unmodifiableList(nsPvtRwset_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.nsPvtRwset_ = nsPvtRwset_;
} else {
result.nsPvtRwset_ = nsPvtRwsetBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet.getDefaultInstance()) return this;
if (other.dataModel_ != 0) {
setDataModelValue(other.getDataModelValue());
}
if (nsPvtRwsetBuilder_ == null) {
if (!other.nsPvtRwset_.isEmpty()) {
if (nsPvtRwset_.isEmpty()) {
nsPvtRwset_ = other.nsPvtRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.addAll(other.nsPvtRwset_);
}
onChanged();
}
} else {
if (!other.nsPvtRwset_.isEmpty()) {
if (nsPvtRwsetBuilder_.isEmpty()) {
nsPvtRwsetBuilder_.dispose();
nsPvtRwsetBuilder_ = null;
nsPvtRwset_ = other.nsPvtRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
nsPvtRwsetBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getNsPvtRwsetFieldBuilder() : null;
} else {
nsPvtRwsetBuilder_.addAllMessages(other.nsPvtRwset_);
}
}
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private int dataModel_ = 0;
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public int getDataModelValue() {
return dataModel_;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder setDataModelValue(int value) {
dataModel_ = value;
onChanged();
return this;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel getDataModel() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel result = org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.valueOf(dataModel_);
return result == null ? org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel.UNRECOGNIZED : result;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder setDataModel(org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxReadWriteSet.DataModel value) {
if (value == null) {
throw new NullPointerException();
}
dataModel_ = value.getNumber();
onChanged();
return this;
}
/**
* optional .rwset.TxReadWriteSet.DataModel data_model = 1;
*/
public Builder clearDataModel() {
dataModel_ = 0;
onChanged();
return this;
}
private java.util.List nsPvtRwset_ =
java.util.Collections.emptyList();
private void ensureNsPvtRwsetIsMutable() {
if (!((bitField0_ & 0x00000002) == 0x00000002)) {
nsPvtRwset_ = new java.util.ArrayList(nsPvtRwset_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder> nsPvtRwsetBuilder_;
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public java.util.List getNsPvtRwsetList() {
if (nsPvtRwsetBuilder_ == null) {
return java.util.Collections.unmodifiableList(nsPvtRwset_);
} else {
return nsPvtRwsetBuilder_.getMessageList();
}
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public int getNsPvtRwsetCount() {
if (nsPvtRwsetBuilder_ == null) {
return nsPvtRwset_.size();
} else {
return nsPvtRwsetBuilder_.getCount();
}
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getNsPvtRwset(int index) {
if (nsPvtRwsetBuilder_ == null) {
return nsPvtRwset_.get(index);
} else {
return nsPvtRwsetBuilder_.getMessage(index);
}
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder setNsPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet value) {
if (nsPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.set(index, value);
onChanged();
} else {
nsPvtRwsetBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder setNsPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder builderForValue) {
if (nsPvtRwsetBuilder_ == null) {
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.set(index, builderForValue.build());
onChanged();
} else {
nsPvtRwsetBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder addNsPvtRwset(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet value) {
if (nsPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.add(value);
onChanged();
} else {
nsPvtRwsetBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder addNsPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet value) {
if (nsPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.add(index, value);
onChanged();
} else {
nsPvtRwsetBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder addNsPvtRwset(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder builderForValue) {
if (nsPvtRwsetBuilder_ == null) {
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.add(builderForValue.build());
onChanged();
} else {
nsPvtRwsetBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder addNsPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder builderForValue) {
if (nsPvtRwsetBuilder_ == null) {
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.add(index, builderForValue.build());
onChanged();
} else {
nsPvtRwsetBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder addAllNsPvtRwset(
java.lang.Iterable values) {
if (nsPvtRwsetBuilder_ == null) {
ensureNsPvtRwsetIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, nsPvtRwset_);
onChanged();
} else {
nsPvtRwsetBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder clearNsPvtRwset() {
if (nsPvtRwsetBuilder_ == null) {
nsPvtRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
nsPvtRwsetBuilder_.clear();
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public Builder removeNsPvtRwset(int index) {
if (nsPvtRwsetBuilder_ == null) {
ensureNsPvtRwsetIsMutable();
nsPvtRwset_.remove(index);
onChanged();
} else {
nsPvtRwsetBuilder_.remove(index);
}
return this;
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder getNsPvtRwsetBuilder(
int index) {
return getNsPvtRwsetFieldBuilder().getBuilder(index);
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder getNsPvtRwsetOrBuilder(
int index) {
if (nsPvtRwsetBuilder_ == null) {
return nsPvtRwset_.get(index); } else {
return nsPvtRwsetBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public java.util.List
getNsPvtRwsetOrBuilderList() {
if (nsPvtRwsetBuilder_ != null) {
return nsPvtRwsetBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(nsPvtRwset_);
}
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder addNsPvtRwsetBuilder() {
return getNsPvtRwsetFieldBuilder().addBuilder(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder addNsPvtRwsetBuilder(
int index) {
return getNsPvtRwsetFieldBuilder().addBuilder(
index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.NsPvtReadWriteSet ns_pvt_rwset = 2;
*/
public java.util.List
getNsPvtRwsetBuilderList() {
return getNsPvtRwsetFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder>
getNsPvtRwsetFieldBuilder() {
if (nsPvtRwsetBuilder_ == null) {
nsPvtRwsetBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder>(
nsPvtRwset_,
((bitField0_ & 0x00000002) == 0x00000002),
getParentForChildren(),
isClean());
nsPvtRwset_ = null;
}
return nsPvtRwsetBuilder_;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.TxPvtReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.TxPvtReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public TxPvtReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new TxPvtReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.TxPvtReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface NsPvtReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.NsPvtReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional string namespace = 1;
*/
java.lang.String getNamespace();
/**
* optional string namespace = 1;
*/
com.google.protobuf.ByteString
getNamespaceBytes();
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
java.util.List
getCollectionPvtRwsetList();
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getCollectionPvtRwset(int index);
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
int getCollectionPvtRwsetCount();
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
java.util.List
getCollectionPvtRwsetOrBuilderList();
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder getCollectionPvtRwsetOrBuilder(
int index);
}
/**
*
* NsPvtReadWriteSet encapsulates the private read-write set for a chaincode
*
*
* Protobuf type {@code rwset.NsPvtReadWriteSet}
*/
public static final class NsPvtReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.NsPvtReadWriteSet)
NsPvtReadWriteSetOrBuilder {
// Use NsPvtReadWriteSet.newBuilder() to construct.
private NsPvtReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private NsPvtReadWriteSet() {
namespace_ = "";
collectionPvtRwset_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private NsPvtReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 10: {
java.lang.String s = input.readStringRequireUtf8();
namespace_ = s;
break;
}
case 18: {
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
collectionPvtRwset_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
collectionPvtRwset_.add(
input.readMessage(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.parser(), extensionRegistry));
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 {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
collectionPvtRwset_ = java.util.Collections.unmodifiableList(collectionPvtRwset_);
}
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder.class);
}
private int bitField0_;
public static final int NAMESPACE_FIELD_NUMBER = 1;
private volatile java.lang.Object namespace_;
/**
* optional string namespace = 1;
*/
public java.lang.String getNamespace() {
java.lang.Object ref = namespace_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
namespace_ = s;
return s;
}
}
/**
* optional string namespace = 1;
*/
public com.google.protobuf.ByteString
getNamespaceBytes() {
java.lang.Object ref = namespace_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
namespace_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int COLLECTION_PVT_RWSET_FIELD_NUMBER = 2;
private java.util.List collectionPvtRwset_;
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public java.util.List getCollectionPvtRwsetList() {
return collectionPvtRwset_;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public java.util.List
getCollectionPvtRwsetOrBuilderList() {
return collectionPvtRwset_;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public int getCollectionPvtRwsetCount() {
return collectionPvtRwset_.size();
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getCollectionPvtRwset(int index) {
return collectionPvtRwset_.get(index);
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder getCollectionPvtRwsetOrBuilder(
int index) {
return collectionPvtRwset_.get(index);
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!getNamespaceBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, namespace_);
}
for (int i = 0; i < collectionPvtRwset_.size(); i++) {
output.writeMessage(2, collectionPvtRwset_.get(i));
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getNamespaceBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, namespace_);
}
for (int i = 0; i < collectionPvtRwset_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, collectionPvtRwset_.get(i));
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet) obj;
boolean result = true;
result = result && getNamespace()
.equals(other.getNamespace());
result = result && getCollectionPvtRwsetList()
.equals(other.getCollectionPvtRwsetList());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + NAMESPACE_FIELD_NUMBER;
hash = (53 * hash) + getNamespace().hashCode();
if (getCollectionPvtRwsetCount() > 0) {
hash = (37 * hash) + COLLECTION_PVT_RWSET_FIELD_NUMBER;
hash = (53 * hash) + getCollectionPvtRwsetList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* NsPvtReadWriteSet encapsulates the private read-write set for a chaincode
*
*
* Protobuf type {@code rwset.NsPvtReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.NsPvtReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCollectionPvtRwsetFieldBuilder();
}
}
public Builder clear() {
super.clear();
namespace_ = "";
if (collectionPvtRwsetBuilder_ == null) {
collectionPvtRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
} else {
collectionPvtRwsetBuilder_.clear();
}
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_NsPvtReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.namespace_ = namespace_;
if (collectionPvtRwsetBuilder_ == null) {
if (((bitField0_ & 0x00000002) == 0x00000002)) {
collectionPvtRwset_ = java.util.Collections.unmodifiableList(collectionPvtRwset_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.collectionPvtRwset_ = collectionPvtRwset_;
} else {
result.collectionPvtRwset_ = collectionPvtRwsetBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet.getDefaultInstance()) return this;
if (!other.getNamespace().isEmpty()) {
namespace_ = other.namespace_;
onChanged();
}
if (collectionPvtRwsetBuilder_ == null) {
if (!other.collectionPvtRwset_.isEmpty()) {
if (collectionPvtRwset_.isEmpty()) {
collectionPvtRwset_ = other.collectionPvtRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.addAll(other.collectionPvtRwset_);
}
onChanged();
}
} else {
if (!other.collectionPvtRwset_.isEmpty()) {
if (collectionPvtRwsetBuilder_.isEmpty()) {
collectionPvtRwsetBuilder_.dispose();
collectionPvtRwsetBuilder_ = null;
collectionPvtRwset_ = other.collectionPvtRwset_;
bitField0_ = (bitField0_ & ~0x00000002);
collectionPvtRwsetBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getCollectionPvtRwsetFieldBuilder() : null;
} else {
collectionPvtRwsetBuilder_.addAllMessages(other.collectionPvtRwset_);
}
}
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private java.lang.Object namespace_ = "";
/**
* optional string namespace = 1;
*/
public java.lang.String getNamespace() {
java.lang.Object ref = namespace_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
namespace_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string namespace = 1;
*/
public com.google.protobuf.ByteString
getNamespaceBytes() {
java.lang.Object ref = namespace_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
namespace_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string namespace = 1;
*/
public Builder setNamespace(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
namespace_ = value;
onChanged();
return this;
}
/**
* optional string namespace = 1;
*/
public Builder clearNamespace() {
namespace_ = getDefaultInstance().getNamespace();
onChanged();
return this;
}
/**
* optional string namespace = 1;
*/
public Builder setNamespaceBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
namespace_ = value;
onChanged();
return this;
}
private java.util.List collectionPvtRwset_ =
java.util.Collections.emptyList();
private void ensureCollectionPvtRwsetIsMutable() {
if (!((bitField0_ & 0x00000002) == 0x00000002)) {
collectionPvtRwset_ = new java.util.ArrayList(collectionPvtRwset_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder> collectionPvtRwsetBuilder_;
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public java.util.List getCollectionPvtRwsetList() {
if (collectionPvtRwsetBuilder_ == null) {
return java.util.Collections.unmodifiableList(collectionPvtRwset_);
} else {
return collectionPvtRwsetBuilder_.getMessageList();
}
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public int getCollectionPvtRwsetCount() {
if (collectionPvtRwsetBuilder_ == null) {
return collectionPvtRwset_.size();
} else {
return collectionPvtRwsetBuilder_.getCount();
}
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getCollectionPvtRwset(int index) {
if (collectionPvtRwsetBuilder_ == null) {
return collectionPvtRwset_.get(index);
} else {
return collectionPvtRwsetBuilder_.getMessage(index);
}
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder setCollectionPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet value) {
if (collectionPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.set(index, value);
onChanged();
} else {
collectionPvtRwsetBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder setCollectionPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder builderForValue) {
if (collectionPvtRwsetBuilder_ == null) {
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.set(index, builderForValue.build());
onChanged();
} else {
collectionPvtRwsetBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder addCollectionPvtRwset(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet value) {
if (collectionPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.add(value);
onChanged();
} else {
collectionPvtRwsetBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder addCollectionPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet value) {
if (collectionPvtRwsetBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.add(index, value);
onChanged();
} else {
collectionPvtRwsetBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder addCollectionPvtRwset(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder builderForValue) {
if (collectionPvtRwsetBuilder_ == null) {
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.add(builderForValue.build());
onChanged();
} else {
collectionPvtRwsetBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder addCollectionPvtRwset(
int index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder builderForValue) {
if (collectionPvtRwsetBuilder_ == null) {
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.add(index, builderForValue.build());
onChanged();
} else {
collectionPvtRwsetBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder addAllCollectionPvtRwset(
java.lang.Iterable values) {
if (collectionPvtRwsetBuilder_ == null) {
ensureCollectionPvtRwsetIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, collectionPvtRwset_);
onChanged();
} else {
collectionPvtRwsetBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder clearCollectionPvtRwset() {
if (collectionPvtRwsetBuilder_ == null) {
collectionPvtRwset_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
collectionPvtRwsetBuilder_.clear();
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public Builder removeCollectionPvtRwset(int index) {
if (collectionPvtRwsetBuilder_ == null) {
ensureCollectionPvtRwsetIsMutable();
collectionPvtRwset_.remove(index);
onChanged();
} else {
collectionPvtRwsetBuilder_.remove(index);
}
return this;
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder getCollectionPvtRwsetBuilder(
int index) {
return getCollectionPvtRwsetFieldBuilder().getBuilder(index);
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder getCollectionPvtRwsetOrBuilder(
int index) {
if (collectionPvtRwsetBuilder_ == null) {
return collectionPvtRwset_.get(index); } else {
return collectionPvtRwsetBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public java.util.List
getCollectionPvtRwsetOrBuilderList() {
if (collectionPvtRwsetBuilder_ != null) {
return collectionPvtRwsetBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(collectionPvtRwset_);
}
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder addCollectionPvtRwsetBuilder() {
return getCollectionPvtRwsetFieldBuilder().addBuilder(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder addCollectionPvtRwsetBuilder(
int index) {
return getCollectionPvtRwsetFieldBuilder().addBuilder(
index, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.getDefaultInstance());
}
/**
* repeated .rwset.CollectionPvtReadWriteSet collection_pvt_rwset = 2;
*/
public java.util.List
getCollectionPvtRwsetBuilderList() {
return getCollectionPvtRwsetFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder>
getCollectionPvtRwsetFieldBuilder() {
if (collectionPvtRwsetBuilder_ == null) {
collectionPvtRwsetBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder>(
collectionPvtRwset_,
((bitField0_ & 0x00000002) == 0x00000002),
getParentForChildren(),
isClean());
collectionPvtRwset_ = null;
}
return collectionPvtRwsetBuilder_;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.NsPvtReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.NsPvtReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public NsPvtReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new NsPvtReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.NsPvtReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface CollectionPvtReadWriteSetOrBuilder extends
// @@protoc_insertion_point(interface_extends:rwset.CollectionPvtReadWriteSet)
com.google.protobuf.MessageOrBuilder {
/**
* optional string collection_name = 1;
*/
java.lang.String getCollectionName();
/**
* optional string collection_name = 1;
*/
com.google.protobuf.ByteString
getCollectionNameBytes();
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
com.google.protobuf.ByteString getRwset();
}
/**
*
* CollectionPvtReadWriteSet encapsulates the private read-write set for a collection
*
*
* Protobuf type {@code rwset.CollectionPvtReadWriteSet}
*/
public static final class CollectionPvtReadWriteSet extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:rwset.CollectionPvtReadWriteSet)
CollectionPvtReadWriteSetOrBuilder {
// Use CollectionPvtReadWriteSet.newBuilder() to construct.
private CollectionPvtReadWriteSet(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private CollectionPvtReadWriteSet() {
collectionName_ = "";
rwset_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private CollectionPvtReadWriteSet(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
int mutable_bitField0_ = 0;
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!input.skipField(tag)) {
done = true;
}
break;
}
case 10: {
java.lang.String s = input.readStringRequireUtf8();
collectionName_ = s;
break;
}
case 18: {
rwset_ = input.readBytes();
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 {
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder.class);
}
public static final int COLLECTION_NAME_FIELD_NUMBER = 1;
private volatile java.lang.Object collectionName_;
/**
* optional string collection_name = 1;
*/
public java.lang.String getCollectionName() {
java.lang.Object ref = collectionName_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
collectionName_ = s;
return s;
}
}
/**
* optional string collection_name = 1;
*/
public com.google.protobuf.ByteString
getCollectionNameBytes() {
java.lang.Object ref = collectionName_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
collectionName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int RWSET_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString rwset_;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public com.google.protobuf.ByteString getRwset() {
return rwset_;
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!getCollectionNameBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, collectionName_);
}
if (!rwset_.isEmpty()) {
output.writeBytes(2, rwset_);
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getCollectionNameBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, collectionName_);
}
if (!rwset_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(2, rwset_);
}
memoizedSize = size;
return size;
}
private static final long serialVersionUID = 0L;
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet other = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet) obj;
boolean result = true;
result = result && getCollectionName()
.equals(other.getCollectionName());
result = result && getRwset()
.equals(other.getRwset());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + COLLECTION_NAME_FIELD_NUMBER;
hash = (53 * hash) + getCollectionName().hashCode();
hash = (37 * hash) + RWSET_FIELD_NUMBER;
hash = (53 * hash) + getRwset().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet 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 org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
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;
}
/**
*
* CollectionPvtReadWriteSet encapsulates the private read-write set for a collection
*
*
* Protobuf type {@code rwset.CollectionPvtReadWriteSet}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:rwset.CollectionPvtReadWriteSet)
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionPvtReadWriteSet_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionPvtReadWriteSet_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.class, org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
public Builder clear() {
super.clear();
collectionName_ = "";
rwset_ = com.google.protobuf.ByteString.EMPTY;
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.internal_static_rwset_CollectionPvtReadWriteSet_descriptor;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.getDefaultInstance();
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet build() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet buildPartial() {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet result = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet(this);
result.collectionName_ = collectionName_;
result.rwset_ = rwset_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet) {
return mergeFrom((org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet other) {
if (other == org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet.getDefaultInstance()) return this;
if (!other.getCollectionName().isEmpty()) {
collectionName_ = other.collectionName_;
onChanged();
}
if (other.getRwset() != com.google.protobuf.ByteString.EMPTY) {
setRwset(other.getRwset());
}
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private java.lang.Object collectionName_ = "";
/**
* optional string collection_name = 1;
*/
public java.lang.String getCollectionName() {
java.lang.Object ref = collectionName_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
collectionName_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string collection_name = 1;
*/
public com.google.protobuf.ByteString
getCollectionNameBytes() {
java.lang.Object ref = collectionName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
collectionName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string collection_name = 1;
*/
public Builder setCollectionName(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
collectionName_ = value;
onChanged();
return this;
}
/**
* optional string collection_name = 1;
*/
public Builder clearCollectionName() {
collectionName_ = getDefaultInstance().getCollectionName();
onChanged();
return this;
}
/**
* optional string collection_name = 1;
*/
public Builder setCollectionNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
collectionName_ = value;
onChanged();
return this;
}
private com.google.protobuf.ByteString rwset_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public com.google.protobuf.ByteString getRwset() {
return rwset_;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public Builder setRwset(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
rwset_ = value;
onChanged();
return this;
}
/**
*
* Data model specific serialized proto message (e.g., kvrwset.KVRWSet for KV and Document data models)
*
*
* optional bytes rwset = 2;
*/
public Builder clearRwset() {
rwset_ = getDefaultInstance().getRwset();
onChanged();
return this;
}
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return this;
}
// @@protoc_insertion_point(builder_scope:rwset.CollectionPvtReadWriteSet)
}
// @@protoc_insertion_point(class_scope:rwset.CollectionPvtReadWriteSet)
private static final org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet();
}
public static org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public CollectionPvtReadWriteSet parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new CollectionPvtReadWriteSet(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
public org.hyperledger.fabric.protos.ledger.rwset.Rwset.CollectionPvtReadWriteSet getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_TxReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_TxReadWriteSet_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_NsReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_NsReadWriteSet_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_CollectionHashedReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_CollectionHashedReadWriteSet_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_TxPvtReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_TxPvtReadWriteSet_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_NsPvtReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_NsPvtReadWriteSet_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_rwset_CollectionPvtReadWriteSet_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_rwset_CollectionPvtReadWriteSet_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n\030ledger/rwset/rwset.proto\022\005rwset\"\203\001\n\016Tx" +
"ReadWriteSet\0223\n\ndata_model\030\001 \001(\0162\037.rwset" +
".TxReadWriteSet.DataModel\022\'\n\010ns_rwset\030\002 " +
"\003(\0132\025.rwset.NsReadWriteSet\"\023\n\tDataModel\022" +
"\006\n\002KV\020\000\"x\n\016NsReadWriteSet\022\021\n\tnamespace\030\001" +
" \001(\t\022\r\n\005rwset\030\002 \001(\014\022D\n\027collection_hashed" +
"_rwset\030\003 \003(\0132#.rwset.CollectionHashedRea" +
"dWriteSet\"e\n\034CollectionHashedReadWriteSe" +
"t\022\027\n\017collection_name\030\001 \001(\t\022\024\n\014hashed_rws" +
"et\030\002 \001(\014\022\026\n\016pvt_rwset_hash\030\003 \001(\014\"x\n\021TxPv",
"tReadWriteSet\0223\n\ndata_model\030\001 \001(\0162\037.rwse" +
"t.TxReadWriteSet.DataModel\022.\n\014ns_pvt_rws" +
"et\030\002 \003(\0132\030.rwset.NsPvtReadWriteSet\"f\n\021Ns" +
"PvtReadWriteSet\022\021\n\tnamespace\030\001 \001(\t\022>\n\024co" +
"llection_pvt_rwset\030\002 \003(\0132 .rwset.Collect" +
"ionPvtReadWriteSet\"C\n\031CollectionPvtReadW" +
"riteSet\022\027\n\017collection_name\030\001 \001(\t\022\r\n\005rwse" +
"t\030\002 \001(\014B_\n*org.hyperledger.fabric.protos" +
".ledger.rwsetZ1github.com/hyperledger/fa" +
"bric/protos/ledger/rwsetb\006proto3"
};
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() {
public com.google.protobuf.ExtensionRegistry assignDescriptors(
com.google.protobuf.Descriptors.FileDescriptor root) {
descriptor = root;
return null;
}
};
com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
}, assigner);
internal_static_rwset_TxReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_rwset_TxReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_TxReadWriteSet_descriptor,
new java.lang.String[] { "DataModel", "NsRwset", });
internal_static_rwset_NsReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_rwset_NsReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_NsReadWriteSet_descriptor,
new java.lang.String[] { "Namespace", "Rwset", "CollectionHashedRwset", });
internal_static_rwset_CollectionHashedReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(2);
internal_static_rwset_CollectionHashedReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_CollectionHashedReadWriteSet_descriptor,
new java.lang.String[] { "CollectionName", "HashedRwset", "PvtRwsetHash", });
internal_static_rwset_TxPvtReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(3);
internal_static_rwset_TxPvtReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_TxPvtReadWriteSet_descriptor,
new java.lang.String[] { "DataModel", "NsPvtRwset", });
internal_static_rwset_NsPvtReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(4);
internal_static_rwset_NsPvtReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_NsPvtReadWriteSet_descriptor,
new java.lang.String[] { "Namespace", "CollectionPvtRwset", });
internal_static_rwset_CollectionPvtReadWriteSet_descriptor =
getDescriptor().getMessageTypes().get(5);
internal_static_rwset_CollectionPvtReadWriteSet_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_rwset_CollectionPvtReadWriteSet_descriptor,
new java.lang.String[] { "CollectionName", "Rwset", });
}
// @@protoc_insertion_point(outer_class_scope)
}