Saffron Position NFT

Introduction

Saffron Position NFT representing Junior Tranche deposits and lock time

Miscellaneous State Variables

Source Code

Type
Visibility
Name
Description

address

public

pool

Address of Saffron pool that owns this NFT

address

public

insurance_fund

Address of Saffron insurance fund

uint256

public

next_id

NFT tokenId counter

mapping(uint256=>uint256)

public

tranche

NFT(tokenID) variable: Tranche

mapping(uint256=>uint256)

public

balance

NFT(tokenID) variable: User's balance in this tranche LP

mapping(uint256=>uint256)

public

principal

NFT(tokenID) variable: Principal when user enters pool

mapping(uint256=>uint256)

public

expiration

NFT(tokenID) variable: Expiration date when NFT is unfrozen

Constructor

Source Code

constructor(string memory name_, string memory symbol_) ERC721(name_, symbol_)
Type
Name
Description

string

name_

Name of position NFTs

string

symbol_

Symbol for position NFTs

renew()

Source Code

DEPRECATED

function renew(uint256 token_id) external
Type
Name
Description

uint256

token_id

Position NFT ID to be checked

burn()

Source Code

Burn Position NFT as part of a withdrawal

function burn(uint256 token_id) external
Type
Name
Description

uint256

token_id

Position NFT ID to be burned

begin_unfreeze()

Source Code

Begin to unfreeze an NFT so it may be withdrawn

function begin_unfreeze(address user, uint256 token_id) external
Type
Name
Description

address

user

Address of user attempting to unfreeze

uint256

token_id

Position NFT ID to be unfrozen

set_insurance_fund()

Source Code

Set a new Saffron Insurance Fund to provide coverage

function set_insurance_fund(address to) external
Type
Name
Description

uint256

token_id

Position NFT ID to be burned

baseURI()

Source Code

NFT Metadata baseURI

function baseURI() external

tokenURI()

Source Code

NFT metadata tokenURI

function tokenURI(uint256 token_id) external
Type
Name
Description

uint256

token_id

Position NFT ID to be checked

Last updated

Was this helpful?