Skip to content

cordapp demonstrating central bank to facilitate currency issuance, transfer to consumers and transfer within consumers, and consumers destroying their cash

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENCE
MIT
LICENSE
Notifications You must be signed in to change notification settings

rshrimp/cordapp-centralbank

Repository files navigation

Corda

The Central Bank CorDapp

This CorDapp comprises a demo of cash that can be issued, transferred and destroyed (aka removed from circulation). The CorDapp includes:

  • An cash state definition that records an amount of any currency with bank, and owner parties. The cash state
  • A contract that facilitates the verification of issuance, transfer (from one owner to another) and removing of cash.
  • Three sets of flows for issuing, transferring and destroying cashs.
  • It also includes test cases for contract testing

The CorDapp allows you to issue, transfer (from old owner to new owner- this could be from bank to owner too) and remove cash. It does not currently have an API yet (in works).

Instructions for setting up

See https://docs.corda.net/tutorial-cordapp.html#running-the-example-cordapp.

+......................+.........................+..................+..............+.........+....................+
UseCase                + Invoker +(Owner)Balance +(newOwner)Balance + Inputs       +Outputs  + Signers            +  
+......................+.........+...............+..................+..............+.........+....................+
Issue $100             + Bank    +(Bank)$100     + NA               + None         +$100     + Bank               +
+......................+.........+...............+..................+..............+.........+....................+
Xfer $50 Bank->newOwner+ Bank    +(Bank)$50      +(new) $50         + $100         + $50 Bank+ Bank, newOwner     +
                                                                                   + $50 New +                    +
                                                                                        Owner+                    +
+......................+.........+...............+..................+..............+.........+....................+
Xfer $10 Owner->newOwner+ Owner  +(Owner)$40     +(new) $10         + $50          + $10 New + Owner, newOwner    +
                                                                                   + Owner,  +                    +
                                                                                   + $40 Owner                    +
+......................+.........+...............+..................+........................+....................+
Destroy $10            + newOwner+               +(newOwner)$0      + $10          +         + newOwner, Bank     +
+......................+.........+...............+..................+..............+.........+....................+

TODO

  1. Anonymous parties implementation.
  2. Add front end
  3. Add flow tests

About

cordapp demonstrating central bank to facilitate currency issuance, transfer to consumers and transfer within consumers, and consumers destroying their cash

Resources

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENCE
MIT
LICENSE

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages