Avatar¶
An Avatar holds tokens, reputation and ether for a controller
Execution cost: less than 81472 gas
Deployment cost: less than 467400 gas
Combined cost: less than 548872 gas
Constructor¶
Params:
- _orgName of type
bytes32
- _nativeToken of type
address
- _nativeReputation of type
address
Events¶
ExternalTokenDecreaseApproval(address,address,uint256)¶
Execution cost: No bound available
Params:
- _externalToken of type
address
- _spender of type
address
- _subtractedValue of type
uint256
ExternalTokenIncreaseApproval(address,address,uint256)¶
Execution cost: No bound available
Params:
- _externalToken of type
address
- _spender of type
address
- _addedValue of type
uint256
ExternalTokenTransfer(address,address,uint256)¶
Execution cost: No bound available
Params:
- _externalToken of type
address
- _to of type
address
- _value of type
uint256
ExternalTokenTransferFrom(address,address,address,uint256)¶
Execution cost: No bound available
Params:
- _externalToken of type
address
- _from of type
address
- _to of type
address
- _value of type
uint256
GenericAction(address,bytes32[])¶
Execution cost: No bound available
Params:
- _action of type
address
- _params of type
bytes32[]
OwnershipTransferred(address,address)¶
Execution cost: No bound available
Params:
- previousOwner of type
address
- newOwner of type
address
ReceiveEther(address,uint256)¶
Execution cost: No bound available
Params:
- _sender of type
address
- _value of type
uint256
SendEther(uint256,address)¶
Execution cost: No bound available
Params:
- _amountInWei of type
uint256
- _to of type
address
Fallback¶
Execution cost: less than 1870 gas
Attributes: payable
Methods¶
externalTokenTransferFrom(address,address,address,uint256)¶
external token transfer from a specific account
Execution cost: No bound available
Params:
-
_externalToken of type
address
the token contract
-
_from of type
address
the account to spend token from
-
_to of type
address
the destination address
-
_value of type
uint256
the amount of tokens to transfer
Returns:
bool which represents success
- output_0 of type
bool
orgName()¶
Execution cost: less than 1545 gas
Attributes: constant
Returns:
- output_0 of type
bytes32
nativeReputation()¶
Execution cost: less than 1545 gas
Attributes: constant
Returns:
- output_0 of type
address
externalTokenIncreaseApproval(address,address,uint256)¶
increase approval for the spender address to spend a specified amount of tokens on behalf of msg.sender.
Execution cost: No bound available
Params:
-
_externalToken of type
address
the address of the Token Contract
-
_spender of type
address
address
-
_addedValue of type
uint256
the amount of ether (in Wei) which the approval is referring to.
Returns:
bool which represents a success
- output_0 of type
bool
nativeToken()¶
Execution cost: less than 1545 gas
Attributes: constant
Returns:
- output_0 of type
address
genericAction(address,bytes32[])¶
call an action function on an ActionInterface. This function use delegatecall and might expose the organization to security risk. Use this function only if you really knows what you are doing.
Execution cost: No bound available
Params:
-
_action of type
address
the address of the contract to call.
-
_params of type
bytes32[]
the params for the call.
Returns:
bool which represents success
- output_0 of type
bool
externalTokenTransfer(address,address,uint256)¶
external token transfer
Execution cost: No bound available
Params:
-
_externalToken of type
address
the token contract
-
_to of type
address
the destination address
-
_value of type
uint256
the amount of tokens to transfer
Returns:
bool which represents success
- output_0 of type
bool
externalTokenDecreaseApproval(address,address,uint256)¶
decrease approval for the spender address to spend a specified amount of tokens on behalf of msg.sender.
Execution cost: No bound available
Params:
-
_externalToken of type
address
the address of the Token Contract
-
_spender of type
address
address
-
_subtractedValue of type
uint256
the amount of ether (in Wei) which the approval is referring to.
Returns:
bool which represents a success
- output_0 of type
bool
owner()¶
Execution cost: less than 1545 gas
Attributes: constant
Returns:
- output_0 of type
address
sendEther(uint256,address)¶
send ethers from the avatar's wallet
Execution cost: No bound available
Params:
-
_amountInWei of type
uint256
amount to send in Wei units
-
_to of type
address
send the ethers to this address
Returns:
bool which represents success
- output_0 of type
bool
transferOwnership(address)¶
Allows the current owner to transfer control of the contract to a newOwner.
Execution cost: less than 23027 gas
Params:
-
newOwner of type
address
The address to transfer ownership to.