package
module
Version:
v1.0.0
Opens a new window with list of versions in this module.
Published: Jun 18, 2025
License: Apache-2.0
Opens a new window with license information.
Imports: 15
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
NYX
version 1.0
golang微服务框架
支持http、tcp、ws(websocket)、rpc 和 cli 服务模式
Installation
Quick Start
Documentation
¶
View Source
const (
SYSTEM_VERSION = "1.0"
SERVER_HTTP = "http"
SERVER_RPC = "rpc"
SERVER_TCP = "tcp"
SERVER_WS = "ws"
SERVER_CLI = "cli"
)
func AddApi(c interface{}, group ...string)
添加http 方法对应的controller实例, 支持分组; 默认url路径: controller/action, 分组时路径: group/controller/action
func AddCli(c interface{})
添加cli 方法对应的controller实例
func AddRpc(c interface{}, group ...string)
添加rpc 方法对应的controller实例
type Nyx struct {
Mode []string
}
func (this *Nyx) RunCli()
func (this *Nyx) RunHttp()
func (this *Nyx) RunRpc()
func (this *Nyx) RunTcp()
func (this *Nyx) RunWebsocket()
Source Files
¶
Directories
¶
cmd
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Click to show internal directories.
Click to hide internal directories.