Skip to content

Latest commit

 

History

History
2365 lines (1921 loc) · 54.1 KB

StoreKeyUtil.md

File metadata and controls

2365 lines (1921 loc) · 54.1 KB

StoreKeyUtil.sol

View Source: contracts/libraries/StoreKeyUtil.sol

StoreKeyUtil

Functions

setUintByKey

function setUintByKey(IStore s, bytes32 key, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value uint256
Source Code
function setUintByKey(
    IStore s,
    bytes32 key,
    uint256 value
  ) external {
    require(key > 0, "Invalid key");
    return s.setUint(key, value);
  }

setUintByKeys

function setUintByKeys(IStore s, bytes32 key1, bytes32 key2, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value uint256
Source Code
function setUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    uint256 value
  ) external {
    return s.setUint(_getKey(key1, key2), value);
  }

setUintByKeys

function setUintByKeys(IStore s, bytes32 key1, bytes32 key2, address account, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
value uint256
Source Code
function setUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account,
    uint256 value
  ) external {
    return s.setUint(_getKey(key1, key2, account), value);
  }

addUintByKey

function addUintByKey(IStore s, bytes32 key, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value uint256
Source Code
function addUintByKey(
    IStore s,
    bytes32 key,
    uint256 value
  ) external {
    require(key > 0, "Invalid key");
    return s.addUint(key, value);
  }

addUintByKeys

function addUintByKeys(IStore s, bytes32 key1, bytes32 key2, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value uint256
Source Code
function addUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    uint256 value
  ) external {
    return s.addUint(_getKey(key1, key2), value);
  }

addUintByKeys

function addUintByKeys(IStore s, bytes32 key1, bytes32 key2, address account, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
value uint256
Source Code
function addUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account,
    uint256 value
  ) external {
    return s.addUint(_getKey(key1, key2, account), value);
  }

subtractUintByKey

function subtractUintByKey(IStore s, bytes32 key, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value uint256
Source Code
function subtractUintByKey(
    IStore s,
    bytes32 key,
    uint256 value
  ) external {
    require(key > 0, "Invalid key");
    return s.subtractUint(key, value);
  }

subtractUintByKeys

function subtractUintByKeys(IStore s, bytes32 key1, bytes32 key2, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value uint256
Source Code
function subtractUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    uint256 value
  ) external {
    return s.subtractUint(_getKey(key1, key2), value);
  }

subtractUintByKeys

function subtractUintByKeys(IStore s, bytes32 key1, bytes32 key2, address account, uint256 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
value uint256
Source Code
function subtractUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account,
    uint256 value
  ) external {
    return s.subtractUint(_getKey(key1, key2, account), value);
  }

setStringByKey

function setStringByKey(IStore s, bytes32 key, string value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value string
Source Code
function setStringByKey(
    IStore s,
    bytes32 key,
    string memory value
  ) external {
    require(key > 0, "Invalid key");
    s.setString(key, value);
  }

setStringByKeys

function setStringByKeys(IStore s, bytes32 key1, bytes32 key2, string value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value string
Source Code
function setStringByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    string memory value
  ) external {
    return s.setString(_getKey(key1, key2), value);
  }

setBytes32ByKey

function setBytes32ByKey(IStore s, bytes32 key, bytes32 value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value bytes32
Source Code
function setBytes32ByKey(
    IStore s,
    bytes32 key,
    bytes32 value
  ) external {
    require(key > 0, "Invalid key");
    s.setBytes32(key, value);
  }

setBytes32ByKeys

function setBytes32ByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value bytes32
Source Code
function setBytes32ByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 value
  ) external {
    return s.setBytes32(_getKey(key1, key2), value);
  }

setBoolByKey

function setBoolByKey(IStore s, bytes32 key, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value bool
Source Code
function setBoolByKey(
    IStore s,
    bytes32 key,
    bool value
  ) external {
    require(key > 0, "Invalid key");
    return s.setBool(key, value);
  }

setBoolByKeys

function setBoolByKeys(IStore s, bytes32 key1, bytes32 key2, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value bool
Source Code
function setBoolByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bool value
  ) external {
    return s.setBool(_getKey(key1, key2), value);
  }

setBoolByKeys

function setBoolByKeys(IStore s, bytes32 key, address account, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
account address
value bool
Source Code
function setBoolByKeys(
    IStore s,
    bytes32 key,
    address account,
    bool value
  ) external {
    return s.setBool(_getKey(key, account), value);
  }

setAddressByKey

function setAddressByKey(IStore s, bytes32 key, address value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value address
Source Code
function setAddressByKey(
    IStore s,
    bytes32 key,
    address value
  ) external {
    require(key > 0, "Invalid key");
    return s.setAddress(key, value);
  }

setAddressByKeys

function setAddressByKeys(IStore s, bytes32 key1, bytes32 key2, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value address
Source Code
function setAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address value
  ) external {
    return s.setAddress(_getKey(key1, key2), value);
  }

setAddressByKeys

function setAddressByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
value address
Source Code
function setAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address value
  ) external {
    return s.setAddress(_getKey(key1, key2, key3), value);
  }

setAddressArrayByKey

function setAddressArrayByKey(IStore s, bytes32 key, address value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value address
Source Code
function setAddressArrayByKey(
    IStore s,
    bytes32 key,
    address value
  ) external {
    require(key > 0, "Invalid key");
    return s.setAddressArrayItem(key, value);
  }

setAddressArrayByKeys

function setAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value address
Source Code
function setAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address value
  ) external {
    return s.setAddressArrayItem(_getKey(key1, key2), value);
  }

setAddressArrayByKeys

function setAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
value address
Source Code
function setAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address value
  ) external {
    return s.setAddressArrayItem(_getKey(key1, key2, key3), value);
  }

setAddressBooleanByKey

function setAddressBooleanByKey(IStore s, bytes32 key, address account, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
account address
value bool
Source Code
function setAddressBooleanByKey(
    IStore s,
    bytes32 key,
    address account,
    bool value
  ) external {
    require(key > 0, "Invalid key");
    return s.setAddressBoolean(key, account, value);
  }

setAddressBooleanByKeys

function setAddressBooleanByKeys(IStore s, bytes32 key1, bytes32 key2, address account, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
value bool
Source Code
function setAddressBooleanByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account,
    bool value
  ) external {
    return s.setAddressBoolean(_getKey(key1, key2), account, value);
  }

setAddressBooleanByKeys

function setAddressBooleanByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address account, bool value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
account address
value bool
Source Code
function setAddressBooleanByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address account,
    bool value
  ) external {
    return s.setAddressBoolean(_getKey(key1, key2, key3), account, value);
  }

deleteUintByKey

function deleteUintByKey(IStore s, bytes32 key) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function deleteUintByKey(IStore s, bytes32 key) external {
    require(key > 0, "Invalid key");
    return s.deleteUint(key);
  }

deleteUintByKeys

function deleteUintByKeys(IStore s, bytes32 key1, bytes32 key2) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function deleteUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external {
    return s.deleteUint(_getKey(key1, key2));
  }

deleteBytes32ByKey

function deleteBytes32ByKey(IStore s, bytes32 key) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function deleteBytes32ByKey(IStore s, bytes32 key) external {
    require(key > 0, "Invalid key");
    s.deleteBytes32(key);
  }

deleteBytes32ByKeys

function deleteBytes32ByKeys(IStore s, bytes32 key1, bytes32 key2) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function deleteBytes32ByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external {
    return s.deleteBytes32(_getKey(key1, key2));
  }

deleteBoolByKey

function deleteBoolByKey(IStore s, bytes32 key) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function deleteBoolByKey(IStore s, bytes32 key) external {
    require(key > 0, "Invalid key");
    return s.deleteBool(key);
  }

deleteBoolByKeys

function deleteBoolByKeys(IStore s, bytes32 key1, bytes32 key2) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function deleteBoolByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external {
    return s.deleteBool(_getKey(key1, key2));
  }

deleteBoolByKeys

function deleteBoolByKeys(IStore s, bytes32 key, address account) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
account address
Source Code
function deleteBoolByKeys(
    IStore s,
    bytes32 key,
    address account
  ) external {
    return s.deleteBool(_getKey(key, account));
  }

deleteAddressByKey

function deleteAddressByKey(IStore s, bytes32 key) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function deleteAddressByKey(IStore s, bytes32 key) external {
    require(key > 0, "Invalid key");
    return s.deleteAddress(key);
  }

deleteAddressByKeys

function deleteAddressByKeys(IStore s, bytes32 key1, bytes32 key2) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function deleteAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external {
    return s.deleteAddress(_getKey(key1, key2));
  }

deleteAddressByKeys

function deleteAddressByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
Source Code
function deleteAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3
  ) external {
    return s.deleteAddress(_getKey(key1, key2, key3));
  }

deleteAddressArrayByKey

function deleteAddressArrayByKey(IStore s, bytes32 key, address value) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
value address
Source Code
function deleteAddressArrayByKey(
    IStore s,
    bytes32 key,
    address value
  ) external {
    require(key > 0, "Invalid key");
    return s.deleteAddressArrayItem(key, value);
  }

deleteAddressArrayByKeys

function deleteAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
value address
Source Code
function deleteAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address value
  ) external {
    return s.deleteAddressArrayItem(_getKey(key1, key2), value);
  }

deleteAddressArrayByKeys

function deleteAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address value) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
value address
Source Code
function deleteAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address value
  ) external {
    return s.deleteAddressArrayItem(_getKey(key1, key2, key3), value);
  }

deleteAddressArrayByIndexByKey

function deleteAddressArrayByIndexByKey(IStore s, bytes32 key, uint256 index) external nonpayable

Arguments

Name Type Description
s IStore
key bytes32
index uint256
Source Code
function deleteAddressArrayByIndexByKey(
    IStore s,
    bytes32 key,
    uint256 index
  ) external {
    require(key > 0, "Invalid key");
    return s.deleteAddressArrayItemByIndex(key, index);
  }

deleteAddressArrayByIndexByKeys

function deleteAddressArrayByIndexByKeys(IStore s, bytes32 key1, bytes32 key2, uint256 index) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
index uint256
Source Code
function deleteAddressArrayByIndexByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    uint256 index
  ) external {
    return s.deleteAddressArrayItemByIndex(_getKey(key1, key2), index);
  }

