All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult Maven / Gradle / Ivy

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: peer/lifecycle/lifecycle.proto
// Protobuf Java Version: 4.28.2

package org.hyperledger.fabric.protos.peer.lifecycle;

/**
 * 
 * QueryInstalledChaincodeResult is the message returned by
 * '_lifecycle.QueryInstalledChaincode'
 * 
* * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult} */ public final class QueryInstalledChaincodeResult extends com.google.protobuf.GeneratedMessage implements // @@protoc_insertion_point(message_implements:lifecycle.QueryInstalledChaincodeResult) QueryInstalledChaincodeResultOrBuilder { private static final long serialVersionUID = 0L; static { com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, /* major= */ 4, /* minor= */ 28, /* patch= */ 2, /* suffix= */ "", QueryInstalledChaincodeResult.class.getName()); } // Use QueryInstalledChaincodeResult.newBuilder() to construct. private QueryInstalledChaincodeResult(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } private QueryInstalledChaincodeResult() { packageId_ = ""; label_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_descriptor; } @SuppressWarnings({"rawtypes"}) @java.lang.Override protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 3: return internalGetReferences(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Builder.class); } public interface ReferencesOrBuilder extends // @@protoc_insertion_point(interface_extends:lifecycle.QueryInstalledChaincodeResult.References) com.google.protobuf.MessageOrBuilder { /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ java.util.List getChaincodesList(); /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getChaincodes(int index); /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ int getChaincodesCount(); /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ java.util.List getChaincodesOrBuilderList(); /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder getChaincodesOrBuilder( int index); } /** * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult.References} */ public static final class References extends com.google.protobuf.GeneratedMessage implements // @@protoc_insertion_point(message_implements:lifecycle.QueryInstalledChaincodeResult.References) ReferencesOrBuilder { private static final long serialVersionUID = 0L; static { com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, /* major= */ 4, /* minor= */ 28, /* patch= */ 2, /* suffix= */ "", References.class.getName()); } // Use References.newBuilder() to construct. private References(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } private References() { chaincodes_ = java.util.Collections.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_References_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_References_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder.class); } public static final int CHAINCODES_FIELD_NUMBER = 1; @SuppressWarnings("serial") private java.util.List chaincodes_; /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ @java.lang.Override public java.util.List getChaincodesList() { return chaincodes_; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ @java.lang.Override public java.util.List getChaincodesOrBuilderList() { return chaincodes_; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ @java.lang.Override public int getChaincodesCount() { return chaincodes_.size(); } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getChaincodes(int index) { return chaincodes_.get(index); } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder getChaincodesOrBuilder( int index) { return chaincodes_.get(index); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < chaincodes_.size(); i++) { output.writeMessage(1, chaincodes_.get(i)); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; for (int i = 0; i < chaincodes_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, chaincodes_.get(i)); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References)) { return super.equals(obj); } org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References other = (org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) obj; if (!getChaincodesList() .equals(other.getChaincodesList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (getChaincodesCount() > 0) { hash = (37 * hash) + CHAINCODES_FIELD_NUMBER; hash = (53 * hash) + getChaincodesList().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References 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.lifecycle.QueryInstalledChaincodeResult.References parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References 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.lifecycle.QueryInstalledChaincodeResult.References parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult.References} */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder implements // @@protoc_insertion_point(builder_implements:lifecycle.QueryInstalledChaincodeResult.References) org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ReferencesOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_References_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_References_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder.class); } // Construct using org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; if (chaincodesBuilder_ == null) { chaincodes_ = java.util.Collections.emptyList(); } else { chaincodes_ = null; chaincodesBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000001); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_References_descriptor; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getDefaultInstanceForType() { return org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.getDefaultInstance(); } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References build() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References buildPartial() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References result = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References result) { if (chaincodesBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { chaincodes_ = java.util.Collections.unmodifiableList(chaincodes_); bitField0_ = (bitField0_ & ~0x00000001); } result.chaincodes_ = chaincodes_; } else { result.chaincodes_ = chaincodesBuilder_.build(); } } private void buildPartial0(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References result) { int from_bitField0_ = bitField0_; } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) { return mergeFrom((org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References other) { if (other == org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.getDefaultInstance()) return this; if (chaincodesBuilder_ == null) { if (!other.chaincodes_.isEmpty()) { if (chaincodes_.isEmpty()) { chaincodes_ = other.chaincodes_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensureChaincodesIsMutable(); chaincodes_.addAll(other.chaincodes_); } onChanged(); } } else { if (!other.chaincodes_.isEmpty()) { if (chaincodesBuilder_.isEmpty()) { chaincodesBuilder_.dispose(); chaincodesBuilder_ = null; chaincodes_ = other.chaincodes_; bitField0_ = (bitField0_ & ~0x00000001); chaincodesBuilder_ = com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? getChaincodesFieldBuilder() : null; } else { chaincodesBuilder_.addAllMessages(other.chaincodes_); } } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode m = input.readMessage( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.parser(), extensionRegistry); if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); chaincodes_.add(m); } else { chaincodesBuilder_.addMessage(m); } break; } // case 10 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.util.List chaincodes_ = java.util.Collections.emptyList(); private void ensureChaincodesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { chaincodes_ = new java.util.ArrayList(chaincodes_); bitField0_ |= 0x00000001; } } private com.google.protobuf.RepeatedFieldBuilder< org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder> chaincodesBuilder_; /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public java.util.List getChaincodesList() { if (chaincodesBuilder_ == null) { return java.util.Collections.unmodifiableList(chaincodes_); } else { return chaincodesBuilder_.getMessageList(); } } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public int getChaincodesCount() { if (chaincodesBuilder_ == null) { return chaincodes_.size(); } else { return chaincodesBuilder_.getCount(); } } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getChaincodes(int index) { if (chaincodesBuilder_ == null) { return chaincodes_.get(index); } else { return chaincodesBuilder_.getMessage(index); } } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder setChaincodes( int index, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode value) { if (chaincodesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureChaincodesIsMutable(); chaincodes_.set(index, value); onChanged(); } else { chaincodesBuilder_.setMessage(index, value); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder setChaincodes( int index, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder builderForValue) { if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); chaincodes_.set(index, builderForValue.build()); onChanged(); } else { chaincodesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder addChaincodes(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode value) { if (chaincodesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureChaincodesIsMutable(); chaincodes_.add(value); onChanged(); } else { chaincodesBuilder_.addMessage(value); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder addChaincodes( int index, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode value) { if (chaincodesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureChaincodesIsMutable(); chaincodes_.add(index, value); onChanged(); } else { chaincodesBuilder_.addMessage(index, value); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder addChaincodes( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder builderForValue) { if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); chaincodes_.add(builderForValue.build()); onChanged(); } else { chaincodesBuilder_.addMessage(builderForValue.build()); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder addChaincodes( int index, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder builderForValue) { if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); chaincodes_.add(index, builderForValue.build()); onChanged(); } else { chaincodesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder addAllChaincodes( java.lang.Iterable values) { if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, chaincodes_); onChanged(); } else { chaincodesBuilder_.addAllMessages(values); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder clearChaincodes() { if (chaincodesBuilder_ == null) { chaincodes_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); } else { chaincodesBuilder_.clear(); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public Builder removeChaincodes(int index) { if (chaincodesBuilder_ == null) { ensureChaincodesIsMutable(); chaincodes_.remove(index); onChanged(); } else { chaincodesBuilder_.remove(index); } return this; } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder getChaincodesBuilder( int index) { return getChaincodesFieldBuilder().getBuilder(index); } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder getChaincodesOrBuilder( int index) { if (chaincodesBuilder_ == null) { return chaincodes_.get(index); } else { return chaincodesBuilder_.getMessageOrBuilder(index); } } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public java.util.List getChaincodesOrBuilderList() { if (chaincodesBuilder_ != null) { return chaincodesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(chaincodes_); } } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder addChaincodesBuilder() { return getChaincodesFieldBuilder().addBuilder( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.getDefaultInstance()); } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder addChaincodesBuilder( int index) { return getChaincodesFieldBuilder().addBuilder( index, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.getDefaultInstance()); } /** * repeated .lifecycle.QueryInstalledChaincodeResult.Chaincode chaincodes = 1 [json_name = "chaincodes"]; */ public java.util.List getChaincodesBuilderList() { return getChaincodesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilder< org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder> getChaincodesFieldBuilder() { if (chaincodesBuilder_ == null) { chaincodesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder>( chaincodes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); chaincodes_ = null; } return chaincodesBuilder_; } // @@protoc_insertion_point(builder_scope:lifecycle.QueryInstalledChaincodeResult.References) } // @@protoc_insertion_point(class_scope:lifecycle.QueryInstalledChaincodeResult.References) private static final org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References(); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public References parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface ChaincodeOrBuilder extends // @@protoc_insertion_point(interface_extends:lifecycle.QueryInstalledChaincodeResult.Chaincode) com.google.protobuf.MessageOrBuilder { /** * string name = 1 [json_name = "name"]; * @return The name. */ java.lang.String getName(); /** * string name = 1 [json_name = "name"]; * @return The bytes for name. */ com.google.protobuf.ByteString getNameBytes(); /** * string version = 2 [json_name = "version"]; * @return The version. */ java.lang.String getVersion(); /** * string version = 2 [json_name = "version"]; * @return The bytes for version. */ com.google.protobuf.ByteString getVersionBytes(); } /** * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult.Chaincode} */ public static final class Chaincode extends com.google.protobuf.GeneratedMessage implements // @@protoc_insertion_point(message_implements:lifecycle.QueryInstalledChaincodeResult.Chaincode) ChaincodeOrBuilder { private static final long serialVersionUID = 0L; static { com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, /* major= */ 4, /* minor= */ 28, /* patch= */ 2, /* suffix= */ "", Chaincode.class.getName()); } // Use Chaincode.newBuilder() to construct. private Chaincode(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } private Chaincode() { name_ = ""; version_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_Chaincode_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_Chaincode_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object name_ = ""; /** * string name = 1 [json_name = "name"]; * @return The name. */ @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; 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(); name_ = s; return s; } } /** * string name = 1 [json_name = "name"]; * @return The bytes for name. */ @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int VERSION_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object version_ = ""; /** * string version = 2 [json_name = "version"]; * @return The version. */ @java.lang.Override public java.lang.String getVersion() { java.lang.Object ref = version_; 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(); version_ = s; return s; } } /** * string version = 2 [json_name = "version"]; * @return The bytes for version. */ @java.lang.Override public com.google.protobuf.ByteString getVersionBytes() { java.lang.Object ref = version_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); version_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { com.google.protobuf.GeneratedMessage.writeString(output, 2, version_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(2, version_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode)) { return super.equals(obj); } org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode other = (org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode) obj; if (!getName() .equals(other.getName())) return false; if (!getVersion() .equals(other.getVersion())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + VERSION_FIELD_NUMBER; hash = (53 * hash) + getVersion().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode 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.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode 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.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult.Chaincode} */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder implements // @@protoc_insertion_point(builder_implements:lifecycle.QueryInstalledChaincodeResult.Chaincode) org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ChaincodeOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_Chaincode_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_Chaincode_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.Builder.class); } // Construct using org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; name_ = ""; version_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_Chaincode_descriptor; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getDefaultInstanceForType() { return org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.getDefaultInstance(); } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode build() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode buildPartial() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode result = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.name_ = name_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.version_ = version_; } } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode) { return mergeFrom((org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode other) { if (other == org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode.getDefaultInstance()) return this; if (!other.getName().isEmpty()) { name_ = other.name_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getVersion().isEmpty()) { version_ = other.version_; bitField0_ |= 0x00000002; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { name_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { version_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object name_ = ""; /** * string name = 1 [json_name = "name"]; * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } else { return (java.lang.String) ref; } } /** * string name = 1 [json_name = "name"]; * @return The bytes for name. */ public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * string name = 1 [json_name = "name"]; * @param value The name to set. * @return This builder for chaining. */ public Builder setName( java.lang.String value) { if (value == null) { throw new NullPointerException(); } name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * string name = 1 [json_name = "name"]; * @return This builder for chaining. */ public Builder clearName() { name_ = getDefaultInstance().getName(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * string name = 1 [json_name = "name"]; * @param value The bytes for name to set. * @return This builder for chaining. */ public Builder setNameBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private java.lang.Object version_ = ""; /** * string version = 2 [json_name = "version"]; * @return The version. */ public java.lang.String getVersion() { java.lang.Object ref = version_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); version_ = s; return s; } else { return (java.lang.String) ref; } } /** * string version = 2 [json_name = "version"]; * @return The bytes for version. */ public com.google.protobuf.ByteString getVersionBytes() { java.lang.Object ref = version_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); version_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * string version = 2 [json_name = "version"]; * @param value The version to set. * @return This builder for chaining. */ public Builder setVersion( java.lang.String value) { if (value == null) { throw new NullPointerException(); } version_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * string version = 2 [json_name = "version"]; * @return This builder for chaining. */ public Builder clearVersion() { version_ = getDefaultInstance().getVersion(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * string version = 2 [json_name = "version"]; * @param value The bytes for version to set. * @return This builder for chaining. */ public Builder setVersionBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); version_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } // @@protoc_insertion_point(builder_scope:lifecycle.QueryInstalledChaincodeResult.Chaincode) } // @@protoc_insertion_point(class_scope:lifecycle.QueryInstalledChaincodeResult.Chaincode) private static final org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode(); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Chaincode parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Chaincode getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public static final int PACKAGE_ID_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object packageId_ = ""; /** * string package_id = 1 [json_name = "packageId"]; * @return The packageId. */ @java.lang.Override public java.lang.String getPackageId() { java.lang.Object ref = packageId_; 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(); packageId_ = s; return s; } } /** * string package_id = 1 [json_name = "packageId"]; * @return The bytes for packageId. */ @java.lang.Override public com.google.protobuf.ByteString getPackageIdBytes() { java.lang.Object ref = packageId_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); packageId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LABEL_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object label_ = ""; /** * string label = 2 [json_name = "label"]; * @return The label. */ @java.lang.Override public java.lang.String getLabel() { java.lang.Object ref = label_; 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(); label_ = s; return s; } } /** * string label = 2 [json_name = "label"]; * @return The bytes for label. */ @java.lang.Override public com.google.protobuf.ByteString getLabelBytes() { java.lang.Object ref = label_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); label_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int REFERENCES_FIELD_NUMBER = 3; private static final class ReferencesDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_ReferencesEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.MESSAGE, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.getDefaultInstance()); } @SuppressWarnings("serial") private com.google.protobuf.MapField< java.lang.String, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References> references_; private com.google.protobuf.MapField internalGetReferences() { if (references_ == null) { return com.google.protobuf.MapField.emptyMapField( ReferencesDefaultEntryHolder.defaultEntry); } return references_; } public int getReferencesCount() { return internalGetReferences().getMap().size(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public boolean containsReferences( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetReferences().getMap().containsKey(key); } /** * Use {@link #getReferencesMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getReferences() { return getReferencesMap(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public java.util.Map getReferencesMap() { return internalGetReferences().getMap(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public /* nullable */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getReferencesOrDefault( java.lang.String key, /* nullable */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetReferences().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getReferencesOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetReferences().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(packageId_)) { com.google.protobuf.GeneratedMessage.writeString(output, 1, packageId_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(label_)) { com.google.protobuf.GeneratedMessage.writeString(output, 2, label_); } com.google.protobuf.GeneratedMessage .serializeStringMapTo( output, internalGetReferences(), ReferencesDefaultEntryHolder.defaultEntry, 3); getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessage.isStringEmpty(packageId_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(1, packageId_); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(label_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(2, label_); } for (java.util.Map.Entry entry : internalGetReferences().getMap().entrySet()) { com.google.protobuf.MapEntry references__ = ReferencesDefaultEntryHolder.defaultEntry.newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream .computeMessageSize(3, references__); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult)) { return super.equals(obj); } org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult other = (org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult) obj; if (!getPackageId() .equals(other.getPackageId())) return false; if (!getLabel() .equals(other.getLabel())) return false; if (!internalGetReferences().equals( other.internalGetReferences())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + PACKAGE_ID_FIELD_NUMBER; hash = (53 * hash) + getPackageId().hashCode(); hash = (37 * hash) + LABEL_FIELD_NUMBER; hash = (53 * hash) + getLabel().hashCode(); if (!internalGetReferences().getMap().isEmpty()) { hash = (37 * hash) + REFERENCES_FIELD_NUMBER; hash = (53 * hash) + internalGetReferences().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult 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.lifecycle.QueryInstalledChaincodeResult parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult 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.lifecycle.QueryInstalledChaincodeResult parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessage .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** *
   * QueryInstalledChaincodeResult is the message returned by
   * '_lifecycle.QueryInstalledChaincode'
   * 
