| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- // contracts/Getters.sol
- // SPDX-License-Identifier: Apache 2
- pragma solidity ^0.8.0;
- import "./State.sol";
- contract Getters is State {
- function getGuardianSet(uint32 index) public view returns (Structs.GuardianSet memory) {
- return _state.guardianSets[index];
- }
- function getCurrentGuardianSetIndex() public view returns (uint32) {
- return _state.guardianSetIndex;
- }
- function getGuardianSetExpiry() public view returns (uint32) {
- return _state.guardianSetExpiry;
- }
- function governanceActionIsConsumed(bytes32 hash) public view returns (bool) {
- return _state.consumedGovernanceActions[hash];
- }
- function isInitialized(address impl) public view returns (bool) {
- return _state.initializedImplementations[impl];
- }
- function chainId() public view returns (uint16) {
- return _state.provider.chainId;
- }
- function evmChainId() public view returns (uint256) {
- return _state.evmChainId;
- }
- function isFork() public view returns (bool) {
- return evmChainId() != block.chainid;
- }
- function governanceChainId() public view returns (uint16){
- return _state.provider.governanceChainId;
- }
- function governanceContract() public view returns (bytes32){
- return _state.provider.governanceContract;
- }
- function messageFee() public view returns (uint256) {
- return _state.messageFee;
- }
- function nextSequence(address emitter) public view returns (uint64) {
- return _state.sequences[emitter];
- }
- }
|