From 0dd8b22ceef5293e9ec0611b3478b505982b9970 Mon Sep 17 00:00:00 2001 From: Ashutosh Meher Date: Tue, 29 Aug 2023 09:22:10 +0530 Subject: [PATCH] Remane Finalize --- ...sponderFlow.java => FinalizeGoldTokenResponderFlow.java} | 4 ++-- ...nalizeMintSubFlow.java => FinalizeGoldTokenSubFlow.java} | 6 +++--- .../samples/tokens/workflows/IssueGoldTokensFlow.java | 3 +-- .../samples/tokens/workflows/TransferGoldTokenFlow.java | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) rename java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/{FinalizeMintResponderFlow.java => FinalizeGoldTokenResponderFlow.java} (95%) rename java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/{FinalizeMintSubFlow.java => FinalizeGoldTokenSubFlow.java} (92%) diff --git a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintResponderFlow.java b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenResponderFlow.java similarity index 95% rename from java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintResponderFlow.java rename to java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenResponderFlow.java index 0988cd6..6463c63 100644 --- a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintResponderFlow.java +++ b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenResponderFlow.java @@ -13,8 +13,8 @@ //@InitiatingBy declares the protocol which will be used to link the initiator to the responder. @InitiatedBy(protocol = "finalize-gold-protocol") -public class FinalizeMintResponderFlow implements ResponderFlow { - private final static Logger log = LoggerFactory.getLogger(FinalizeMintResponderFlow.class); +public class FinalizeGoldTokenResponderFlow implements ResponderFlow { + private final static Logger log = LoggerFactory.getLogger(FinalizeGoldTokenResponderFlow.class); // Injects the UtxoLedgerService to enable the flow to make use of the Ledger API. @CordaInject diff --git a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintSubFlow.java b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenSubFlow.java similarity index 92% rename from java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintSubFlow.java rename to java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenSubFlow.java index c270da6..9f0d3d5 100644 --- a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeMintSubFlow.java +++ b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/FinalizeGoldTokenSubFlow.java @@ -16,13 +16,13 @@ import java.util.List; @InitiatingFlow(protocol = "finalize-gold-protocol") -public class FinalizeMintSubFlow implements SubFlow { +public class FinalizeGoldTokenSubFlow implements SubFlow { - private final static Logger log = LoggerFactory.getLogger(FinalizeMintSubFlow.class); + private final static Logger log = LoggerFactory.getLogger(FinalizeGoldTokenSubFlow.class); private final UtxoSignedTransaction signedTransaction; private final MemberX500Name otherMember; - public FinalizeMintSubFlow(UtxoSignedTransaction signedTransaction, MemberX500Name otherMember) { + public FinalizeGoldTokenSubFlow(UtxoSignedTransaction signedTransaction, MemberX500Name otherMember) { this.signedTransaction = signedTransaction; this.otherMember = otherMember; } diff --git a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/IssueGoldTokensFlow.java b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/IssueGoldTokensFlow.java index 01dc3cb..a654af7 100644 --- a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/IssueGoldTokensFlow.java +++ b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/IssueGoldTokensFlow.java @@ -6,7 +6,6 @@ import net.corda.v5.application.flows.*; import net.corda.v5.application.marshalling.JsonMarshallingService; import net.corda.v5.application.membership.MemberLookup; -import net.corda.v5.application.messaging.FlowMessaging; import net.corda.v5.base.annotations.Suspendable; import net.corda.v5.base.exceptions.CordaRuntimeException; import net.corda.v5.base.types.MemberX500Name; @@ -87,7 +86,7 @@ public String call(ClientRequestBody requestBody) { UtxoSignedTransaction signedTransaction = txBuilder.toSignedTransaction(); - return flowEngine.subFlow(new FinalizeMintSubFlow(signedTransaction, owner.getName())); + return flowEngine.subFlow(new FinalizeGoldTokenSubFlow(signedTransaction, owner.getName())); } // Catch any exceptions, log them and rethrow the exception. catch (Exception e) { diff --git a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/TransferGoldTokenFlow.java b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/TransferGoldTokenFlow.java index 570cbd1..78adf0b 100644 --- a/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/TransferGoldTokenFlow.java +++ b/java-samples/shinny-tokens/workflows/src/main/java/com/r3/developers/samples/tokens/workflows/TransferGoldTokenFlow.java @@ -164,7 +164,7 @@ public String call( ClientRequestBody requestBody) { UtxoSignedTransaction signedTransaction = txBuilder.toSignedTransaction(); - flowEngine.subFlow(new FinalizeMintSubFlow(signedTransaction, receiver.getName())); + flowEngine.subFlow(new FinalizeGoldTokenSubFlow(signedTransaction, receiver.getName())); } catch (Exception e) {