mobile

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2021 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Version

func Version() string

Types

type Node

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

func NewNode

func NewNode(o *Options) (*Node, error)

func (*Node) Stop

func (n *Node) Stop() error

type Options

type Options struct {
	// api setting
	APIPort        int
	DebugAPIPort   int
	EnableDebugAPI bool

	// p2p setup
	NetworkID      int64 // default type uint64
	P2PPort        int
	WelcomeMessage string

	// kademlia
	BinMaxPeers   int
	LightMaxPeers int

	// cache size
	CacheCapacity int64 // default type uint64

	// node bootstrap
	BootNodes      []byte // default type []string
	EnableDevNode  bool
	EnableFullNode bool

	// oracle setting
	ContractAddress string
	ChainEndpoint   string

	// security
	Password string
	KeysPath string
	DataPath string

	// leveldb opts
	BlockCacheCapacity     int64 // default type uint64
	OpenFilesLimit         int64 // default type uint64
	WriteBufferSize        int64 // default type uint64
	DisableSeeksCompaction bool

	// misc
	Verbosity string
}

Options represents the collection of configuration values to fine tune the aurora node embedded into a mobile process. The available values are a subset of the entire API provided by aurora to reduce the maintenance surface and dev complexity.

func (Options) APIAddr

func (o Options) APIAddr(c *node.Options)

func (Options) Bootnodes

func (o Options) Bootnodes(c *node.Options)

func (Options) DBBlockCacheCapacity

func (o Options) DBBlockCacheCapacity(c *node.Options)

func (Options) DBDisableSeeksCompaction

func (o Options) DBDisableSeeksCompaction(c *node.Options)

func (Options) DBOpenFilesLimit

func (o Options) DBOpenFilesLimit(c *node.Options)

func (Options) DBWriteBufferSize

func (o Options) DBWriteBufferSize(c *node.Options)

func (Options) DataDir

func (o Options) DataDir(c *node.Options)

func (Options) DebugAPIAddr

func (o Options) DebugAPIAddr(c *node.Options)

func (Options) FullNode

func (o Options) FullNode(c *node.Options)

func (Options) IsDev

func (o Options) IsDev(c *node.Options)

func (Options) KadBinMaxPeers

func (o Options) KadBinMaxPeers(c *node.Options)

func (Options) LightNodeMaxPeers

func (o Options) LightNodeMaxPeers(c *node.Options)

func (Options) OracleContractAddress

func (o Options) OracleContractAddress(c *node.Options)

func (Options) OracleEndpoint

func (o Options) OracleEndpoint(c *node.Options)

Jump to

Keyboard shortcuts

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