stx

package
v1.0.0-rc12 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2019 License: GPL-3.0 Imports: 13 Imported by: 16

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfirmOut_Z

func ConfirmOut_Z(deInfo *cpt.InfoDesc, out_z *Out_Z) (e error)

Types

type BuyShareCmd

type BuyShareCmd struct {
	Value utils.U256
	Vote  keys.PKr
	Pool  *keys.Uint256 `rlp:"nil"`
}

func (*BuyShareCmd) Asset

func (self *BuyShareCmd) Asset() (ret assets.Asset)

func (*BuyShareCmd) ToHash

func (self *BuyShareCmd) ToHash() (ret keys.Uint256)

type ClosePoolCmd

type ClosePoolCmd struct {
	None byte
}

func (*ClosePoolCmd) ToHash

func (self *ClosePoolCmd) ToHash() (ret keys.Uint256)

type ContractCmd

type ContractCmd struct {
	Asset assets.Asset
	To    *keys.PKr `rlp:"nil"`
	Data  []byte
}

func (*ContractCmd) ToHash

func (self *ContractCmd) ToHash() (ret keys.Uint256)

type DescCmd

type DescCmd struct {
	BuyShare   *BuyShareCmd   `rlp:"nil"`
	RegistPool *RegistPoolCmd `rlp:"nil"`
	ClosePool  *ClosePoolCmd  `rlp:"nil"`
	Contract   *ContractCmd   `rlp:"nil"`
	// contains filtered or unexported fields
}

func (*DescCmd) Count

func (self *DescCmd) Count() int

func (*DescCmd) OutAsset

func (self *DescCmd) OutAsset() *assets.Asset

func (*DescCmd) ToAssetCC

func (self *DescCmd) ToAssetCC() *keys.Uint256

func (*DescCmd) ToHash

func (self *DescCmd) ToHash() (ret keys.Uint256)

func (*DescCmd) ToPkr

func (self *DescCmd) ToPkr() *keys.PKr

func (*DescCmd) Valid

func (self *DescCmd) Valid() bool

type Desc_O

type Desc_O struct {
	Ins  []In_S
	Outs []Out_O
}

func (*Desc_O) ToHash

func (self *Desc_O) ToHash() (ret keys.Uint256)

func (*Desc_O) ToHash_for_gen

func (self *Desc_O) ToHash_for_gen() (ret keys.Uint256)

func (*Desc_O) ToHash_for_sign

func (self *Desc_O) ToHash_for_sign() (ret keys.Uint256)

type Desc_Z

type Desc_Z struct {
	Ins  []In_Z
	Outs []Out_Z
}

func (*Desc_Z) ToHash

func (self *Desc_Z) ToHash() (ret keys.Uint256)

func (*Desc_Z) ToHash_for_gen

func (self *Desc_Z) ToHash_for_gen() (ret keys.Uint256)

func (*Desc_Z) ToHash_for_sign

func (self *Desc_Z) ToHash_for_sign() (ret keys.Uint256)

type In_O

type In_O struct {
	Root keys.Uint256
	Sign keys.Uint512
}

func (In_O) MarshalText

func (ino In_O) MarshalText() ([]byte, error)

func (*In_O) ToHash

func (self *In_O) ToHash() (ret keys.Uint256)

func (*In_O) ToHash_for_gen

func (self *In_O) ToHash_for_gen() (ret keys.Uint256)

func (*In_O) ToHash_for_sign

func (self *In_O) ToHash_for_sign() (ret keys.Uint256)

type In_S

type In_S struct {
	Root keys.Uint256
	Nil  keys.Uint256
	Sign keys.Uint512
}

func (*In_S) ToHash

func (self *In_S) ToHash() (ret keys.Uint256)

func (*In_S) ToHash_for_gen

func (self *In_S) ToHash_for_gen() (ret keys.Uint256)

func (*In_S) ToHash_for_sign

func (self *In_S) ToHash_for_sign() (ret keys.Uint256)

type In_Z

type In_Z struct {
	Anchor  keys.Uint256
	Nil     keys.Uint256
	Trace   keys.Uint256
	AssetCM keys.Uint256
	Proof   cpt.Proof
}

func (*In_Z) ToHash

func (self *In_Z) ToHash() (ret keys.Uint256)

func (*In_Z) ToHash_for_sign

func (self *In_Z) ToHash_for_sign() (ret keys.Uint256)

type Out_O

type Out_O struct {
	Addr  keys.PKr
	Asset assets.Asset
	Memo  keys.Uint512
	// contains filtered or unexported fields
}

func (*Out_O) Clone

func (self *Out_O) Clone() (ret Out_O)

func (*Out_O) ToAssetCC

func (self *Out_O) ToAssetCC() keys.Uint256

func (*Out_O) ToHash

func (self *Out_O) ToHash() (ret keys.Uint256)

func (*Out_O) ToHash_for_gen

func (self *Out_O) ToHash_for_gen() (ret keys.Uint256)

func (*Out_O) ToHash_for_sign

func (self *Out_O) ToHash_for_sign() (ret keys.Uint256)

func (Out_O) ToRef

func (this Out_O) ToRef() (ret *Out_O)

type Out_Z

type Out_Z struct {
	AssetCM keys.Uint256
	OutCM   keys.Uint256
	RPK     keys.Uint256
	EInfo   cpt.Einfo
	PKr     keys.PKr
	Proof   cpt.Proof
}

func (*Out_Z) Clone

func (self *Out_Z) Clone() (ret Out_Z)

func (*Out_Z) ToHash

func (self *Out_Z) ToHash() (ret keys.Uint256)

func (*Out_Z) ToHash_for_gen

func (self *Out_Z) ToHash_for_gen() (ret keys.Uint256)

