Blockwell

Linear Token

ERC20

This contract is an ERC20 token.

Name Linear Token
Symbol LINA
Decimals 18
Total Supply 10,000,000,000 LINA

About link

Linear (LINA) is a cryptocurrency and operates on the Ethereum platform. Linear has a current supply of 10,000,000,000 with 3,755,627,344.7466664 in circulation. The last known price of Linear is 0.03220689 USD and is down -7.72 over the last 24 hours. It is currently trading on 34 active market(s) with $25,732,932.84 traded over the last 24 hours. More information can be found at https://linear.finance.

Stats

Public Functions 18
Event Types 5
Code Size 7,846 bytes

Events (5) keyboard_arrow_up

AdminChanged Event

Parameters help
oldAdmin
address help
newAdmin
address help

Approval Event

Parameters help
owner
address help
spender
address help
value
uint help

TargetUpdated Event

Parameters help
newTarget
LnProxyImpl help

Transfer Event

Parameters help
from
address help
to
address help
value
uint help

candidateChanged Event

Parameters help
oldCandidate
address help
newCandidate
address help

target Variable

address help

admin Variable

address help

candidate Variable

address help

Functions Expand All Collapse All

setCandidate keyboard_arrow_up

Parameters help

Name Type
_candidate
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyAdmin checks for the following:
Source Code
function setCandidate(address _candidate) external onlyAdmin {
  address old = candidate;
  candidate = _candidate;
  emit candidateChanged(old, candidate);
}

becomeAdmin keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function becomeAdmin() external {
  require(msg.sender == candidate, "Only candidate can become admin");
  address old = admin;
  admin = candidate;
  emit AdminChanged(old, admin);
}

setTarget keyboard_arrow_up

Parameters help

Name Type
_target
LnProxyImpl help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyAdmin checks for the following:
Source Code
function setTarget(LnProxyImpl _target) external onlyAdmin {
  target = _target;
  emit TargetUpdated(_target);
}

Log0 keyboard_arrow_up

Parameters help

Name Type
callData
bytes help

Properties

Visibility help public
Mutability help transaction
Source Code
function Log0(bytes calldata callData) external onlyTarget {
  uint256 size = callData.length;
  bytes memory _callData = callData;
  assembly {
    log0(add(_callData, 32), size)
  }
}

Log1 keyboard_arrow_up

Parameters help

Name Type
callData
bytes help
topic1
bytes32 help

Properties

Visibility help public
Mutability help transaction
Source Code
function Log1(bytes calldata callData, bytes32 topic1) external onlyTarget {
  uint256 size = callData.length;
  bytes memory _callData = callData;
  assembly {
    log1(add(_callData, 32), size, topic1)
  }
}

Log2 keyboard_arrow_up

Parameters help

Name Type
callData
bytes help
topic1
bytes32 help
topic2
bytes32 help

Properties

Visibility help public
Mutability help transaction
Source Code
function Log2(
  bytes calldata callData,
  bytes32 topic1,
  bytes32 topic2
) external onlyTarget {
  uint256 size = callData.length;
  bytes memory _callData = callData;
  assembly {
    log2(add(_callData, 32), size, topic1, topic2)
  }
}

Log3 keyboard_arrow_up

Parameters help

Name Type
callData
bytes help
topic1
bytes32 help
topic2
bytes32 help
topic3
bytes32 help

Properties

Visibility help public
Mutability help transaction
Source Code
function Log3(
  bytes calldata callData,
  bytes32 topic1,
  bytes32 topic2,
  bytes32 topic3
) external onlyTarget {
  uint256 size = callData.length;
  bytes memory _callData = callData;
  assembly {
    log3(add(_callData, 32), size, topic1, topic2, topic3)
  }
}

Log4 keyboard_arrow_up

Parameters help

Name Type
callData
bytes help
topic1
bytes32 help
topic2
bytes32 help
topic3
bytes32 help
topic4
bytes32 help

Properties

Visibility help public
Mutability help transaction
Source Code
function Log4(
  bytes calldata callData,
  bytes32 topic1,
  bytes32 topic2,
  bytes32 topic3,
  bytes32 topic4
) external onlyTarget {
  uint256 size = callData.length;
  bytes memory _callData = callData;
  assembly {
    log4(add(_callData, 32), size, topic1, topic2, topic3, topic4)
  }
}

constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help payable
Source Code
receive() external payable {
  target.setMessageSender(msg.sender);

  assembly {
    let free_ptr := mload(0x40)
    calldatacopy(free_ptr, 0, calldatasize())

    let result := call(
      gas(),
      sload(target_slot),
      callvalue(),
      free_ptr,
      calldatasize(),
      0,
      0
    )
    returndatacopy(free_ptr, 0, returndatasize())

    if iszero(result) {
      revert(free_ptr, returndatasize())
    }
    return(free_ptr, returndatasize())
  }
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function name() public view override returns (string memory) {
  return IERC20(address(target)).name();
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function symbol() public view override returns (string memory) {
  return IERC20(address(target)).symbol();
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function decimals() public view override returns (uint8) {
  return IERC20(address(target)).decimals();
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function totalSupply() public view override returns (uint256) {
  return IERC20(address(target)).totalSupply();
}

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help view
Source Code
function balanceOf(address account) public view override returns (uint256) {
  return IERC20(address(target)).balanceOf(account);
}

Parameters help

Name Type
owner
address help
spender
address help

Properties

Visibility help public
Mutability help view
Source Code
function allowance(address owner, address spender)
  public
  view
  override
  returns (uint256)
{
  return IERC20(address(target)).allowance(owner, spender);
}

Parameters help

Name Type
to
address help
value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transfer(address to, uint256 value) public override returns (bool) {
  target.setMessageSender(msg.sender);

  IERC20(address(target)).transfer(to, value);

  return true;
}

Parameters help

Name Type
spender
address help
value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function approve(address spender, uint256 value)
  public
  override
  returns (bool)
{
  target.setMessageSender(msg.sender);

  IERC20(address(target)).approve(spender, value);

  return true;
}

Parameters help

Name Type
from
address help
to
address help
value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFrom(
  address from,
  address to,
  uint256 value
) public override returns (bool) {
  target.setMessageSender(msg.sender);

  IERC20(address(target)).transferFrom(from, to, value);

  return true;
}

Internal Functions Expand All Collapse All

Internal functions are parts of the contract that can't be used directly, but instead are used by the public functions listed above.