Here is a sample contract which is designed to take xyz token
. How can the contract verify that the sent is the xyz token
?
pragma "^0.7.0"
contract myContract {
address public payable owner;
uint public value; //<<==xyz token
constructor(uint _value) payable {
owner = msg.sender;
value = _value; //<<== how does the contract verify it is the _value of xyz token?
}
}