MaxPageSize
untyped bigintValue
(50 <untyped> bigint)
idWidth
untyped bigintValue
(12 <untyped> bigint)
priceWidth
untyped bigint// types.MaxUnitPrice has 16 digits
Value
(16 <untyped> bigint)
listing
typeValue
v1.listing
listings
v0.Tree// padded id -> \*listing
- OID
- 0a9cb3…ac82:4
listings details
byToken
v0.Tree// cid:tid -> id
- OID
- 0a9cb3…ac82:6
byToken details
byCollection
v0.Tree// cid:paddedPrice:paddedID -> id (floor = first key)
- OID
- 0a9cb3…ac82:8
byCollection details
bySeller
v0.Tree// seller:paddedID -> id
- OID
- 0a9cb3…ac82:10
bySeller details
nextID
int64Value
1
selfPath
string// captured in init for read paths without a cur
Value
"gno.land/r/g19dzk54hhsdc3gllpksuj6gu4a3e6fl8cr6rn4w/minhwa2/market/v1"
init.10
func()- OID
- 0a9cb3…ac82:13
init.10 details
List
func(cid string, tid string, price int64) stringList offers a token of a Final collection at price (ugnot). The caller must own it and have approved this realm (Approve or SetApprovalForAll in core). A stale listing of the same token is replaced.
- OID
- 0a9cb3…ac82:15
List details
UpdatePrice
func(listingID string, price int64)UpdatePrice changes the price of a live listing; Buy's expectedPrice protects buyers from a change racing their purchase (RA M-10).
- OID
- 0a9cb3…ac82:16
UpdatePrice details
Cancel
func(listingID string)Cancel removes the caller's listing. Never paused.
- OID
- 0a9cb3…ac82:17
Cancel details
CancelStale
func(listingID string)CancelStale lets anyone remove a listing that can no longer be bought.
- OID
- 0a9cb3…ac82:18
CancelStale details
Buy
func(listingID string, expectedPrice int64)Buy pays exactly expectedPrice for the listing (excess attached ugnot is refunded). Order: checks, remove the listing, move the token, then pay — protocol fee to the treasury, royalty to the collection's sub-treasury (then distributed to its payees), the rest to the seller. I-4: fee + royalty + seller + refund == attached.
- OID
- 0a9cb3…ac82:19
Buy details
Listing
func(listingID string) string- OID
- 0a9cb3…ac82:20
Listing details
ListingOf
func(cid string, tid string) stringListingOf is the live listing of a token as JSON, or "null".
- OID
- 0a9cb3…ac82:21
ListingOf details
ActiveListing
func(cid string, tid string) (id string, price int64, ok bool)ActiveListing is the typed read for other realms: the live listing of a token, if any.
- OID
- 0a9cb3…ac82:22
ActiveListing details
ListingsByCollection
func(cid string, offset int64, limit int64) stringListingsByCollection lists by ascending price. Stale listings are included with "live":false so pages stay stable; frontends hide them.
- OID
- 0a9cb3…ac82:23
ListingsByCollection details
ListingsBySeller
func(seller .uverse.address, offset int64, limit int64) string- OID
- 0a9cb3…ac82:24
ListingsBySeller details
Floor
func(cid string) int64Floor is the lowest live price in cid, or -1. It inspects at most MaxPageSize listings from the cheapest, so spam cannot make it unbounded.
- OID
- 0a9cb3…ac82:25
Floor details
Render
func(path string) string- OID
- 0a9cb3…ac82:26
Render details
live
func(l *v1.listing, market .uverse.address) boollive: still owned by the seller, not moved since listing, still approved.
- OID
- 0a9cb3…ac82:27
live details
approved
func(cid string, tid string, owner .uverse.address, market .uverse.address) bool- OID
- 0a9cb3…ac82:28
approved details
remove
func(l *v1.listing, reason string)remove deletes a listing and its indexes; closed listings are not kept (RA L-6), the "Cancelled" event (reason sold/cancelled/stale) is the record.
- OID
- 0a9cb3…ac82:29
remove details
listPrefix
func(index *v0.Tree, prefix string, offset int64, limit int64) string- OID
- 0a9cb3…ac82:30
listPrefix details
writeListing
func(w *v1.JSONWriter, l *v1.listing)- OID
- 0a9cb3…ac82:31
writeListing details
writeListingLive
func(w *v1.JSONWriter, l *v1.listing, isLive bool)- OID
- 0a9cb3…ac82:32
writeListingLive details
mustListing
func(id int64) *v1.listing- OID
- 0a9cb3…ac82:33
mustListing details
assertSeller
func(l *v1.listing)- OID
- 0a9cb3…ac82:34
assertSeller details
assertTradeOpen
func()- OID
- 0a9cb3…ac82:35
assertTradeOpen details
assertPrice
func(price int64)- OID
- 0a9cb3…ac82:36
assertPrice details
received
func() int64- OID
- 0a9cb3…ac82:37
received details
assertNoDeposit
func()- OID
- 0a9cb3…ac82:38
assertNoDeposit details
pay
func(to .uverse.address, amount int64)- OID
- 0a9cb3…ac82:39
pay details
tokenKey
func(cid string, tid string) string- OID
- 0a9cb3…ac82:40
tokenKey details
collectionKey
func(l *v1.listing) string- OID
- 0a9cb3…ac82:41
collectionKey details
sellerKey
func(l *v1.listing) string- OID
- 0a9cb3…ac82:42
sellerKey details
prefixEnd
func(prefix string) stringprefixEnd is the smallest key greater than every key with this prefix (prefixes here end in ':', so bump it to ';').
- OID
- 0a9cb3…ac82:43
prefixEnd details
parseID
func(s string) int64- OID
- 0a9cb3…ac82:44
parseID details
itoa
func(n int64) string- OID
- 0a9cb3…ac82:45
itoa details
selfAddress
func() .uverse.address- OID
- 0a9cb3…ac82:46