protocol

package
v1.0.58 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: AGPL-3.0 Imports: 3 Imported by: 4

Documentation

Overview

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Package protocol implements the Secure Connection protocol

Index

Constants

View Source
const (
	// ProtocolID is the protocol ID for the Secure Connection protocol
	ProtocolID = 0xB

	// MethodRegister is the method ID for the method Register
	MethodRegister = 0x1

	// MethodRequestConnectionData is the method ID for the method RequestConnectionData
	MethodRequestConnectionData = 0x2

	// MethodRequestURLs is the method ID for the method RequestURLs
	MethodRequestURLs = 0x3

	// MethodRegisterEx is the method ID for the method RegisterEx
	MethodRegisterEx = 0x4

	// MethodTestConnectivity is the method ID for the method TestConnectivity
	MethodTestConnectivity = 0x5

	// MethodUpdateURLs is the method ID for the method UpdateURLs
	MethodUpdateURLs = 0x6

	// MethodReplaceURL is the method ID for the method ReplaceURL
	MethodReplaceURL = 0x7

	// MethodSendReport is the method ID for the method SendReport
	MethodSendReport = 0x8
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Protocol added in v1.0.45

type Protocol struct {
	Server *nex.Server
	// contains filtered or unexported fields
}

Protocol stores all the RMC method handlers for the Secure Connection protocol and listens for requests

func NewProtocol added in v1.0.45

func NewProtocol(server *nex.Server) *Protocol

NewProtocol returns a new Secure Connection protocol

func (*Protocol) HandlePacket added in v1.0.45

func (protocol *Protocol) HandlePacket(packet nex.PacketInterface)

HandlePacket sends the packet to the correct RMC method handler

func (*Protocol) Register added in v1.0.45

func (protocol *Protocol) Register(handler func(err error, packet nex.PacketInterface, callID uint32, vecMyURLs []*nex.StationURL) uint32)

Register sets the Register handler function

func (*Protocol) RegisterEx added in v1.0.45

func (protocol *Protocol) RegisterEx(handler func(err error, packet nex.PacketInterface, callID uint32, vecMyURLs []*nex.StationURL, hCustomData *nex.DataHolder) uint32)

RegisterEx sets the RegisterEx handler function

func (*Protocol) ReplaceURL added in v1.0.45

func (protocol *Protocol) ReplaceURL(handler func(err error, packet nex.PacketInterface, callID uint32, target *nex.StationURL, url *nex.StationURL) uint32)

ReplaceURL sets the ReplaceURL handler function

func (*Protocol) RequestConnectionData added in v1.0.45

func (protocol *Protocol) RequestConnectionData(handler func(err error, packet nex.PacketInterface, callID uint32, cidTarget uint32, pidTarget uint32) uint32)

RequestConnectionData sets the RequestConnectionData handler function

func (*Protocol) RequestURLs added in v1.0.45

func (protocol *Protocol) RequestURLs(handler func(err error, packet nex.PacketInterface, callID uint32, cidTarget uint32, pidTarget uint32) uint32)

RequestURLs sets the RequestURLs handler function

func (*Protocol) SendReport added in v1.0.45

func (protocol *Protocol) SendReport(handler func(err error, packet nex.PacketInterface, callID uint32, reportID uint32, reportData []byte) uint32)

SendReport sets the SendReport handler function

func (*Protocol) Setup added in v1.0.45

func (protocol *Protocol) Setup()

Setup initializes the protocol

func (*Protocol) TestConnectivity added in v1.0.45

func (protocol *Protocol) TestConnectivity(handler func(err error, packet nex.PacketInterface, callID uint32) uint32)

TestConnectivity sets the TestConnectivity handler function

func (*Protocol) UpdateURLs added in v1.0.45

func (protocol *Protocol) UpdateURLs(handler func(err error, packet nex.PacketInterface, callID uint32, vecMyURLs []*nex.StationURL) uint32)

UpdateURLs sets the UpdateURLs handler function

Directories

Path Synopsis
Package protocol implements the Nintendo Badge Arcade Secure Connection protocol
Package protocol implements the Nintendo Badge Arcade Secure Connection protocol

Jump to

Keyboard shortcuts

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