deleteAddressArrayByIndexByKeys

function deleteAddressArrayByIndexByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, uint256 index) external nonpayable

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
index uint256
Source Code
function deleteAddressArrayByIndexByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    uint256 index
  ) external {
    return s.deleteAddressArrayItemByIndex(_getKey(key1, key2, key3), index);
  }

getUintByKey

function getUintByKey(IStore s, bytes32 key) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getUintByKey(IStore s, bytes32 key) external view returns (uint256) {
    require(key > 0, "Invalid key");
    return s.getUint(key);
  }

getUintByKeys

function getUintByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (uint256) {
    return s.getUint(_getKey(key1, key2));
  }

getUintByKeys

function getUintByKeys(IStore s, bytes32 key1, bytes32 key2, address account) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
Source Code
function getUintByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account
  ) external view returns (uint256) {
    return s.getUint(_getKey(key1, key2, account));
  }

getStringByKey

function getStringByKey(IStore s, bytes32 key) external view
returns(string)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getStringByKey(IStore s, bytes32 key) external view returns (string memory) {
    require(key > 0, "Invalid key");
    return s.getString(key);
  }

getStringByKeys

function getStringByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(string)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getStringByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (string memory) {
    return s.getString(_getKey(key1, key2));
  }

getBytes32ByKey

