Skip to content

Instantly share code, notes, and snippets.

@davidawad
Created June 30, 2020 17:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidawad/112ccd6f3f1ddcadd0917e76091a3001 to your computer and use it in GitHub Desktop.
Save davidawad/112ccd6f3f1ddcadd0917e76091a3001 to your computer and use it in GitHub Desktop.
quick java snippet of corda accounts sdk
@Suspendable
@Override
public String call() throws FlowException {
//Generate accountinfo & AnonymousParty object for transaction
AccountInfo issuerAccountInfo = UtilitiesKt.getAccountService(this).accountInfo(issuer).get(0).getState().getData();
AccountInfo ownerAccountInfo = UtilitiesKt.getAccountService(this).accountInfo(owner).get(0).getState().getData();
AnonymousParty issuerAccount = subFlow(new RequestKeyForAccount(issuerAccountInfo));
AnonymousParty ownerAccount = subFlow(new RequestKeyForAccount(ownerAccountInfo));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment