Lockup

Git Source

Namespace for the structs used in both {SablierV2LockupLinear} and {SablierV2LockupDynamic}.

Structs

Amounts

Struct encapsulating the deposit, withdrawn, and refunded amounts, all denoted in units of the asset's decimals.

Because the deposited and the withdrawn amount are often read together, declaring them in the same slot saves gas.

struct Amounts {
    uint128 deposited;
    uint128 withdrawn;
    uint128 refunded;
}

Properties

NameTypeDescription
depositeduint128The initial amount deposited in the stream, net of fees.
withdrawnuint128The cumulative amount withdrawn from the stream.
refundeduint128The amount refunded to the sender. Unless the stream was canceled, this is always zero.