function getBytes32ByKey(IStore s, bytes32 key) external view
returns(bytes32)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getBytes32ByKey(IStore s, bytes32 key) external view returns (bytes32) {
    require(key > 0, "Invalid key");
    return s.getBytes32(key);
  }

getBytes32ByKeys

function getBytes32ByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(bytes32)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getBytes32ByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (bytes32) {
    return s.getBytes32(_getKey(key1, key2));
  }

getBoolByKey

function getBoolByKey(IStore s, bytes32 key) external view
returns(bool)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getBoolByKey(IStore s, bytes32 key) external view returns (bool) {
    require(key > 0, "Invalid key");
    return s.getBool(key);
  }

getBoolByKeys

function getBoolByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(bool)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getBoolByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (bool) {
    return s.getBool(_getKey(key1, key2));
  }

getBoolByKeys

function getBoolByKeys(IStore s, bytes32 key, address account) external view
returns(bool)

Arguments

Name Type Description
s IStore
key bytes32
account address
Source Code
function getBoolByKeys(
    IStore s,
    bytes32 key,
    address account
  ) external view returns (bool) {
    return s.getBool(_getKey(key, account));
  }

getAddressByKey

function getAddressByKey(IStore s, bytes32 key) external view
returns(address)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getAddressByKey(IStore s, bytes32 key) external view returns (address) {
    require(key > 0, "Invalid key");
    return s.getAddress(key);
  }

