protocol

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2025 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MarshalRequest

func MarshalRequest(m mx.Message) ([]byte, error)

MarshalRequest 编码req数据包

func UnmarshalRequest

func UnmarshalRequest(b []byte) (mx.Message, *proto.BasePacket, error)

UnmarshalRequest 解码req数据包

func UnmarshalResponse

func UnmarshalResponse(bin []byte) (mx.Message, proto.Protocol, error)

UnmarshalResponse 解码rsp数据包

Types

type NetworkProtocolResponse

type NetworkProtocolResponse struct {
	Packet   string `json:"packet"`   // 包数据
	Protocol string `json:"protocol"` // 协议名称
}

func MarshalResponse

func MarshalResponse(m mx.Message) (*NetworkProtocolResponse, error)

MarshalResponse 编码rsp数据包

Directories

Path Synopsis
Code auto-generated by gucooing & Hiro420 DO NOT EDIT.
Code auto-generated by gucooing & Hiro420 DO NOT EDIT.

Jump to

Keyboard shortcuts

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