parser

package
v0.2.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 29, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NameBRC721Deploy = "brc-721-deploy"
	NameBRC721Mint   = "brc-721-mint"
	NameBRC721Update = "brc-721-update"
)
View Source
const (
	BRC721 = "brc-721"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BRC721Deploy

type BRC721Deploy struct {
	P       string         `json:"p"`
	Op      string         `json:"op"`
	Tick    string         `json:"tick"`
	Max     string         `json:"max"`
	BaseURI *string        `json:"buri"`
	Meta    *BRC721Meta    `json:"meta"`
	Sig     *sig.DeploySig `json:"sig"`
}

func (BRC721Deploy) Validate

func (m BRC721Deploy) Validate() bool

type BRC721DeployParser

type BRC721DeployParser struct {
}

func (*BRC721DeployParser) Name

func (p *BRC721DeployParser) Name() string

func (*BRC721DeployParser) Parse

func (p *BRC721DeployParser) Parse(data []byte) (interface{}, bool, error)

type BRC721Meta

type BRC721Meta struct {
	Name        string                   `json:"name"`
	Description string                   `json:"description"`
	Image       string                   `json:"image"`
	Attributes  []map[string]interface{} `json:"attributes"`
}

type BRC721Mint

type BRC721Mint struct {
	P    string       `json:"p"`
	Op   string       `json:"op"`
	Tick string       `json:"tick"`
	Sig  *sig.MintSig `json:"sig"`
}

func (BRC721Mint) Validate

func (m BRC721Mint) Validate() bool

type BRC721MintParser

type BRC721MintParser struct {
}

func (*BRC721MintParser) Name

func (p *BRC721MintParser) Name() string

func (*BRC721MintParser) Parse

func (p *BRC721MintParser) Parse(data []byte) (interface{}, bool, error)

type BRC721Update

type BRC721Update struct {
	P       string      `json:"p"`
	Op      string      `json:"op"`
	Tick    string      `json:"tick"`
	BaseURI *string     `json:"buri"`
	Meta    *BRC721Meta `json:"meta"`
}

func (BRC721Update) Validate

func (m BRC721Update) Validate() bool

type BRC721UpdateParser

type BRC721UpdateParser struct {
}

func (*BRC721UpdateParser) Name

func (p *BRC721UpdateParser) Name() string

func (*BRC721UpdateParser) Parse

func (p *BRC721UpdateParser) Parse(data []byte) (interface{}, bool, error)

type Parser

type Parser interface {
	Parse(content []byte) (interface{}, bool, error)
	Name() string
}

func ParserList

func ParserList() []Parser

type Validator

type Validator interface {
	Validate() bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL