Documentation ¶
Index ¶
- Constants
- func CheckTimeouts(timeouts *rpc.HTTPTimeouts)
- func CreateWallet(password, name, mnemonic, hdPath string) string
- func GetWalletAddress() error
- func GetWallets(walletAddress string, password string) ([]fs.FileInfo, error)
- func Login(walletAddress, password string) error
- func NewHTTPHandlerStack(srv http.Handler, cors []string, vhosts []string) http.Handler
- func RegisterApis(apis []rpc.API, modules []string, srv *rpc.Server, exposeAll bool) error
- func RpcLogService() *rpcLogService
- func ShowMonitor()
- func Start()
- func StartDumpTrafficLog()
- func StartHTTPEndpoint(endpoint string, timeouts rpc.HTTPTimeouts, handler http.Handler) (*http.Server, net.Addr, error)
- func StopDumpTrafficLog()
- func StopMonitor()
- func TerminalAPI() *terminalCmd
- func Wallets()
- type CmdResult
- type CpuInfo
- type HdInfo
- type LogMsg
- type MemInfo
- type SingleCpuInfo
- type TrafficDumpInfo
- type TrafficInfo
Constants ¶
View Source
const (
DefaultMsg = "Request Accepted"
)
Variables ¶
This section is empty.
Functions ¶
func CheckTimeouts ¶ added in v0.5.0
func CheckTimeouts(timeouts *rpc.HTTPTimeouts)
CheckTimeouts ensures that timeout values are meaningful
func GetWallets ¶ added in v0.6.0
func NewHTTPHandlerStack ¶ added in v0.5.0
NewHTTPHandlerStack returns wrapped http-related handlers
func RegisterApis ¶ added in v0.5.0
RegisterApis checks the given modules' availability, generates an allowlist based on the allowed modules, and then registers all of the APIs exposed by the services.
func RpcLogService ¶ added in v0.5.0
func RpcLogService() *rpcLogService
func StartDumpTrafficLog ¶ added in v0.5.0
func StartDumpTrafficLog()
func StartHTTPEndpoint ¶ added in v0.5.0
func StartHTTPEndpoint(endpoint string, timeouts rpc.HTTPTimeouts, handler http.Handler) (*http.Server, net.Addr, error)
StartHTTPEndpoint starts the HTTP RPC endpoint.
func StopDumpTrafficLog ¶ added in v0.5.0
func StopDumpTrafficLog()
func TerminalAPI ¶ added in v0.5.0
func TerminalAPI() *terminalCmd
Types ¶
type CpuInfo ¶ added in v0.5.0
type CpuInfo struct { CpuInfos []SingleCpuInfo `json:"cpu_infos"` CpuUsedPercent float64 `json:"cpu_used_percent"` }
func NewCpuInfo ¶ added in v0.5.0
func NewCpuInfo(cpuInfos []SingleCpuInfo, cpuUsedPercent float64) CpuInfo
type HdInfo ¶ added in v0.5.0
type MemInfo ¶ added in v0.5.0
type SingleCpuInfo ¶ added in v0.5.0
type SingleCpuInfo struct { CpuModelName string `json:"cpu_model_name"` CpuCores int32 `json:"cpu_cores"` }
func NewSingleCpuInfo ¶ added in v0.5.0
func NewSingleCpuInfo(cpuModelName string, cpuCores int32) SingleCpuInfo
type TrafficDumpInfo ¶ added in v0.5.0
type TrafficDumpInfo struct { MemInfo MemInfo `json:"mem_info"` CpuInfo CpuInfo `json:"cpu_info"` HdInfo HdInfo `json:"hd_info"` TrafficInfo TrafficInfo `json:"traffic_info"` }
func NewTrafficDumpInfo ¶ added in v0.5.0
func NewTrafficDumpInfo(memInfo MemInfo, cpuInfo CpuInfo, hdInfo HdInfo, trafficInfo TrafficInfo) TrafficDumpInfo
type TrafficInfo ¶ added in v0.5.0
type TrafficInfo struct { TrafficInbound uint64 `json:"traffic_inbound"` TrafficOutbound uint64 `json:"traffic_outbound"` }
func NewTrafficInfo ¶ added in v0.5.0
func NewTrafficInfo(trafficInbound uint64, trafficOutbound uint64) TrafficInfo
Click to show internal directories.
Click to hide internal directories.