Skip to content Search Apps Documentation Source Content File Folder Download Copy Actions State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

Community realm. Read the code first. Community realm, deployed by its author. Read the code before you interact or send coins.

shop state

Back to all declarations

maxImageLen

untyped bigint

Value

(200 <untyped> bigint)

maxTidLen

untyped bigint

Value

(64 <untyped> bigint)

saleCap

untyped bigint

Value

(100 <untyped> bigint)

pageMax

untyped bigint

Value

(50 <untyped> bigint)

tokenSeq

v0.ID

Value

<zero>

creator

.uverse.address

Value

<gnolang.StringValue>

ready

bool

Value

true

saleN

int

Value

0

listing

type

Value

shop.listing

sale

type

Value

shop.sale

Init

func(name string, symbol string)

Init creates the collection once. The caller is the creator and can mint.

Open
OID
0b6124…5997:118
Init details

Inspect func

Grant

func(who .uverse.address)

Grant lets who mint. Only the creator can call it.

Open
OID
0b6124…5997:120
Grant details

Inspect func

Revoke

func(who .uverse.address)

Revoke removes a minter. Only the creator can call it.

Open
OID
0b6124…5997:121
Revoke details

Inspect func

canMint

func(caller .uverse.address) bool
Open
OID
0b6124…5997:122
canMint details

Inspect func

Mint

func(tid string, name string, image string)

Mint issues one token to the caller. image is an https URL.

Open
OID
0b6124…5997:123
Mint details

Inspect func

Transfer

func(to .uverse.address, tid string)

Transfer moves a token the caller owns.

Open
OID
0b6124…5997:124
Transfer details

Inspect func

requireUser

func() .uverse.address
Open
OID
0b6124…5997:126
requireUser details

Inspect func

parseTid

func(tid string) v0.TokenID
Open
OID
0b6124…5997:127
parseTid details

Inspect func

ownerOf

func(tid v0.TokenID) .uverse.address
Open
OID
0b6124…5997:130
ownerOf details

Inspect func

metaNameImage

func(tid v0.TokenID) (string, string)
Open
OID
0b6124…5997:131
metaNameImage details

Inspect func

page

func(offset int, limit int) (int, int)
Open
OID
0b6124…5997:132
page details

Inspect func

List

func(tid string, price int64)

List puts tid on sale for price ugnot. The token stays with the owner. A dead listing (the recorded seller no longer owns it) is replaced.

Open
OID
0b6124…5997:135
List details

Inspect func

Cancel

func(tid string)

Cancel removes the caller's listing, or a listing whose seller no longer owns the token.

Open
OID
0b6124…5997:137
Cancel details

Inspect func

Buy

func(tid string)

Buy pays the listing price in ugnot and takes the token. The attached send must be exactly the price, one ugnot coin.

Open
OID
0b6124…5997:138
Buy details

Inspect func

mustListing

func(id v0.TokenID) shop.listing
Open
OID
0b6124…5997:139
mustListing details

Inspect func

InfoJSON

func() string

InfoJSON is the collection header. ready is false until Init.

Open
OID
0b6124…5997:141
InfoJSON details

Inspect func

ListingsJSON

func(offset int, limit int) string

ListingsJSON returns one page of listings, oldest key first.

Open
OID
0b6124…5997:144
ListingsJSON details

Inspect func

ListingJSON

func(tid string) string

ListingJSON returns one listing or "null".

Open
OID
0b6124…5997:145
ListingJSON details

Inspect func

TokenJSON

func(tid string) string

TokenJSON returns one token, listed or not.

Open
OID
0b6124…5997:146
TokenJSON details

Inspect func

TokensJSON

func(owner .uverse.address, offset int, limit int) string

TokensJSON lists tokens owned by owner.

Open
OID
0b6124…5997:147
TokensJSON details

Inspect func

SalesJSON

func(offset int, limit int) string

SalesJSON returns the newest sales first.

Open
OID
0b6124…5997:148
SalesJSON details

Inspect func

lotJSON

func(tid string, lot shop.listing) string
Open
OID
0b6124…5997:149
lotJSON details

Inspect func
maxImageLen : untyped bigint =(200 <untyped> bigint)
maxTidLen : untyped bigint =(64 <untyped> bigint)
saleCap : untyped bigint =(100 <untyped> bigint)
pageMax : untyped bigint =(50 <untyped> bigint)
token : *v0.Token Inspect
ledger : *v0.PrivateLedger Inspect
metaView : *v0.Metadata Inspect
metaLed : *v0.Ledger Inspect
enumView : *v0.Enumerable Inspect
tokenSeq : v0.ID =<zero>
creator : .uverse.address =<gnolang.StringValue>
ready : bool =true
admins : v0.Tree Inspect
listings : v0.Tree Inspect
sales : [100]shop.sale Inspect
saleN : int =0
listing : type =shop.listing
sale : type =shop.sale
Init : func(name string, symbol string) Inspect
Grant : func(who .uverse.address) Inspect
Revoke : func(who .uverse.address) Inspect
canMint : func(caller .uverse.address) bool Inspect
Mint : func(tid string, name string, image string) Inspect
Transfer : func(to .uverse.address, tid string) Inspect
requireReady : func() Inspect
requireUser : func() .uverse.address Inspect
parseTid : func(tid string) v0.TokenID Inspect
httpsURL : func(s string) bool Inspect
ascii : func(s string) bool Inspect
ownerOf : func(tid v0.TokenID) .uverse.address Inspect
metaNameImage : func(tid v0.TokenID) (string, string) Inspect
page : func(offset int, limit int) (int, int) Inspect
quote : func(s string) string Inspect
i64 : func(n int64) string Inspect
List : func(tid string, price int64) Inspect
Cancel : func(tid string) Inspect
Buy : func(tid string) Inspect
mustListing : func(id v0.TokenID) shop.listing Inspect
pushSale : func(s shop.sale) Inspect
InfoJSON : func() string Inspect
adminsJSON : func() string Inspect
ListingsJSON : func(offset int, limit int) string Inspect
ListingJSON : func(tid string) string Inspect
TokenJSON : func(tid string) string Inspect
TokensJSON : func(owner .uverse.address, offset int, limit int) string Inspect
SalesJSON : func(offset int, limit int) string Inspect
lotJSON : func(tid string, lot shop.listing) string Inspect
boolJSON : func(v bool) string Inspect
join : func(parts []string) string Inspect
Render : func(path string) string Inspect