4
0
Fork 0
Fork of the exw3 library. With our own additions
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
exw3/test/examples/contracts/Complex.sol

48 lines
1.0 KiB

pragma solidity ^0.4.0;
contract Complex {
uint foo;
bytes32 foobar;
bool barFoo;
event Bar(uint foo, address person);
event FooBar(bool fooboo, uint foo, bytes32 foobar);
constructor(uint _foo, bytes32 _foobar) public {
foo = _foo;
foobar = _foobar;
}
function getBoth() public view returns (uint, bytes32) {
return (foo, foobar);
}
function getBarFoo() public view returns (bool) {
return barFoo;
}
function getFooBar() public view returns (bytes32) {
return foobar;
}
function getFooBoo(uint _fooboo) public pure returns (uint fooBoo) {
fooBoo = _fooboo + 42;
}
function getBroAndBroBro() public view returns (uint bro, bytes32 broBro) {
return (foo + 42, foobar);
}
function setFoo(uint _foo) public {
foo = _foo;
}
function setFooBar(bytes32 _foobar) public {
foobar = _foobar;
}
function setBarFoo(bool _barFoo) public {
barFoo = _barFoo;
}
}