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.peer.Configuration Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: peer/configuration.proto
package org.hyperledger.fabric.protos.peer;
public final class Configuration {
private Configuration() {}
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 AnchorPeersOrBuilder extends
// @@protoc_insertion_point(interface_extends:protos.AnchorPeers)
com.google.protobuf.MessageOrBuilder {
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
java.util.List
getAnchorPeersList();
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer getAnchorPeers(int index);
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
int getAnchorPeersCount();
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
java.util.List
getAnchorPeersOrBuilderList();
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder getAnchorPeersOrBuilder(
int index);
}
/**
*
* AnchorPeers simply represents list of anchor peers which is used in ConfigurationItem
*
*
* Protobuf type {@code protos.AnchorPeers}
*/
public static final class AnchorPeers extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:protos.AnchorPeers)
AnchorPeersOrBuilder {
// Use AnchorPeers.newBuilder() to construct.
private AnchorPeers(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private AnchorPeers() {
anchorPeers_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private AnchorPeers(
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: {
if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
anchorPeers_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000001;
}
anchorPeers_.add(
input.readMessage(org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.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_ & 0x00000001) == 0x00000001)) {
anchorPeers_ = java.util.Collections.unmodifiableList(anchorPeers_);
}
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeers_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeers_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.class, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.Builder.class);
}
public static final int ANCHOR_PEERS_FIELD_NUMBER = 1;
private java.util.List anchorPeers_;
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public java.util.List getAnchorPeersList() {
return anchorPeers_;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public java.util.List
getAnchorPeersOrBuilderList() {
return anchorPeers_;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public int getAnchorPeersCount() {
return anchorPeers_.size();
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer getAnchorPeers(int index) {
return anchorPeers_.get(index);
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder getAnchorPeersOrBuilder(
int index) {
return anchorPeers_.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 {
for (int i = 0; i < anchorPeers_.size(); i++) {
output.writeMessage(1, anchorPeers_.get(i));
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < anchorPeers_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, anchorPeers_.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.peer.Configuration.AnchorPeers)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers other = (org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers) obj;
boolean result = true;
result = result && getAnchorPeersList()
.equals(other.getAnchorPeersList());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
if (getAnchorPeersCount() > 0) {
hash = (37 * hash) + ANCHOR_PEERS_FIELD_NUMBER;
hash = (53 * hash) + getAnchorPeersList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers 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.peer.Configuration.AnchorPeers parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers 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.peer.Configuration.AnchorPeers parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers 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.peer.Configuration.AnchorPeers parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers 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.peer.Configuration.AnchorPeers 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;
}
/**
*
* AnchorPeers simply represents list of anchor peers which is used in ConfigurationItem
*
*
* Protobuf type {@code protos.AnchorPeers}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:protos.AnchorPeers)
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeersOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeers_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeers_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.class, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getAnchorPeersFieldBuilder();
}
}
public Builder clear() {
super.clear();
if (anchorPeersBuilder_ == null) {
anchorPeers_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else {
anchorPeersBuilder_.clear();
}
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeers_descriptor;
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.getDefaultInstance();
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers build() {
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers buildPartial() {
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers result = new org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers(this);
int from_bitField0_ = bitField0_;
if (anchorPeersBuilder_ == null) {
if (((bitField0_ & 0x00000001) == 0x00000001)) {
anchorPeers_ = java.util.Collections.unmodifiableList(anchorPeers_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.anchorPeers_ = anchorPeers_;
} else {
result.anchorPeers_ = anchorPeersBuilder_.build();
}
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.peer.Configuration.AnchorPeers) {
return mergeFrom((org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers other) {
if (other == org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers.getDefaultInstance()) return this;
if (anchorPeersBuilder_ == null) {
if (!other.anchorPeers_.isEmpty()) {
if (anchorPeers_.isEmpty()) {
anchorPeers_ = other.anchorPeers_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureAnchorPeersIsMutable();
anchorPeers_.addAll(other.anchorPeers_);
}
onChanged();
}
} else {
if (!other.anchorPeers_.isEmpty()) {
if (anchorPeersBuilder_.isEmpty()) {
anchorPeersBuilder_.dispose();
anchorPeersBuilder_ = null;
anchorPeers_ = other.anchorPeers_;
bitField0_ = (bitField0_ & ~0x00000001);
anchorPeersBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getAnchorPeersFieldBuilder() : null;
} else {
anchorPeersBuilder_.addAllMessages(other.anchorPeers_);
}
}
}
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.peer.Configuration.AnchorPeers parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private java.util.List anchorPeers_ =
java.util.Collections.emptyList();
private void ensureAnchorPeersIsMutable() {
if (!((bitField0_ & 0x00000001) == 0x00000001)) {
anchorPeers_ = new java.util.ArrayList(anchorPeers_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder> anchorPeersBuilder_;
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public java.util.List getAnchorPeersList() {
if (anchorPeersBuilder_ == null) {
return java.util.Collections.unmodifiableList(anchorPeers_);
} else {
return anchorPeersBuilder_.getMessageList();
}
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public int getAnchorPeersCount() {
if (anchorPeersBuilder_ == null) {
return anchorPeers_.size();
} else {
return anchorPeersBuilder_.getCount();
}
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer getAnchorPeers(int index) {
if (anchorPeersBuilder_ == null) {
return anchorPeers_.get(index);
} else {
return anchorPeersBuilder_.getMessage(index);
}
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder setAnchorPeers(
int index, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer value) {
if (anchorPeersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAnchorPeersIsMutable();
anchorPeers_.set(index, value);
onChanged();
} else {
anchorPeersBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder setAnchorPeers(
int index, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder builderForValue) {
if (anchorPeersBuilder_ == null) {
ensureAnchorPeersIsMutable();
anchorPeers_.set(index, builderForValue.build());
onChanged();
} else {
anchorPeersBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder addAnchorPeers(org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer value) {
if (anchorPeersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAnchorPeersIsMutable();
anchorPeers_.add(value);
onChanged();
} else {
anchorPeersBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder addAnchorPeers(
int index, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer value) {
if (anchorPeersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAnchorPeersIsMutable();
anchorPeers_.add(index, value);
onChanged();
} else {
anchorPeersBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder addAnchorPeers(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder builderForValue) {
if (anchorPeersBuilder_ == null) {
ensureAnchorPeersIsMutable();
anchorPeers_.add(builderForValue.build());
onChanged();
} else {
anchorPeersBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder addAnchorPeers(
int index, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder builderForValue) {
if (anchorPeersBuilder_ == null) {
ensureAnchorPeersIsMutable();
anchorPeers_.add(index, builderForValue.build());
onChanged();
} else {
anchorPeersBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder addAllAnchorPeers(
java.lang.Iterable values) {
if (anchorPeersBuilder_ == null) {
ensureAnchorPeersIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, anchorPeers_);
onChanged();
} else {
anchorPeersBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder clearAnchorPeers() {
if (anchorPeersBuilder_ == null) {
anchorPeers_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
anchorPeersBuilder_.clear();
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public Builder removeAnchorPeers(int index) {
if (anchorPeersBuilder_ == null) {
ensureAnchorPeersIsMutable();
anchorPeers_.remove(index);
onChanged();
} else {
anchorPeersBuilder_.remove(index);
}
return this;
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder getAnchorPeersBuilder(
int index) {
return getAnchorPeersFieldBuilder().getBuilder(index);
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder getAnchorPeersOrBuilder(
int index) {
if (anchorPeersBuilder_ == null) {
return anchorPeers_.get(index); } else {
return anchorPeersBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public java.util.List
getAnchorPeersOrBuilderList() {
if (anchorPeersBuilder_ != null) {
return anchorPeersBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(anchorPeers_);
}
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder addAnchorPeersBuilder() {
return getAnchorPeersFieldBuilder().addBuilder(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.getDefaultInstance());
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder addAnchorPeersBuilder(
int index) {
return getAnchorPeersFieldBuilder().addBuilder(
index, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.getDefaultInstance());
}
/**
* repeated .protos.AnchorPeer anchor_peers = 1;
*/
public java.util.List
getAnchorPeersBuilderList() {
return getAnchorPeersFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder>
getAnchorPeersFieldBuilder() {
if (anchorPeersBuilder_ == null) {
anchorPeersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder>(
anchorPeers_,
((bitField0_ & 0x00000001) == 0x00000001),
getParentForChildren(),
isClean());
anchorPeers_ = null;
}
return anchorPeersBuilder_;
}
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:protos.AnchorPeers)
}
// @@protoc_insertion_point(class_scope:protos.AnchorPeers)
private static final org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers();
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeers getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public AnchorPeers parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new AnchorPeers(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.peer.Configuration.AnchorPeers getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface AnchorPeerOrBuilder extends
// @@protoc_insertion_point(interface_extends:protos.AnchorPeer)
com.google.protobuf.MessageOrBuilder {
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
java.lang.String getHost();
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
com.google.protobuf.ByteString
getHostBytes();
/**
*
* The port number
*
*
* optional int32 port = 2;
*/
int getPort();
}
/**
*
* AnchorPeer message structure which provides information about anchor peer, it includes host name,
* port number and peer certificate.
*
*
* Protobuf type {@code protos.AnchorPeer}
*/
public static final class AnchorPeer extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:protos.AnchorPeer)
AnchorPeerOrBuilder {
// Use AnchorPeer.newBuilder() to construct.
private AnchorPeer(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private AnchorPeer() {
host_ = "";
port_ = 0;
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private AnchorPeer(
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();
host_ = s;
break;
}
case 16: {
port_ = input.readInt32();
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.peer.Configuration.internal_static_protos_AnchorPeer_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.class, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder.class);
}
public static final int HOST_FIELD_NUMBER = 1;
private volatile java.lang.Object host_;
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public java.lang.String getHost() {
java.lang.Object ref = host_;
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();
host_ = s;
return s;
}
}
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public com.google.protobuf.ByteString
getHostBytes() {
java.lang.Object ref = host_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
host_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PORT_FIELD_NUMBER = 2;
private int port_;
/**
*
* The port number
*
*
* optional int32 port = 2;
*/
public int getPort() {
return port_;
}
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 (!getHostBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, host_);
}
if (port_ != 0) {
output.writeInt32(2, port_);
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getHostBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, host_);
}
if (port_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(2, port_);
}
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.peer.Configuration.AnchorPeer)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer other = (org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer) obj;
boolean result = true;
result = result && getHost()
.equals(other.getHost());
result = result && (getPort()
== other.getPort());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + HOST_FIELD_NUMBER;
hash = (53 * hash) + getHost().hashCode();
hash = (37 * hash) + PORT_FIELD_NUMBER;
hash = (53 * hash) + getPort();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer 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.peer.Configuration.AnchorPeer parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer 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.peer.Configuration.AnchorPeer parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer 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.peer.Configuration.AnchorPeer parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer 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.peer.Configuration.AnchorPeer 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;
}
/**
*
* AnchorPeer message structure which provides information about anchor peer, it includes host name,
* port number and peer certificate.
*
*
* Protobuf type {@code protos.AnchorPeer}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:protos.AnchorPeer)
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeerOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeer_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.class, org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.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();
host_ = "";
port_ = 0;
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_AnchorPeer_descriptor;
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.getDefaultInstance();
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer build() {
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer buildPartial() {
org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer result = new org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer(this);
result.host_ = host_;
result.port_ = port_;
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.peer.Configuration.AnchorPeer) {
return mergeFrom((org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer other) {
if (other == org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer.getDefaultInstance()) return this;
if (!other.getHost().isEmpty()) {
host_ = other.host_;
onChanged();
}
if (other.getPort() != 0) {
setPort(other.getPort());
}
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.peer.Configuration.AnchorPeer parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private java.lang.Object host_ = "";
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public java.lang.String getHost() {
java.lang.Object ref = host_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
host_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public com.google.protobuf.ByteString
getHostBytes() {
java.lang.Object ref = host_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
host_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public Builder setHost(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
host_ = value;
onChanged();
return this;
}
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public Builder clearHost() {
host_ = getDefaultInstance().getHost();
onChanged();
return this;
}
/**
*
* DNS host name of the anchor peer
*
*
* optional string host = 1;
*/
public Builder setHostBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
host_ = value;
onChanged();
return this;
}
private int port_ ;
/**
*
* The port number
*
*
* optional int32 port = 2;
*/
public int getPort() {
return port_;
}
/**
*
* The port number
*
*
* optional int32 port = 2;
*/
public Builder setPort(int value) {
port_ = value;
onChanged();
return this;
}
/**
*
* The port number
*
*
* optional int32 port = 2;
*/
public Builder clearPort() {
port_ = 0;
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:protos.AnchorPeer)
}
// @@protoc_insertion_point(class_scope:protos.AnchorPeer)
private static final org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer();
}
public static org.hyperledger.fabric.protos.peer.Configuration.AnchorPeer getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public AnchorPeer parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new AnchorPeer(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.peer.Configuration.AnchorPeer getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface APIResourceOrBuilder extends
// @@protoc_insertion_point(interface_extends:protos.APIResource)
com.google.protobuf.MessageOrBuilder {
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
java.lang.String getPolicyRef();
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
com.google.protobuf.ByteString
getPolicyRefBytes();
}
/**
*
* APIResource represents an API resource in the peer whose ACL
* is determined by the policy_ref field
*
*
* Protobuf type {@code protos.APIResource}
*/
public static final class APIResource extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:protos.APIResource)
APIResourceOrBuilder {
// Use APIResource.newBuilder() to construct.
private APIResource(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private APIResource() {
policyRef_ = "";
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private APIResource(
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();
policyRef_ = s;
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.peer.Configuration.internal_static_protos_APIResource_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_APIResource_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.APIResource.class, org.hyperledger.fabric.protos.peer.Configuration.APIResource.Builder.class);
}
public static final int POLICY_REF_FIELD_NUMBER = 1;
private volatile java.lang.Object policyRef_;
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public java.lang.String getPolicyRef() {
java.lang.Object ref = policyRef_;
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();
policyRef_ = s;
return s;
}
}
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public com.google.protobuf.ByteString
getPolicyRefBytes() {
java.lang.Object ref = policyRef_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
policyRef_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
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 (!getPolicyRefBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, policyRef_);
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!getPolicyRefBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, policyRef_);
}
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.peer.Configuration.APIResource)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.peer.Configuration.APIResource other = (org.hyperledger.fabric.protos.peer.Configuration.APIResource) obj;
boolean result = true;
result = result && getPolicyRef()
.equals(other.getPolicyRef());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
hash = (37 * hash) + POLICY_REF_FIELD_NUMBER;
hash = (53 * hash) + getPolicyRef().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource 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.peer.Configuration.APIResource parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource 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.peer.Configuration.APIResource parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource 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.peer.Configuration.APIResource parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource 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.peer.Configuration.APIResource 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;
}
/**
*
* APIResource represents an API resource in the peer whose ACL
* is determined by the policy_ref field
*
*
* Protobuf type {@code protos.APIResource}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:protos.APIResource)
org.hyperledger.fabric.protos.peer.Configuration.APIResourceOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_APIResource_descriptor;
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_APIResource_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.APIResource.class, org.hyperledger.fabric.protos.peer.Configuration.APIResource.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.peer.Configuration.APIResource.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();
policyRef_ = "";
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_APIResource_descriptor;
}
public org.hyperledger.fabric.protos.peer.Configuration.APIResource getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.peer.Configuration.APIResource.getDefaultInstance();
}
public org.hyperledger.fabric.protos.peer.Configuration.APIResource build() {
org.hyperledger.fabric.protos.peer.Configuration.APIResource result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.peer.Configuration.APIResource buildPartial() {
org.hyperledger.fabric.protos.peer.Configuration.APIResource result = new org.hyperledger.fabric.protos.peer.Configuration.APIResource(this);
result.policyRef_ = policyRef_;
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.peer.Configuration.APIResource) {
return mergeFrom((org.hyperledger.fabric.protos.peer.Configuration.APIResource)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.peer.Configuration.APIResource other) {
if (other == org.hyperledger.fabric.protos.peer.Configuration.APIResource.getDefaultInstance()) return this;
if (!other.getPolicyRef().isEmpty()) {
policyRef_ = other.policyRef_;
onChanged();
}
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.peer.Configuration.APIResource parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.peer.Configuration.APIResource) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private java.lang.Object policyRef_ = "";
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public java.lang.String getPolicyRef() {
java.lang.Object ref = policyRef_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
policyRef_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public com.google.protobuf.ByteString
getPolicyRefBytes() {
java.lang.Object ref = policyRef_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
policyRef_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public Builder setPolicyRef(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
policyRef_ = value;
onChanged();
return this;
}
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public Builder clearPolicyRef() {
policyRef_ = getDefaultInstance().getPolicyRef();
onChanged();
return this;
}
/**
*
* The policy name to use for this API
*
*
* optional string policy_ref = 1;
*/
public Builder setPolicyRefBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
policyRef_ = value;
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:protos.APIResource)
}
// @@protoc_insertion_point(class_scope:protos.APIResource)
private static final org.hyperledger.fabric.protos.peer.Configuration.APIResource DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.Configuration.APIResource();
}
public static org.hyperledger.fabric.protos.peer.Configuration.APIResource getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public APIResource parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new APIResource(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.peer.Configuration.APIResource getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface ACLsOrBuilder extends
// @@protoc_insertion_point(interface_extends:protos.ACLs)
com.google.protobuf.MessageOrBuilder {
/**
* map<string, .protos.APIResource> acls = 1;
*/
int getAclsCount();
/**
* map<string, .protos.APIResource> acls = 1;
*/
boolean containsAcls(
java.lang.String key);
/**
* Use {@link #getAclsMap()} instead.
*/
@java.lang.Deprecated
java.util.Map
getAcls();
/**
* map<string, .protos.APIResource> acls = 1;
*/
java.util.Map
getAclsMap();
/**
* map<string, .protos.APIResource> acls = 1;
*/
org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrDefault(
java.lang.String key,
org.hyperledger.fabric.protos.peer.Configuration.APIResource defaultValue);
/**
* map<string, .protos.APIResource> acls = 1;
*/
org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrThrow(
java.lang.String key);
}
/**
*
* ACLs provides mappings for resources in a channel. APIResource encpasulates
* reference to a policy used to determine ACL for the resource
*
*
* Protobuf type {@code protos.ACLs}
*/
public static final class ACLs extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:protos.ACLs)
ACLsOrBuilder {
// Use ACLs.newBuilder() to construct.
private ACLs(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private ACLs() {
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
}
private ACLs(
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: {
if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
acls_ = com.google.protobuf.MapField.newMapField(
AclsDefaultEntryHolder.defaultEntry);
mutable_bitField0_ |= 0x00000001;
}
com.google.protobuf.MapEntry
acls = input.readMessage(
AclsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
acls_.getMutableMap().put(acls.getKey(), acls.getValue());
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.peer.Configuration.internal_static_protos_ACLs_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 1:
return internalGetAcls();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_ACLs_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.ACLs.class, org.hyperledger.fabric.protos.peer.Configuration.ACLs.Builder.class);
}
public static final int ACLS_FIELD_NUMBER = 1;
private static final class AclsDefaultEntryHolder {
static final com.google.protobuf.MapEntry<
java.lang.String, org.hyperledger.fabric.protos.peer.Configuration.APIResource> defaultEntry =
com.google.protobuf.MapEntry
.newDefaultInstance(
org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_ACLs_AclsEntry_descriptor,
com.google.protobuf.WireFormat.FieldType.STRING,
"",
com.google.protobuf.WireFormat.FieldType.MESSAGE,
org.hyperledger.fabric.protos.peer.Configuration.APIResource.getDefaultInstance());
}
private com.google.protobuf.MapField<
java.lang.String, org.hyperledger.fabric.protos.peer.Configuration.APIResource> acls_;
private com.google.protobuf.MapField
internalGetAcls() {
if (acls_ == null) {
return com.google.protobuf.MapField.emptyMapField(
AclsDefaultEntryHolder.defaultEntry);
}
return acls_;
}
public int getAclsCount() {
return internalGetAcls().getMap().size();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public boolean containsAcls(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetAcls().getMap().containsKey(key);
}
/**
* Use {@link #getAclsMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getAcls() {
return getAclsMap();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public java.util.Map getAclsMap() {
return internalGetAcls().getMap();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrDefault(
java.lang.String key,
org.hyperledger.fabric.protos.peer.Configuration.APIResource defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAcls().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAcls().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
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 {
for (java.util.Map.Entry entry
: internalGetAcls().getMap().entrySet()) {
com.google.protobuf.MapEntry
acls = AclsDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
output.writeMessage(1, acls);
}
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (java.util.Map.Entry entry
: internalGetAcls().getMap().entrySet()) {
com.google.protobuf.MapEntry
acls = AclsDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, acls);
}
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.peer.Configuration.ACLs)) {
return super.equals(obj);
}
org.hyperledger.fabric.protos.peer.Configuration.ACLs other = (org.hyperledger.fabric.protos.peer.Configuration.ACLs) obj;
boolean result = true;
result = result && internalGetAcls().equals(
other.internalGetAcls());
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptorForType().hashCode();
if (!internalGetAcls().getMap().isEmpty()) {
hash = (37 * hash) + ACLS_FIELD_NUMBER;
hash = (53 * hash) + internalGetAcls().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs 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.peer.Configuration.ACLs parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs 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.peer.Configuration.ACLs parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs 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.peer.Configuration.ACLs parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs 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.peer.Configuration.ACLs 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;
}
/**
*
* ACLs provides mappings for resources in a channel. APIResource encpasulates
* reference to a policy used to determine ACL for the resource
*
*
* Protobuf type {@code protos.ACLs}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:protos.ACLs)
org.hyperledger.fabric.protos.peer.Configuration.ACLsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_ACLs_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 1:
return internalGetAcls();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 1:
return internalGetMutableAcls();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_ACLs_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.hyperledger.fabric.protos.peer.Configuration.ACLs.class, org.hyperledger.fabric.protos.peer.Configuration.ACLs.Builder.class);
}
// Construct using org.hyperledger.fabric.protos.peer.Configuration.ACLs.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();
internalGetMutableAcls().clear();
return this;
}
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.hyperledger.fabric.protos.peer.Configuration.internal_static_protos_ACLs_descriptor;
}
public org.hyperledger.fabric.protos.peer.Configuration.ACLs getDefaultInstanceForType() {
return org.hyperledger.fabric.protos.peer.Configuration.ACLs.getDefaultInstance();
}
public org.hyperledger.fabric.protos.peer.Configuration.ACLs build() {
org.hyperledger.fabric.protos.peer.Configuration.ACLs result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public org.hyperledger.fabric.protos.peer.Configuration.ACLs buildPartial() {
org.hyperledger.fabric.protos.peer.Configuration.ACLs result = new org.hyperledger.fabric.protos.peer.Configuration.ACLs(this);
int from_bitField0_ = bitField0_;
result.acls_ = internalGetAcls();
result.acls_.makeImmutable();
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.peer.Configuration.ACLs) {
return mergeFrom((org.hyperledger.fabric.protos.peer.Configuration.ACLs)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.hyperledger.fabric.protos.peer.Configuration.ACLs other) {
if (other == org.hyperledger.fabric.protos.peer.Configuration.ACLs.getDefaultInstance()) return this;
internalGetMutableAcls().mergeFrom(
other.internalGetAcls());
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.peer.Configuration.ACLs parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.hyperledger.fabric.protos.peer.Configuration.ACLs) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private com.google.protobuf.MapField<
java.lang.String, org.hyperledger.fabric.protos.peer.Configuration.APIResource> acls_;
private com.google.protobuf.MapField
internalGetAcls() {
if (acls_ == null) {
return com.google.protobuf.MapField.emptyMapField(
AclsDefaultEntryHolder.defaultEntry);
}
return acls_;
}
private com.google.protobuf.MapField
internalGetMutableAcls() {
onChanged();;
if (acls_ == null) {
acls_ = com.google.protobuf.MapField.newMapField(
AclsDefaultEntryHolder.defaultEntry);
}
if (!acls_.isMutable()) {
acls_ = acls_.copy();
}
return acls_;
}
public int getAclsCount() {
return internalGetAcls().getMap().size();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public boolean containsAcls(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetAcls().getMap().containsKey(key);
}
/**
* Use {@link #getAclsMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getAcls() {
return getAclsMap();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public java.util.Map getAclsMap() {
return internalGetAcls().getMap();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrDefault(
java.lang.String key,
org.hyperledger.fabric.protos.peer.Configuration.APIResource defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAcls().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public org.hyperledger.fabric.protos.peer.Configuration.APIResource getAclsOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAcls().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearAcls() {
getMutableAcls().clear();
return this;
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public Builder removeAcls(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
getMutableAcls().remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableAcls() {
return internalGetMutableAcls().getMutableMap();
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public Builder putAcls(
java.lang.String key,
org.hyperledger.fabric.protos.peer.Configuration.APIResource value) {
if (key == null) { throw new java.lang.NullPointerException(); }
if (value == null) { throw new java.lang.NullPointerException(); }
getMutableAcls().put(key, value);
return this;
}
/**
* map<string, .protos.APIResource> acls = 1;
*/
public Builder putAllAcls(
java.util.Map values) {
getMutableAcls().putAll(values);
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:protos.ACLs)
}
// @@protoc_insertion_point(class_scope:protos.ACLs)
private static final org.hyperledger.fabric.protos.peer.Configuration.ACLs DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.Configuration.ACLs();
}
public static org.hyperledger.fabric.protos.peer.Configuration.ACLs getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
public ACLs parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new ACLs(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.peer.Configuration.ACLs getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_protos_AnchorPeers_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_protos_AnchorPeers_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_protos_AnchorPeer_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_protos_AnchorPeer_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_protos_APIResource_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_protos_APIResource_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_protos_ACLs_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_protos_ACLs_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_protos_ACLs_AclsEntry_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_protos_ACLs_AclsEntry_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\030peer/configuration.proto\022\006protos\"7\n\013An" +
"chorPeers\022(\n\014anchor_peers\030\001 \003(\0132\022.protos" +
".AnchorPeer\"(\n\nAnchorPeer\022\014\n\004host\030\001 \001(\t\022" +
"\014\n\004port\030\002 \001(\005\"!\n\013APIResource\022\022\n\npolicy_r" +
"ef\030\001 \001(\t\"n\n\004ACLs\022$\n\004acls\030\001 \003(\0132\026.protos." +
"ACLs.AclsEntry\032@\n\tAclsEntry\022\013\n\003key\030\001 \001(\t" +
"\022\"\n\005value\030\002 \001(\0132\023.protos.APIResource:\0028\001" +
"BO\n\"org.hyperledger.fabric.protos.peerZ)" +
"github.com/hyperledger/fabric/protos/pee" +
"rb\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_protos_AnchorPeers_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_protos_AnchorPeers_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_protos_AnchorPeers_descriptor,
new java.lang.String[] { "AnchorPeers", });
internal_static_protos_AnchorPeer_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_protos_AnchorPeer_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_protos_AnchorPeer_descriptor,
new java.lang.String[] { "Host", "Port", });
internal_static_protos_APIResource_descriptor =
getDescriptor().getMessageTypes().get(2);
internal_static_protos_APIResource_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_protos_APIResource_descriptor,
new java.lang.String[] { "PolicyRef", });
internal_static_protos_ACLs_descriptor =
getDescriptor().getMessageTypes().get(3);
internal_static_protos_ACLs_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_protos_ACLs_descriptor,
new java.lang.String[] { "Acls", });
internal_static_protos_ACLs_AclsEntry_descriptor =
internal_static_protos_ACLs_descriptor.getNestedTypes().get(0);
internal_static_protos_ACLs_AclsEntry_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_protos_ACLs_AclsEntry_descriptor,
new java.lang.String[] { "Key", "Value", });
}
// @@protoc_insertion_point(outer_class_scope)
}