* * Protobuf type {@code lifecycle.QueryInstalledChaincodeResult} */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder implements // @@protoc_insertion_point(builder_implements:lifecycle.QueryInstalledChaincodeResult) org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResultOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 3: return internalGetReferences(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( int number) { switch (number) { case 3: return internalGetMutableReferences(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_fieldAccessorTable .ensureFieldAccessorsInitialized( org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.class, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.Builder.class); } // Construct using org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; packageId_ = ""; label_ = ""; internalGetMutableReferences().clear(); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.hyperledger.fabric.protos.peer.lifecycle.LifecycleProto.internal_static_lifecycle_QueryInstalledChaincodeResult_descriptor; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult getDefaultInstanceForType() { return org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.getDefaultInstance(); } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult build() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult buildPartial() { org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult result = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.packageId_ = packageId_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.label_ = label_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.references_ = internalGetReferences().build(ReferencesDefaultEntryHolder.defaultEntry); } } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult) { return mergeFrom((org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult other) { if (other == org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.getDefaultInstance()) return this; if (!other.getPackageId().isEmpty()) { packageId_ = other.packageId_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getLabel().isEmpty()) { label_ = other.label_; bitField0_ |= 0x00000002; onChanged(); } internalGetMutableReferences().mergeFrom( other.internalGetReferences()); bitField0_ |= 0x00000004; this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { packageId_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { label_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { com.google.protobuf.MapEntry references__ = input.readMessage( ReferencesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); internalGetMutableReferences().ensureBuilderMap().put( references__.getKey(), references__.getValue()); bitField0_ |= 0x00000004; break; } // case 26 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object packageId_ = ""; /** * string package_id = 1 [json_name = "packageId"]; * @return The packageId. */ public java.lang.String getPackageId() { java.lang.Object ref = packageId_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); packageId_ = s; return s; } else { return (java.lang.String) ref; } } /** * string package_id = 1 [json_name = "packageId"]; * @return The bytes for packageId. */ public com.google.protobuf.ByteString getPackageIdBytes() { java.lang.Object ref = packageId_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); packageId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * string package_id = 1 [json_name = "packageId"]; * @param value The packageId to set. * @return This builder for chaining. */ public Builder setPackageId( java.lang.String value) { if (value == null) { throw new NullPointerException(); } packageId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * string package_id = 1 [json_name = "packageId"]; * @return This builder for chaining. */ public Builder clearPackageId() { packageId_ = getDefaultInstance().getPackageId(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * string package_id = 1 [json_name = "packageId"]; * @param value The bytes for packageId to set. * @return This builder for chaining. */ public Builder setPackageIdBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); packageId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private java.lang.Object label_ = ""; /** * string label = 2 [json_name = "label"]; * @return The label. */ public java.lang.String getLabel() { java.lang.Object ref = label_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); label_ = s; return s; } else { return (java.lang.String) ref; } } /** * string label = 2 [json_name = "label"]; * @return The bytes for label. */ public com.google.protobuf.ByteString getLabelBytes() { java.lang.Object ref = label_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); label_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * string label = 2 [json_name = "label"]; * @param value The label to set. * @return This builder for chaining. */ public Builder setLabel( java.lang.String value) { if (value == null) { throw new NullPointerException(); } label_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * string label = 2 [json_name = "label"]; * @return This builder for chaining. */ public Builder clearLabel() { label_ = getDefaultInstance().getLabel(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * string label = 2 [json_name = "label"]; * @param value The bytes for label to set. * @return This builder for chaining. */ public Builder setLabelBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); label_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } private static final class ReferencesConverter implements com.google.protobuf.MapFieldBuilder.Converter { @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References build(org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ReferencesOrBuilder val) { if (val instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) { return (org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) val; } return ((org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder) val).build(); } @java.lang.Override public com.google.protobuf.MapEntry defaultEntry() { return ReferencesDefaultEntryHolder.defaultEntry; } }; private static final ReferencesConverter referencesConverter = new ReferencesConverter(); private com.google.protobuf.MapFieldBuilder< java.lang.String, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ReferencesOrBuilder, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder> references_; private com.google.protobuf.MapFieldBuilder internalGetReferences() { if (references_ == null) { return new com.google.protobuf.MapFieldBuilder<>(referencesConverter); } return references_; } private com.google.protobuf.MapFieldBuilder internalGetMutableReferences() { if (references_ == null) { references_ = new com.google.protobuf.MapFieldBuilder<>(referencesConverter); } bitField0_ |= 0x00000004; onChanged(); return references_; } public int getReferencesCount() { return internalGetReferences().ensureBuilderMap().size(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public boolean containsReferences( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetReferences().ensureBuilderMap().containsKey(key); } /** * Use {@link #getReferencesMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getReferences() { return getReferencesMap(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public java.util.Map getReferencesMap() { return internalGetReferences().getImmutableMap(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public /* nullable */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getReferencesOrDefault( java.lang.String key, /* nullable */ org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMutableReferences().ensureBuilderMap(); return map.containsKey(key) ? referencesConverter.build(map.get(key)) : defaultValue; } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References getReferencesOrThrow( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMutableReferences().ensureBuilderMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return referencesConverter.build(map.get(key)); } public Builder clearReferences() { bitField0_ = (bitField0_ & ~0x00000004); internalGetMutableReferences().clear(); return this; } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ public Builder removeReferences( java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableReferences().ensureBuilderMap() .remove(key); return this; } /** * Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableReferences() { bitField0_ |= 0x00000004; return internalGetMutableReferences().ensureMessageMap(); } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ public Builder putReferences( java.lang.String key, org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References value) { if (key == null) { throw new NullPointerException("map key"); } if (value == null) { throw new NullPointerException("map value"); } internalGetMutableReferences().ensureBuilderMap() .put(key, value); bitField0_ |= 0x00000004; return this; } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ public Builder putAllReferences( java.util.Map values) { for (java.util.Map.Entry e : values.entrySet()) { if (e.getKey() == null || e.getValue() == null) { throw new NullPointerException(); } } internalGetMutableReferences().ensureBuilderMap() .putAll(values); bitField0_ |= 0x00000004; return this; } /** * map<string, .lifecycle.QueryInstalledChaincodeResult.References> references = 3 [json_name = "references"]; */ public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder putReferencesBuilderIfAbsent( java.lang.String key) { java.util.Map builderMap = internalGetMutableReferences().ensureBuilderMap(); org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.ReferencesOrBuilder entry = builderMap.get(key); if (entry == null) { entry = org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.newBuilder(); builderMap.put(key, entry); } if (entry instanceof org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) { entry = ((org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References) entry).toBuilder(); builderMap.put(key, entry); } return (org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult.References.Builder) entry; } // @@protoc_insertion_point(builder_scope:lifecycle.QueryInstalledChaincodeResult) } // @@protoc_insertion_point(class_scope:lifecycle.QueryInstalledChaincodeResult) private static final org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult(); } public static org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public QueryInstalledChaincodeResult parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public org.hyperledger.fabric.protos.peer.lifecycle.QueryInstalledChaincodeResult getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy