Storage

Git Source

Author: Cujo

Stores System-level Carbonmark state.

Structs

CreditListing

Stores the detailed data for currently valid listings within this struct

struct CreditListing {
    address account;
    address token;
    uint256 tokenId;
    uint256 originalAmount;
    uint256 remainingAmount;
    uint256 unitPrice;
    uint256 minFillAmount;
    uint256 deadline;
    TokenType tokenType;
}

Properties

NameTypeDescription
accountaddressThe ethereum account that owns this listing
tokenaddressThe ethereum address of the token listed
tokenIduint256
originalAmountuint256
remainingAmountuint256The remaining unfilled amount on this listing
unitPriceuint256The unit price in USDC, expected to be six decimals
minFillAmountuint256The minimum amount needed to fill any part of this listing
deadlineuint256The last UNIX timestamp for which this listing is valid
tokenTypeTokenType

Enums

CreditProtocol

Enum providing values to check against when a new token is being listed

enum CreditProtocol {
    UNKNOWN,
    TOUCAN,
    C3,
    ICR,
    CMARK
}

TokenType

enum TokenType {
    UNKNOWN,
    ERC20,
    ERC1155
}