S++Business systems language
DEMO SOURCE · SPP / APP / PHYRead the book

petshop-00-model.spp

petshop/payment/petshop-00-model.spp

Download original file · Petstore source contents

1domain petshop;23Role SettlementAccount {4    business("Third-party payment settlement account number") String accountNumber;5    quantum BigDecimal(25, 2) balance;6}78Contract WalletFundingAgreement {9    Buyer buyer;10    SettlementAccount source;11    BigDecimal(19, 2) amount;12}1314Contract PaymentAgreement {15    Buyer buyer;16    Merchant seller;17    ShopOrder order;18    Receipt receipt;19    BigDecimal(19, 2) paymentAmount;20}