getAddressByKeys

function getAddressByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(address)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (address) {
    return s.getAddress(_getKey(key1, key2));
  }

getAddressByKeys

function getAddressByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3) external view
returns(address)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
Source Code
function getAddressByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3
  ) external view returns (address) {
    return s.getAddress(_getKey(key1, key2, key3));
  }

getAddressBooleanByKey

function getAddressBooleanByKey(IStore s, bytes32 key, address account) external view
returns(bool)

Arguments

Name Type Description
s IStore
key bytes32
account address
Source Code
function getAddressBooleanByKey(
    IStore s,
    bytes32 key,
    address account
  ) external view returns (bool) {
    require(key > 0, "Invalid key");
    return s.getAddressBoolean(key, account);
  }

getAddressBooleanByKeys

function getAddressBooleanByKeys(IStore s, bytes32 key1, bytes32 key2, address account) external view
returns(bool)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
account address
Source Code
function getAddressBooleanByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address account
  ) external view returns (bool) {
    return s.getAddressBoolean(_getKey(key1, key2), account);
  }

getAddressBooleanByKeys

function getAddressBooleanByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address account) external view
returns(bool)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
account address
Source Code
function getAddressBooleanByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address account
  ) external view returns (bool) {
    return s.getAddressBoolean(_getKey(key1, key2, key3), account);
  }

countAddressArrayByKey

function countAddressArrayByKey(IStore s, bytes32 key) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function countAddressArrayByKey(IStore s, bytes32 key) external view returns (uint256) {
    require(key > 0, "Invalid key");
    return s.countAddressArrayItems(key);
  }

countAddressArrayByKeys

function countAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function countAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (uint256) {
    return s.countAddressArrayItems(_getKey(key1, key2));
  }

countAddressArrayByKeys

function countAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
Source Code
function countAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3
  ) external view returns (uint256) {
    return s.countAddressArrayItems(_getKey(key1, key2, key3));
  }

getAddressArrayByKey

function getAddressArrayByKey(IStore s, bytes32 key) external view
returns(address[])

Arguments

Name Type Description
s IStore
key bytes32
Source Code
function getAddressArrayByKey(IStore s, bytes32 key) external view returns (address[] memory) {
    require(key > 0, "Invalid key");
    return s.getAddressArray(key);
  }

getAddressArrayByKeys

function getAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2) external view
returns(address[])

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
Source Code
function getAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2
  ) external view returns (address[] memory) {
    return s.getAddressArray(_getKey(key1, key2));
  }

getAddressArrayByKeys

function getAddressArrayByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3) external view
returns(address[])

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
Source Code
function getAddressArrayByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3
  ) external view returns (address[] memory) {
    return s.getAddressArray(_getKey(key1, key2, key3));
  }

getAddressArrayItemPositionByKey

function getAddressArrayItemPositionByKey(IStore s, bytes32 key, address addressToFind) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key bytes32
addressToFind address
Source Code
function getAddressArrayItemPositionByKey(
    IStore s,
    bytes32 key,
    address addressToFind
  ) external view returns (uint256) {
    require(key > 0, "Invalid key");
    return s.getAddressArrayItemPosition(key, addressToFind);
  }

