dispatch

package
v0.1.11 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handle

func Handle(method string, request []byte) ([]byte, error)

Handle is the shipped C ABI method switch (JSON in / JSON envelope out).

func SetCaller

func SetCaller(c Caller)

SetCaller installs the C ABI host callback.

func SetEndpoints

func SetEndpoints(e endpointOverride)

SetEndpoints overrides Huawei base URLs (tests).

func SetHTTPClient

func SetHTTPClient(c *http.Client)

SetHTTPClient replaces the fallback net/http client (tests).

Types

type Caller

type Caller interface {
	Call(method string, payload []byte) ([]byte, error)
}

Caller is the CPA host RPC (host.http.do, host.auth.save, host.stream.emit, ...).

type Config

type Config struct {
	CallbackHost     string
	CallbackPort     int
	CallbackPath     string
	BenefitAutoClaim bool
}

Config is plugin-owned configuration under plugins.configs.codearts.

Jump to

Keyboard shortcuts

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