example

package
v0.0.0-...-95b87ed Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// contains filtered or unexported fields
}

func ConstructAppInstance

func ConstructAppInstance(ledger ledger.PeerLedger) *App

func (*App) Init

func (app *App) Init(initialBalances map[string]int) (*common.Envelope, error)

func (*App) QueryBalances

func (app *App) QueryBalances(accounts []string) ([]int, error)

func (*App) TransferFunds

func (app *App) TransferFunds(fromAccount string, toAccount string, transferAmt int) (*common.Envelope, error)

type Committer

type Committer struct {
	// contains filtered or unexported fields
}

func ConstructCommitter

func ConstructCommitter(ledger ledger.PeerLedger) *Committer

func (*Committer) Commit

func (c *Committer) Commit(rawBlock *common.Block) error

type Consenter

type Consenter struct {
	// contains filtered or unexported fields
}

func ConstructConsenter

func ConstructConsenter() *Consenter

func (*Consenter) ConstructBlock

func (c *Consenter) ConstructBlock(transactions ...*common.Envelope) *common.Block

type Marble

type Marble struct {
	Name  string `json:"asset_name"`
	Color string `json:"color"`
	Size  int    `json:"size"`
	User  string `json:"owner"`
	Rev   string `json:"_rev"`
	Txid  string `json:"txid"`
}

type MarbleApp

type MarbleApp struct {
	// contains filtered or unexported fields
}

func ConstructMarbleAppInstance

func ConstructMarbleAppInstance(ledger ledger.PeerLedger) *MarbleApp

func (*MarbleApp) CreateMarble

func (marbleApp *MarbleApp) CreateMarble(args []string) (*common.Envelope, error)

func (*MarbleApp) TransferMarble

func (marbleApp *MarbleApp) TransferMarble(args []string) (*common.Envelope, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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