@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange)) { return super.equals(obj); } org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange other = (org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange) obj; boolean result = true; result = result && getStartKey() .equals(other.getStartKey()); result = result && getEndKey() .equals(other.getEndKey()); result = result && getCollection() .equals(other.getCollection()); return result; }
public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!getStartKeyBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, startKey_); } if (!getEndKeyBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, endKey_); } if (!getCollectionBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, collection_); } memoizedSize = size; return size; }
public Builder mergeFrom(org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange other) { if (other == org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange.getDefaultInstance()) return this; if (!other.getStartKey().isEmpty()) { startKey_ = other.startKey_; onChanged(); } if (!other.getEndKey().isEmpty()) { endKey_ = other.endKey_; onChanged(); } if (!other.getCollection().isEmpty()) { collection_ = other.collection_; onChanged(); } onChanged(); return this; }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + STARTKEY_FIELD_NUMBER; hash = (53 * hash) + getStartKey().hashCode(); hash = (37 * hash) + ENDKEY_FIELD_NUMBER; hash = (53 * hash) + getEndKey().hashCode(); hash = (37 * hash) + COLLECTION_FIELD_NUMBER; hash = (53 * hash) + getCollection().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() {
public org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange getDefaultInstanceForType() { return org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange.getDefaultInstance(); }
/** * <code>optional string endKey = 2;</code> */ public Builder clearEndKey() { endKey_ = getDefaultInstance().getEndKey(); onChanged(); return this; } /**
/** * <code>optional string startKey = 1;</code> */ public Builder clearStartKey() { startKey_ = getDefaultInstance().getStartKey(); onChanged(); return this; } /**
QueryResponse getStateByRange(String channelId, String txId, String collection, String startKey, String endKey) { return invokeQueryResponseMessage(channelId, txId, GET_STATE_BY_RANGE, GetStateByRange.newBuilder() .setCollection(collection) .setStartKey(startKey) .setEndKey(endKey) .build().toByteString()); }
public org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange buildPartial() { org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange result = new org.hyperledger.fabric.protos.peer.ChaincodeShim.GetStateByRange(this); result.startKey_ = startKey_; result.endKey_ = endKey_; result.collection_ = collection_; onBuilt(); return result; }
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getStartKeyBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, startKey_); } if (!getEndKeyBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, endKey_); } if (!getCollectionBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, collection_); } }
/** * <code>optional string collection = 3;</code> */ public Builder clearCollection() { collection_ = getDefaultInstance().getCollection(); onChanged(); return this; } /**