github.com/annchain/OG@v0.0.9/types/token/token.go (about) 1 package token 2 3 import "fmt" 4 5 type TokenID int32 6 7 const ( 8 KeyPrefix string = "tkID" 9 ) 10 11 // token id 12 var ( 13 OGTokenID = int32(0) 14 ) 15 16 func TokenTrieKey(tokenID int32) []byte { 17 keyStr := KeyPrefix + fmt.Sprintf("%d", tokenID) 18 return []byte(keyStr) 19 } 20 21 func LatestTokenIDTrieKey() []byte { 22 keyStr := KeyPrefix + "latest" 23 return []byte(keyStr) 24 }