Go-Ethereum
關於從映射中檢索數據的問題
這是智能合約。
pragma solidity ^0.4.8; contract RecordCreation { uint public count; mapping (address => string) public usertype; struct Patientdetails{ } Patientdetails[] public patientdetails; mapping (address => uint[]) public PatientDocuments; function RecordCreation(){ } //Function user type definition function userDefinition(string utype1) payable returns(bool result) { } //Data Submission Function function patientDataSubmission() payable returns (bool result){ } //Documents Count Retrieval Function for a Patient function countOfDataSubmission(address patientaddress) payable returns (uint result){ } function getPatientsCount(address patientaddress) constant returns (uint count) { } }
如何定義案例的契約 - 患者持有任意數量的文件?