modes

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Overview

---------------------------------------------------------------------------------------------

  • Copyright (c) IBAX. All rights reserved.
  • See LICENSE in the project root for license information. *--------------------------------------------------------------------------------------------

---------------------------------------------------------------------------------------------

  • Copyright (c) IBAX. All rights reserved.
  • See LICENSE in the project root for license information. *--------------------------------------------------------------------------------------------

---------------------------------------------------------------------------------------------

  • Copyright (c) IBAX. All rights reserved.
  • See LICENSE in the project root for license information. *--------------------------------------------------------------------------------------------

---------------------------------------------------------------------------------------------

  • Copyright (c) IBAX. All rights reserved.
  • See LICENSE in the project root for license information. *--------------------------------------------------------------------------------------------

Index

Constants

This section is empty.

Variables

View Source
var ErrDiffKey = errors.New("Different keys")

Functions

func GetClientTxPreprocessor

func GetClientTxPreprocessor() types.ClientTxPreprocessor

func GetDaemonLoader

func GetDaemonLoader() types.DaemonFactory

func GetEcosystemGetter

func GetEcosystemGetter() types.EcosystemGetter

func GetSmartContractRunner

func GetSmartContractRunner() types.SmartContractRunner

GetSmartContractRunner returns mode boundede implementation of SmartContractRunner

func RegisterJsonRPCRoutes

func RegisterJsonRPCRoutes(next http.Handler) http.Handler

func RegisterRoutes

func RegisterRoutes() http.Handler

Types

type BCDaemonFactory

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

BCDaemonFactory allow load blockchain daemons

func (BCDaemonFactory) GetDaemonsList

func (BCDaemonFactory) GetDaemonsList() []string

func (BCDaemonFactory) Load

func (l BCDaemonFactory) Load(ctx context.Context) error

Load loads blockchain daemons

type BCEcosystemGetter

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

func (BCEcosystemGetter) GetEcosystemLookup

func (g BCEcosystemGetter) GetEcosystemLookup() ([]int64, []string, error)

func (BCEcosystemGetter) GetEcosystemName

func (ng BCEcosystemGetter) GetEcosystemName(id int64) (string, error)

func (BCEcosystemGetter) ValidateId

func (v BCEcosystemGetter) ValidateId(formEcosysID, clientEcosysID int64, le *log.Entry) (int64, error)

type BlockchainSCRunner

type BlockchainSCRunner struct{}

BlockchainSCRunner implementls SmartContractRunner for blockchain mode

func (BlockchainSCRunner) RunContract

func (runner BlockchainSCRunner) RunContract(data, hash []byte, keyID, tnow int64, le *log.Entry) error

RunContract runs smart contract on blockchain mode

type CLBDaemonFactory

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

CLBDaemonFactory allows load clb daemons

func (CLBDaemonFactory) GetDaemonsList

func (CLBDaemonFactory) GetDaemonsList() []string

func (CLBDaemonFactory) Load

func (l CLBDaemonFactory) Load(ctx context.Context) error

Load loads clb daemons

type CLBEcosystemGetter

type CLBEcosystemGetter struct{}

func (CLBEcosystemGetter) GetEcosystemLookup

func (g CLBEcosystemGetter) GetEcosystemLookup() ([]int64, []string, error)

func (CLBEcosystemGetter) GetEcosystemName

func (ng CLBEcosystemGetter) GetEcosystemName(id int64) (string, error)

func (CLBEcosystemGetter) ValidateId

func (CLBEcosystemGetter) ValidateId(id, clientID int64, le *log.Entry) (int64, error)

type CLBSCRunner

type CLBSCRunner struct{}

CLBSCRunner implementls SmartContractRunner for clb mode

func (CLBSCRunner) RunContract

func (runner CLBSCRunner) RunContract(data, hash []byte, keyID, tnow int64, le *log.Entry) error

RunContract runs smart contract on clb mode

type ClbTxPreprocessor

type ClbTxPreprocessor struct{}

func (ClbTxPreprocessor) ProcessClientTxBatches

func (p ClbTxPreprocessor) ProcessClientTxBatches(txData [][]byte, key int64, le *log.Entry) ([]string, error)

type JsonRpcRoutes

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

func (*JsonRpcRoutes) ServeHTTP

func (s *JsonRpcRoutes) ServeHTTP(w http.ResponseWriter, r *http.Request)

type SNDaemonFactory

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

SNDaemonFactory allows load subnode daemons

func (SNDaemonFactory) GetDaemonsList

func (SNDaemonFactory) GetDaemonsList() []string

func (SNDaemonFactory) Load

func (l SNDaemonFactory) Load(ctx context.Context) error

Load loads subnode daemons

Jump to

Keyboard shortcuts

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