getAddressArrayItemPositionByKeys

function getAddressArrayItemPositionByKeys(IStore s, bytes32 key1, bytes32 key2, address addressToFind) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
addressToFind address
Source Code
function getAddressArrayItemPositionByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    address addressToFind
  ) external view returns (uint256) {
    return s.getAddressArrayItemPosition(_getKey(key1, key2), addressToFind);
  }

getAddressArrayItemPositionByKeys

function getAddressArrayItemPositionByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, address addressToFind) external view
returns(uint256)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
addressToFind address
Source Code
function getAddressArrayItemPositionByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    address addressToFind
  ) external view returns (uint256) {
    return s.getAddressArrayItemPosition(_getKey(key1, key2, key3), addressToFind);
  }

getAddressArrayItemByIndexByKey

function getAddressArrayItemByIndexByKey(IStore s, bytes32 key, uint256 index) external view
returns(address)

Arguments

Name Type Description
s IStore
key bytes32
index uint256
Source Code
function getAddressArrayItemByIndexByKey(
    IStore s,
    bytes32 key,
    uint256 index
  ) external view returns (address) {
    require(key > 0, "Invalid key");
    return s.getAddressArrayItemByIndex(key, index);
  }

getAddressArrayItemByIndexByKeys

function getAddressArrayItemByIndexByKeys(IStore s, bytes32 key1, bytes32 key2, uint256 index) external view
returns(address)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
index uint256
Source Code
function getAddressArrayItemByIndexByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    uint256 index
  ) external view returns (address) {
    return s.getAddressArrayItemByIndex(_getKey(key1, key2), index);
  }

getAddressArrayItemByIndexByKeys

function getAddressArrayItemByIndexByKeys(IStore s, bytes32 key1, bytes32 key2, bytes32 key3, uint256 index) external view
returns(address)

Arguments

Name Type Description
s IStore
key1 bytes32
key2 bytes32
key3 bytes32
index uint256
Source Code
function getAddressArrayItemByIndexByKeys(
    IStore s,
    bytes32 key1,
    bytes32 key2,
    bytes32 key3,
    uint256 index
  ) external view returns (address) {
    return s.getAddressArrayItemByIndex(_getKey(key1, key2, key3), index);
  }

_getKey

function _getKey(bytes32 key1, bytes32 key2) private pure
returns(bytes32)

Arguments

Name Type Description
key1 bytes32
key2 bytes32
Source Code
function _getKey(bytes32 key1, bytes32 key2) private pure returns (bytes32) {
    require(key1 > 0 && key2 > 0, "Invalid key(s)");
    return keccak256(abi.encodePacked(key1, key2));
  }

_getKey

function _getKey(bytes32 key1, bytes32 key2, bytes32 key3) private pure
returns(bytes32)

Arguments

Name Type Description
key1 bytes32
key2 bytes32
key3 bytes32
Source Code
function _getKey(
    bytes32 key1,
    bytes32 key2,
    bytes32 key3
  ) private pure returns (bytes32) {
    require(key1 > 0 && key2 > 0 && key3 > 0, "Invalid key(s)");
    return keccak256(abi.encodePacked(key1, key2, key3));
  }

_getKey

function _getKey(bytes32 key, address account) private pure
returns(bytes32)

Arguments

Name Type Description
key bytes32
account address
Source Code
function _getKey(bytes32 key, address account) private pure returns (bytes32) {
    require(key > 0 && account != address(0), "Invalid key(s)");
    return keccak256(abi.encodePacked(key, account));
  }

_getKey

function _getKey(bytes32 key1, bytes32 key2, address account) private pure
returns(bytes32)

Arguments

Name Type Description
key1 bytes32
key2 bytes32
account address
Source Code
function _getKey(
    bytes32 key1,
    bytes32 key2,
    address account
  ) private pure returns (bytes32) {
    require(key1 > 0 && key2 > 0 && account != address(0), "Invalid key(s)");
    return keccak256(abi.encodePacked(key1, key2, account));
  }

Contracts