Tutorial About Api




#
#  Eveem.org 26 Apr 2019 
#  Decompiled source of 0xeBE6c7a839A660a0F04BdF6816e2eA182F5d542C
# 
#  Let's make the world open source 
# 

const MAX_UINT256 = -1

def storage:
  owner is addr at storage 0

def owner(): # not payable
  return owner


#
#  Regular functions
#


def _fallback() payable: # default function
  revert


def transferOwnership(address _newOwner): # not payable
  require caller == owner
  owner = _newOwner
  log OwnerChanged(address owner=_newOwner)


def transfer(address _to, uint256 _value) payable: 
  require call.value - _value >= 0
  call _to with:
     value _value wei
       gas 2300 * is_zero(value) wei
  if not ext_call.success:
      return 0
  log Transfer(
        address from=_value,
        address to=caller,
        uint256 value=_to)
  return 1


def withdraw(address _address, uint256 _amount): # not payable
  require caller == owner
  call _address with:
     value 10^18 * _amount wei
       gas 2300 * is_zero(value) wei
  if not ext_call.success:
      return 0
  log Withdraw(
        address address=(10^18 * _amount),
        uint256 amount=_address)
  return 1