This should be fairly simple, but I'm still trying to wrap my mind around a lot of things.
What is the easiest way of testing by hand the function addEntity? What command do I type into the truffle console to execute the function addEntity?
Thanks
pragma solidity ^0.4.18;
contract MetaCoin {
struct Entity {
string name;
string nickname;
string streetaddress;
}
mapping (uint => Entity) entities;
uint entitiesCount;
event EntityAdded(address indexed _senderAddress, uint _entityId);
function addEntity(string _name, string _nickname, string _streetaddress) returns(uint entityId) {
entityId=entitiesCount ++;
entities[entityId]=Entity(_name,_nickname,_streetaddress);
EntityAdded(msg.sender,entityId);
}
}