-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1168 from Agoric/revert-1166-changes
Revert "Fix dapp tutorial intro" accidental changes to #1140
- Loading branch information
Showing
7 changed files
with
141 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
title: "ERTP: Mint, Issuer, Brand" | ||
--- | ||
classDiagram | ||
class IssuerKit | ||
IssuerKit "1" *-- "1" Mint | ||
IssuerKit "1" *-- "1" Issuer | ||
IssuerKit "1" *-- "1" Brand | ||
|
||
class ertp["@agoric/ertp"] { | ||
makeIssuerKit() IssuerKit | ||
... | ||
} | ||
ertp --> IssuerKit : makeIssuerKit | ||
|
||
class Mint { | ||
getIssuer() | ||
} | ||
Mint --> Issuer: getIssuer | ||
class Issuer { | ||
getBrand() | ||
} | ||
Issuer --> Brand: getBrand | ||
class Brand | ||
``` |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
title: "ERTP: Amount, Payment, Purse" | ||
--- | ||
classDiagram | ||
class IssuerKit | ||
IssuerKit "1" *-- "1" Mint | ||
IssuerKit "1" *-- "1" Issuer | ||
IssuerKit "1" *-- "1" Brand | ||
|
||
class ertp["@agoric/ertp"] { | ||
makeIssuerKit() IssuerKit | ||
AmountMath | ||
... | ||
} | ||
ertp *-- AmountMath : import | ||
class AmountMath { | ||
make(brand: Brand, value) Amount | ||
} | ||
ertp --> IssuerKit : makeIssuerKit | ||
AmountMath --> Amount : make | ||
|
||
class Mint { | ||
getIssuer() | ||
mintPayment(amount: Amount) | ||
} | ||
Mint --> Issuer: getIssuer | ||
Mint --> Payment : mintPayment | ||
class Issuer { | ||
getBrand() | ||
makeEmptyPurse() | ||
getAmountOf(payment: Payment) | ||
} | ||
Issuer --> Brand: getBrand | ||
Issuer --> Purse: makeEmptyPurse() | ||
Issuer "1" *-- "many" Payment | ||
Payment | ||
class Brand | ||
class Payment | ||
class Amount { | ||
brand: Brand | ||
value: Value | ||
} | ||
class Purse { | ||
+getCurrentAmount() | ||
+deposit(payment: Payment, expectedAmount?: Amount) | ||
+withdraw(amount: Amount) | ||
} | ||
Purse --> Payment : withdraw | ||
``` |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- | ||
title: "ERTP: Fungible and Non-Fungible Assets" | ||
--- | ||
classDiagram | ||
class IssuerKit~Kind~ | ||
IssuerKit "1" *-- "1" Mint~Kind~ | ||
IssuerKit "1" *-- "1" Issuer~Kind~ | ||
IssuerKit "1" *-- "1" Brand~Kind~ | ||
|
||
class ertp["@agoric/ertp"] { | ||
makeIssuerKit() IssuerKit | ||
AmountMath | ||
AssetKind | ||
} | ||
ertp *-- AmountMath : import | ||
ertp *-- AssetKind : import | ||
class AmountMath { | ||
make(brand: Brand~K~, value~K~) Amount~K~ | ||
} | ||
ertp --> IssuerKit~K~ : makeIssuerKit | ||
AmountMath --> Amount~K~ : make | ||
|
||
class Mint~Kind~ { | ||
getIssuer() | ||
mintPayment(amount: Amount~Kind~) | ||
} | ||
Mint --> Issuer: getIssuer | ||
Mint --> Payment~Kind~ : mintPayment | ||
class Issuer~Kind~ { | ||
getBrand() | ||
makeEmptyPurse() | ||
getAmountOf(payment: Payment) | ||
} | ||
Issuer --> Brand: getBrand | ||
Issuer --> Purse~Kind~: makeEmptyPurse() | ||
Issuer "1" *-- "many" Payment | ||
Payment | ||
class Brand~Kind~ | ||
class Payment~Kind~ | ||
class Amount~Kind~ { | ||
brand: Brand~Kind~ | ||
value: Value~Kind~ | ||
} | ||
class Purse~Kind~ { | ||
+getCurrentAmount() | ||
+deposit(payment: Payment~Kind~, expectedAmount?: Amount~Kind~) | ||
+withdraw(amount: Amount~Kind~) | ||
} | ||
Purse --> Payment : withdraw | ||
|
||
class AssetKind { | ||
NAT // fungible | ||
COPY_BAG // non-fungible | ||
... | ||
} | ||
<<Enumeration>> AssetKind | ||
``` |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters