Skip to main content

ICoreAdjusted

Asset Tokenization Studio Team

ICoreAdjusted

Interface exposing time-adjusted ERC-20 decimal reads for the CoreAdjusted facet.

Complements ICore.decimals(), which always resolves to the current block timestamp. This interface allows callers to query what the effective decimal precision would be at an arbitrary point in time, accounting for any pending scheduled balance adjustments (ABAFs) that have not yet been triggered on-chain.

Methods​

decimalsAt​

function decimalsAt(uint256 _timestamp) external view returns (uint8)

Returns the effective token decimals at a given timestamp, simulating all pending scheduled balance adjustments (ABAFs) up to and including that timestamp.

Delegates to ERC20StorageWrapper.decimalsAdjustedAt. Adjustments with an executionDate strictly greater than _timestamp are excluded. No state mutation occurs; this is a pure simulation.

Parameters​

NameTypeDescription
_timestampuint256The Unix timestamp up to which pending ABAFs are simulated.

Returns​

NameTypeDescription
_0uint8The effective decimal precision of the token at the specified timestamp.

initializeCoreAdjusted​

function initializeCoreAdjusted() external nonpayable

Initialises the core adjusted capability on the token.

Callable once; subsequent calls revert with FacetAlreadyRegistered. Requires DEFAULT_ADMIN_ROLE. Called by the factory during deployment.

Events​

CoreAdjustedInitialized​

event CoreAdjustedInitialized()

Emitted once when the core adjusted capability is initialised on a token.

Fires exclusively from initializeCoreAdjusted.