ChainMap_SmartContract

Smart contract for ChainDev Market Place designed by Infosec Lab., PKU. and ChainMap.

Some Functions about Challenge

PostChallenge

Post a challenge on the blockchain. More details.

  • Parameters: address, challengeId, challengeLevel, challenge, timeEstimation
  • Return: null
AnswerChallenge

Save an answer on the blockchain.More details.

  • Parameters: address, challengeId, answerId, answer
  • Return: null
GetChallenge

Get the information about a challenge from blockchain.

  • Parameters: challengeId
  • Return: Challenge Info
VoteAnswer

Vote answer on the blcokchain. More details.

  • Parameters: address, challengeId, answerId, result
  • Return: null
RewardAll

Reward a challenge, its answers and related voter.

  • Parameters: challengeId
  • return: null

Some Functions about Token

More details about functions.

name

Get the name of this project.

  • Parameters: null
  • return: "ChainMap"
name

Get the name of this project.

  • Parameters: null
  • return: "ChainMap"
symbol

Get the symbol of our token.

  • Parameters: null
  • return: "CMAP"
totalSupply

Get the total number of our token.

  • Parameters: null
  • return: "CMAP"
transfer

Transfer token from one account to another.

  • Parameters: to, value
  • return: null
balanceOf

Get the balance of the account.

  • Parameters: owner
  • return: balance