public byte[] getProposalResponseMessageBytes() { if (isFiltered()) { return null; } return transactionAction.getPayload().getAction().getProposalResponsePayload().getExtension().getResponseMessageBytes(); }
int getType() { if (type == null) { type = getPayload().getHeader().getChannelHeader().getType(); } return type; }
public int getProposalResponseStatus() { if (isFiltered()) { return -1; } return transactionAction.getPayload().getAction().getProposalResponsePayload(). getExtension().getResponseStatus(); }
public int getChaincodeInputArgsCount() { if (isFiltered()) { return 0; } if (getChaincodeInputArgsCount < 0) { getChaincodeInputArgsCount = transactionAction.getPayload().getChaincodeProposalPayload(). getChaincodeInvocationSpec().getChaincodeInput().getChaincodeInput().getArgsCount(); } return getChaincodeInputArgsCount; }
public String getResponseMessage() { return isFiltered() ? null : transactionAction.getPayload().getAction().getProposalResponsePayload().getExtension().getResponseMessage(); }
public byte[] getProposalResponsePayload() { if (isFiltered()) { return null; } byte[] ret = null; ByteString retByteString = transactionAction.getPayload().getAction().getProposalResponsePayload(). getExtension().getResponsePayload(); if (null != retByteString) { ret = retByteString.toByteArray(); } return ret; }
TransactionEvent getTransactionEvent(int index) throws InvalidProtocolBufferException { TransactionEvent ret = null; EnvelopeInfo envelopeInfo = getEnvelopeInfo(index); if (envelopeInfo.getType() == EnvelopeType.TRANSACTION_ENVELOPE) { if (isFiltered()) { ret = new TransactionEvent(getEnvelopeInfo(index).filteredTx); } else { ret = new TransactionEvent((TransactionEnvelopeInfo) getEnvelopeInfo(index)); } } return ret; }
public int getEndorsementsCount() { if (isFiltered()) { return 0; } if (getEndorsementsCount < 0) { getEndorsementsCount = transactionAction.getPayload().getAction().getEndorsementsCount(); } return getEndorsementsCount; }
/** * This is the creator or submitter of the transaction. * Returns null for a filtered block. * * @return {@link IdentitiesInfo} */ public IdentitiesInfo getCreator() { return isFiltered() ? null : new IdentitiesInfo(headerDeserializer.getCreator()); }
/** * @return epoch and -1 if filtered block. * @deprecated */ public long getEpoch() { return BlockInfo.this.isFiltered() ? -1 : headerDeserializer.getChannelHeader().getEpoch(); }
/** * Get channel id * * @return The channel id also referred to as channel name. */ public String getChannelId() { return BlockInfo.this.isFiltered() ? filteredBlock.getChannelId() : headerDeserializer.getChannelHeader().getChannelId(); }
/** * newPeer create a new peer * * @param name * @param grpcURL to the peer's location * @return Peer * @throws InvalidArgumentException */ public Peer newPeer(String name, String grpcURL) throws InvalidArgumentException { clientCheck(); return Peer.createNewInstance(name, grpcURL, null); }
/** * @return the {@link Block} transaction metadata value return null if filtered block. */ public byte[] getTransActionsMetaData() { return isFiltered() ? null : block.getTransActionsMetaData(); }
EnvelopeInfo(EnvelopeDeserializer envelopeDeserializer) { this.envelopeDeserializer = envelopeDeserializer; headerDeserializer = envelopeDeserializer.getPayload().getHeader(); filteredTx = null; }
/** * The nonce of the transaction. * * @return return null for filtered block. */ public byte[] getNonce() { return isFiltered() ? null : headerDeserializer.getNonce(); }
/** * Returns the admin user associated with the client organization * * @return The admin user details * @throws NetworkConfigurationException */ public UserInfo getPeerAdmin() throws NetworkConfigurationException { // Get the details from the client organization return getPeerAdmin(clientOrganization.getName()); }
/** * @return the raw {@link Block} */ public Block getBlock() { return isFiltered() ? null : block.getBlock(); }
public byte[] getResponseMessageBytes() { return isFiltered() ? null : transactionAction.getPayload().getAction().getProposalResponsePayload().getExtension().getResponseMessageBytes(); }
public byte[] getChaincodeInputArgs(int index) { if (isFiltered()) { return null; } ChaincodeInput input = transactionAction.getPayload().getChaincodeProposalPayload(). getChaincodeInvocationSpec().getChaincodeInput().getChaincodeInput(); return input.getArgs(index).toByteArray(); }
public int getResponseStatus() { return isFiltered() ? -1 : transactionAction.getPayload().getAction().getProposalResponsePayload().getExtension().getResponseStatus(); }