mobile

package
v1.2.32 Latest Latest
Warning

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

Go to latest
Published: May 19, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetBaseURL added in v1.2.30

func GetBaseURL() string

GetBaseURL 返回 Flutter WebView 应使用的本地地址。

func GetPort added in v1.2.30

func GetPort() int

GetPort 返回当前服务端口。

func GetServerInfo added in v1.2.30

func GetServerInfo() string

GetServerInfo 返回当前嵌入式服务的运行信息。

func Start

func Start(configJSON string) string

Start 启动嵌入式 Comigo 服务,供 gomobile bind 生成的 Android 包直接调用。

func Stop added in v1.2.30

func Stop() string

Stop 停止嵌入式 Comigo 服务。

Types

type StartConfig added in v1.2.30

type StartConfig struct {
	Port                      int      `json:"port"`
	DisableLAN                bool     `json:"disableLAN"`
	EnableUpload              bool     `json:"enableUpload"`
	ReadOnlyMode              bool     `json:"readOnlyMode"`
	EnableDatabase            bool     `json:"enableDatabase"`
	EnablePlugin              bool     `json:"enablePlugin"`
	Debug                     bool     `json:"debug"`
	Language                  string   `json:"language"`
	Username                  string   `json:"username"`
	Password                  string   `json:"password"`
	Host                      string   `json:"host"`
	BasePath                  string   `json:"basePath"`
	CacheDir                  string   `json:"cacheDir"`
	ConfigDir                 string   `json:"configDir"`
	StoreUrls                 []string `json:"storeUrls"`
	AutoRescanIntervalMinutes int      `json:"autoRescanIntervalMinutes"`
	ScanOnStart               bool     `json:"scanOnStart"`
	WaitReadyTimeoutSeconds   int      `json:"waitReadyTimeoutSeconds"`
}

type StartResult added in v1.2.30

type StartResult struct {
	Success   bool     `json:"success"`
	Running   bool     `json:"running"`
	BaseURL   string   `json:"baseUrl,omitempty"`
	HealthURL string   `json:"healthUrl,omitempty"`
	Port      int      `json:"port,omitempty"`
	StoreUrls []string `json:"storeUrls,omitempty"`
	Error     string   `json:"error,omitempty"`
}

Jump to

Keyboard shortcuts

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