tx.getConfidence().getConfidenceType().name()); dead.remove(tx.getHash());
tx.getConfidence().getConfidenceType().name()); dead.remove(tx.getHash());
default: throw new RuntimeException("Unsupported confidence type: " + tx.getConfidenceType().name());
tx.getConfidence().getConfidenceType().name()); dead.remove(tx.getHash());
tx.getConfidence().getConfidenceType().name()); dead.remove(tx.getHash());
default: throw new RuntimeException("Unsupported confidence type: " + tx.getConfidenceType().name());
private void checkTxConfirmation(HistoryTx historyTx, BitTransaction tx) { checkState(lock.isHeldByCurrentThread(), "Lock is held by another thread"); int height = historyTx.getHeight(); TransactionConfidence.ConfidenceType confidence = tx.getConfidenceType(); if (height > 0) { switch (confidence) { case BUILDING: // If the height is the same, don't do anything if (tx.getAppearedAtChainHeight() == historyTx.getHeight()) { break; } case PENDING: setAppearedAtChainHeight(tx, height, true); maybeUpdateBlockDepth(tx, true); maybeMovePool(tx); break; case DEAD: case UNKNOWN: default: throw new RuntimeException("Unsupported confidence type: " + tx.getConfidenceType().name()); } } }
private void checkTxConfirmation(HistoryTx historyTx, BitTransaction tx) { checkState(lock.isHeldByCurrentThread(), "Lock is held by another thread"); int height = historyTx.getHeight(); TransactionConfidence.ConfidenceType confidence = tx.getConfidenceType(); if (height > 0) { switch (confidence) { case BUILDING: // If the height is the same, don't do anything if (tx.getAppearedAtChainHeight() == historyTx.getHeight()) { break; } case PENDING: setAppearedAtChainHeight(tx, height, true); maybeUpdateBlockDepth(tx, true); maybeMovePool(tx); break; case DEAD: case UNKNOWN: default: throw new RuntimeException("Unsupported confidence type: " + tx.getConfidenceType().name()); } } }