jrpc

package
v1.0.75 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ERR_SERVER_NOT_FOUND = "RPC server not found"
	ERR_METHOD_NOT_FOUND = "Method not found"
)

Variables

This section is empty.

Functions

func Call

func Call(method string, data et.Json) (et.Item, error)

* * Call * @param method string * @param data et.Json * @return et.Item * @return error *

func Close

func Close()

func GetRouters

func GetRouters() (et.Items, error)

* * GetRouters * @return et.Items * @return error *

func Load

func Load()

* * load *

func Mount

func Mount(services any, packageName string) error

* * Mount * @param host string * @param port int * @param service any * @param packageName string *

func StartServer

func StartServer()

* * NewServer *

func UnMount

func UnMount() error

* * UnMount * @return error *

Types

type Router

type Router struct {
	PackageName string             `json:"packageName"`
	Host        string             `json:"host"`
	Port        int                `json:"port"`
	Solvers     map[string]et.Json `json:"routes"`
	// contains filtered or unexported fields
}

func GetSolver

func GetSolver(method string) (*Router, error)

* * GetSolver * @param method string * @return *Solver * @return error *

func (*Router) Save

func (r *Router) Save() error

* * Save * @return error *

Jump to

Keyboard shortcuts

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