业务网络中的多个参与者类型

时间:2017-03-08 14:37:22

标签: hyperledger-composer

如何处理网络中的多个参与者类型?如果我为拍卖师建模,我可能希望将其作为用户的扩展。

1 个答案:

答案 0 :(得分:1)

以下示例概述了您要查找的内容

https://github.com/hyperledger/composer-sample-networks/blob/master/packages/carauction-network/models/auction.cto

abstract participant User identified by email {
  o String email
  o String firstName
  o String lastName
}

participant Member extends User {
 o Double balance
}

participant Auctioneer extends User {
}