mirror of
https://github.com/corda/corda.git
synced 2025-06-13 04:38:19 +00:00
CORDA-1038 Update verifySignaturesExcept in api-transactions.rst (#2546)
This commit is contained in:
committed by
GitHub
parent
458db7cb24
commit
fe7c129ae7
@ -540,12 +540,21 @@ public class FlowCookbookJava {
|
||||
// DOCEND 35
|
||||
|
||||
// If the transaction is only partially signed, we have to pass in
|
||||
// a list of the public keys corresponding to the missing
|
||||
// a vararg of the public keys corresponding to the missing
|
||||
// signatures, explicitly telling the system not to check them.
|
||||
// DOCSTART 36
|
||||
onceSignedTx.verifySignaturesExcept(counterpartyPubKey);
|
||||
// DOCEND 36
|
||||
|
||||
// There is also an overload of ``verifySignaturesExcept`` which accepts
|
||||
// a ``Collection`` of the public keys corresponding to the missing
|
||||
// signatures. In the example below, we could also use
|
||||
// ``Arrays.asList(counterpartyPubKey)`` instead of
|
||||
// ``Collections.singletonList(counterpartyPubKey)``.
|
||||
// DOCSTART 54
|
||||
onceSignedTx.verifySignaturesExcept(Collections.singletonList(counterpartyPubKey));
|
||||
// DOCEND 54
|
||||
|
||||
// We can also choose to only check the signatures that are
|
||||
// present. BE VERY CAREFUL - this function provides no guarantees
|
||||
// that the signatures are correct, or that none are missing.
|
||||
|
@ -522,12 +522,19 @@ class InitiatorFlow(val arg1: Boolean, val arg2: Int, private val counterparty:
|
||||
// DOCEND 35
|
||||
|
||||
// If the transaction is only partially signed, we have to pass in
|
||||
// a list of the public keys corresponding to the missing
|
||||
// a vararg of the public keys corresponding to the missing
|
||||
// signatures, explicitly telling the system not to check them.
|
||||
// DOCSTART 36
|
||||
onceSignedTx.verifySignaturesExcept(counterpartyPubKey)
|
||||
// DOCEND 36
|
||||
|
||||
// There is also an overload of ``verifySignaturesExcept`` which accepts
|
||||
// a ``Collection`` of the public keys corresponding to the missing
|
||||
// signatures.
|
||||
// DOCSTART 54
|
||||
onceSignedTx.verifySignaturesExcept(listOf(counterpartyPubKey))
|
||||
// DOCEND 54
|
||||
|
||||
// We can also choose to only check the signatures that are
|
||||
// present. BE VERY CAREFUL - this function provides no guarantees
|
||||
// that the signatures are correct, or that none are missing.
|
||||
|
Reference in New Issue
Block a user