model

package
v0.2.0-alpha.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MarshalDate

func MarshalDate(date Date) graphql.Marshaler

func MarshalHashIndex

func MarshalHashIndex(hashIndex HashIndex) graphql.Marshaler

Types

type Block

type Block struct {
	Hash      string `json:"hash"`
	Raw       string `json:"raw"`
	Timestamp Date   `json:"timestamp"`
	Height    *int   `json:"height"`
	Size      int64  `json:"size"`
	TxCount   int    `json:"tx_count"`
}

type Date

type Date time.Time

func UnmarshalDate

func UnmarshalDate(v interface{}) (Date, error)

type DoubleSpend

type DoubleSpend struct {
	Hash      string `json:"hash"`
	Index     uint32 `json:"index"`
	Timestamp Date   `json:"timestamp"`
}

type Follow

type Follow struct {
	TxHash        string `json:"tx_hash"`
	Address       string `json:"address"`
	FollowAddress string `json:"follow_address"`
	Unfollow      bool   `json:"unfollow"`
}

type HashIndex

type HashIndex struct {
	Hash  string
	Index uint32
}

func UnmarshalHashIndex

func UnmarshalHashIndex(v interface{}) (HashIndex, error)

type Like

type Like struct {
	TxHash     string `json:"tx_hash"`
	Address    string `json:"address"`
	PostTxHash string `json:"post_tx_hash"`
	Tip        int64  `json:"tip"`
}

type Lock

type Lock struct {
	Address string `json:"address"`
	Balance int64  `json:"balance"`
}

type Post

type Post struct {
	TxHash  string `json:"tx_hash"`
	Address string `json:"address"`
	Text    string `json:"text"`
}

type Profile

type Profile struct {
	Address string      `json:"address"`
	Name    *SetName    `json:"name"`
	Profile *SetProfile `json:"profile"`
	Pic     *SetPic     `json:"pic"`
}

type Room

type Room struct {
	Name string `json:"name"`
}

type RoomFollow

type RoomFollow struct {
	Name     string `json:"name"`
	Address  string `json:"address"`
	Unfollow bool   `json:"unfollow"`
	TxHash   string `json:"tx_hash"`
}

type SetName

type SetName struct {
	TxHash  string `json:"tx_hash"`
	Address string `json:"address"`
	Name    string `json:"name"`
}

type SetPic

type SetPic struct {
	TxHash  string `json:"tx_hash"`
	Address string `json:"address"`
	Pic     string `json:"pic"`
}

type SetProfile

type SetProfile struct {
	TxHash  string `json:"tx_hash"`
	Address string `json:"address"`
	Text    string `json:"text"`
}

type Tx

type Tx struct {
	Hash  string `json:"hash"`
	Index uint32 `json:"index"`
	Raw   string `json:"raw"`
	Seen  Date   `json:"seen"`
}

type TxInput

type TxInput struct {
	Hash      string `json:"hash"`
	Index     uint32 `json:"index"`
	PrevHash  string `json:"prev_hash"`
	PrevIndex uint32 `json:"prev_index"`
	Script    string `json:"script"`
}

type TxLost

type TxLost struct {
	Hash string `json:"hash"`
}

type TxOutput

type TxOutput struct {
	Hash   string `json:"hash"`
	Index  uint32 `json:"index"`
	Amount int64  `json:"amount"`
	Script string `json:"script"`
}

type TxSuspect

type TxSuspect struct {
	Hash string `json:"hash"`
}

Jump to

Keyboard shortcuts

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