func (*Out_Z) ToHash_for_sign

func (self *Out_Z) ToHash_for_sign() (ret keys.Uint256)

func (Out_Z) ToRef

func (this Out_Z) ToRef() (ret *Out_Z)

type PkgClose

type PkgClose struct {
	Id   keys.Uint256
	Sign keys.Uint512
}

func (*PkgClose) Clone

func (self *PkgClose) Clone() (ret PkgClose)

func (*PkgClose) ToHash

func (self *PkgClose) ToHash() (ret keys.Uint256)

func (*PkgClose) ToHash_for_gen

func (self *PkgClose) ToHash_for_gen() (ret keys.Uint256)

func (*PkgClose) ToHash_for_sign

func (self *PkgClose) ToHash_for_sign() (ret keys.Uint256)

func (PkgClose) ToRef

func (this PkgClose) ToRef() (ret *PkgClose)

type PkgCreate

type PkgCreate struct {
	Id    keys.Uint256
	PKr   keys.PKr
	Pkg   pkg.Pkg_Z
	Proof cpt.Proof
}

func (*PkgCreate) Clone

func (self *PkgCreate) Clone() (ret PkgCreate)

func (*PkgCreate) ToHash

func (self *PkgCreate) ToHash() (ret keys.Uint256)

func (*PkgCreate) ToHash_for_gen

func (self *PkgCreate) ToHash_for_gen() (ret keys.Uint256)

func (*PkgCreate) ToHash_for_sign

func (self *PkgCreate) ToHash_for_sign() (ret keys.Uint256)

func (PkgCreate) ToRef

func (this PkgCreate) ToRef() (ret *PkgCreate)

type PkgDesc_Z

type PkgDesc_Z struct {
	Create   *PkgCreate   `rlp:"nil"`
	Transfer *PkgTransfer `rlp:"nil"`
	Close    *PkgClose    `rlp:"nil"`
}

func (*PkgDesc_Z) Clone

func (self *PkgDesc_Z) Clone() (ret PkgDesc_Z)

func (*PkgDesc_Z) Count

func (self *PkgDesc_Z) Count() int

func (*PkgDesc_Z) ToHash

func (self *PkgDesc_Z) ToHash() (ret keys.Uint256)

func (*PkgDesc_Z) ToHash_for_gen

func (self *PkgDesc_Z) ToHash_for_gen() (ret keys.Uint256)

func (*PkgDesc_Z) ToHash_for_sign

func (self *PkgDesc_Z) ToHash_for_sign() (ret keys.Uint256)

func (PkgDesc_Z) ToRef

func (this PkgDesc_Z) ToRef() (ret *PkgDesc_Z)

func (*PkgDesc_Z) Valid

func (self *PkgDesc_Z) Valid() bool

type PkgTransfer

type PkgTransfer struct {
	Id   keys.Uint256
	PKr  keys.PKr
	Sign keys.Uint512
}

func (*PkgTransfer) Clone

func (self *PkgTransfer) Clone() (ret PkgTransfer)

func (*PkgTransfer) ToHash

func (self *PkgTransfer) ToHash() (ret keys.Uint256)

func (*PkgTransfer) ToHash_for_gen

func (self *PkgTransfer) ToHash_for_gen() (ret keys.Uint256)

func (*PkgTransfer) ToHash_for_sign

func (self *PkgTransfer) ToHash_for_sign() (ret keys.Uint256)

func (PkgTransfer) ToRef

func (this PkgTransfer) ToRef() (ret *PkgTransfer)

type RegistPoolCmd

type RegistPoolCmd struct {
	Value   utils.U256
	Vote    keys.PKr
	FeeRate uint32
}

func (*RegistPoolCmd) Asset

func (self *RegistPoolCmd) Asset() (ret assets.Asset)

func (*RegistPoolCmd) ToHash

func (self *RegistPoolCmd) ToHash() (ret keys.Uint256)

type T

type T struct {
	Ehash    keys.Uint256
	From     keys.PKr
	Fee      assets.Token
	Sign     keys.Uint512
	Bcr      keys.Uint256
	Bsign    keys.Uint512
	Desc_Z   Desc_Z
	Desc_O   Desc_O
	Desc_Pkg PkgDesc_Z
	Desc_Cmd DescCmd
	// contains filtered or unexported fields
}

func (*T) DecodeRLP

func (b *T) DecodeRLP(s *rlp.Stream) error

func (*T) EncodeRLP

func (b *T) EncodeRLP(w io.Writer) error

EncodeRLP serializes b into the Ethereum RLP block format.

func (*T) ToFeeCC

func (self *T) ToFeeCC() keys.Uint256

func (*T) ToHash

func (self *T) ToHash() (ret keys.Uint256)

func (*T) ToHash_for_gen

func (self *T) ToHash_for_gen() (ret keys.Uint256)

func (*T) ToHash_for_sign

func (self *T) ToHash_for_sign() (ret keys.Uint256)

type ZtxVersion_0

type ZtxVersion_0 struct {
	Ehash    keys.Uint256
	From     keys.PKr
	Fee      assets.Token
	Sign     keys.Uint512
	Bcr      keys.Uint256
	Bsign    keys.Uint512
	Desc_Z   Desc_Z
	Desc_O   Desc_O
	Desc_Pkg PkgDesc_Z
}

type ZtxVersion_1

type ZtxVersion_1 struct {
	BuyShare   *BuyShareCmd   `rlp:"nil"`
	RegistPool *RegistPoolCmd `rlp:"nil"`
	ClosePool  *ClosePoolCmd  `rlp:"nil"`
	Contract   *ContractCmd   `rlp:"nil"`
}

Jump to

Keyboard shortcuts

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