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: 6 Imported by: 0

Documentation

Overview

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Package protocol implements the ServiceItemWiiSportsClub protocol

Index

Constants

View Source
const (
	// ProtocolID is the Protocol ID for the Service Item (Wii Sports Club) protocol
	ProtocolID = 0x77

	// MethodHello is the method ID for the Hello method
	MethodHello = 0x1

	// MethodHTTPGetRequest is the method ID for the HTTPGetRequest method
	MethodHTTPGetRequest = 0x2

	// MethodHTTPGetResponse is the method ID for the HTTPGetResponse method
	MethodHTTPGetResponse = 0x3

	// MethodPurchaseServiceItemRequest is the method ID for the PurchaseServiceItemRequest method
	MethodPurchaseServiceItemRequest = 0x4

	// MethodPurchaseServiceItemResponse is the method ID for the PurchaseServiceItemResponse method
	MethodPurchaseServiceItemResponse = 0x5

	// MethodListServiceItemRequest is the method ID for the ListServiceItemRequest method
	MethodListServiceItemRequest = 0x6

	// MethodListServiceItemResponse is the method ID for the ListServiceItemResponse method
	MethodListServiceItemResponse = 0x7

	// MethodGetBalanceRequest is the method ID for the GetBalanceRequest method
	MethodGetBalanceRequest = 0x8

	// MethodGetBalanceResponse is the method ID for the GetBalanceResponse method
	MethodGetBalanceResponse = 0x9

	// MethodGetPrepurchaseInfoRequest is the method ID for the GetPrepurchaseInfoRequest method
	MethodGetPrepurchaseInfoRequest = 0xA

	// MethodGetPrepurchaseInfoResponse is the method ID for the GetPrepurchaseInfoResponse method
	MethodGetPrepurchaseInfoResponse = 0xB

	// MethodGetServiceItemRightRequest is the method ID for the GetServiceItemRightRequest method
	MethodGetServiceItemRightRequest = 0xC

	// MethodGetServiceItemRightResponse is the method ID for the GetServiceItemRightResponse method
	MethodGetServiceItemRightResponse = 0xD

	// MethodGetPurchaseHistoryRequest is the method ID for the GetPurchaseHistoryRequest method
	MethodGetPurchaseHistoryRequest = 0xE

	// MethodGetPurchaseHistoryResponse is the method ID for the GetPurchaseHistoryResponse method
	MethodGetPurchaseHistoryResponse = 0xF

	// MethodGetNotice is the method ID for the GetNotice method
	MethodGetNotice = 0x10

	// MethodUpdateAndGetTicketInfo is the method ID for the UpdateAndGetTicketInfo method
	MethodUpdateAndGetTicketInfo = 0x11

	// MethodLoadUserInfo is the method ID for the LoadUserInfo method
	MethodLoadUserInfo = 0x12

	// MethodSaveUserInfo is the method ID for the SaveUserInfo method
	MethodSaveUserInfo = 0x13

	// MethodStartChallenge is the method ID for the StartChallenge method
	MethodStartChallenge = 0x14

	// MethodEndChallenge is the method ID for the EndChallenge method
	MethodEndChallenge = 0x15

	// MethodRequestTicketRestoration is the method ID for the RequestTicketRestoration method
	MethodRequestTicketRestoration = 0x16
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Protocol

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

Protocol stores all the RMC method handlers for the Service Item (Wii Sports Club) protocol and listens for requests Embeds the Service Item protocol

func NewProtocol

func NewProtocol(server *nex.Server) *Protocol

NewProtocol returns a new ServiceItemWiiSportsClub protocol

func (*Protocol) EndChallenge

func (protocol *Protocol) EndChallenge(handler func(err error, packet nex.PacketInterface, callID uint32, endChallengeParam *service_item_wii_sports_club_types.ServiceItemEndChallengeParam) uint32)

EndChallenge sets the EndChallenge handler function

func (*Protocol) GetBalanceRequest

func (protocol *Protocol) GetBalanceRequest(handler func(err error, packet nex.PacketInterface, callID uint32, getBalanceParam *service_item_wii_sports_club_types.ServiceItemGetBalanceParam) uint32)

GetBalanceRequest sets the GetBalanceRequest handler function

func (*Protocol) GetBalanceResponse

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

GetBalanceResponse sets the GetBalanceResponse handler function

func (*Protocol) GetNotice

func (protocol *Protocol) GetNotice(handler func(err error, packet nex.PacketInterface, callID uint32, getNoticeParam *service_item_wii_sports_club_types.ServiceItemGetNoticeParam) uint32)

GetNotice sets the GetNotice handler function

func (*Protocol) GetPrepurchaseInfoRequest

func (protocol *Protocol) GetPrepurchaseInfoRequest(handler func(err error, packet nex.PacketInterface, callID uint32, getPrepurchaseInfoParam *service_item_wii_sports_club_types.ServiceItemGetPrepurchaseInfoParam) uint32)

GetPrepurchaseInfoRequest sets the GetPrepurchaseInfoRequest handler function

func (*Protocol) GetPrepurchaseInfoResponse

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

GetPrepurchaseInfoResponse sets the GetPrepurchaseInfoResponse handler function

func (*Protocol) GetPurchaseHistoryRequest

func (protocol *Protocol) GetPurchaseHistoryRequest(handler func(err error, packet nex.PacketInterface, callID uint32, getPurchaseHistoryParam *service_item_wii_sports_club_types.ServiceItemGetPurchaseHistoryParam) uint32)

GetPurchaseHistoryRequest sets the GetPurchaseHistoryRequest handler function

func (*Protocol) GetPurchaseHistoryResponse

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

GetPurchaseHistoryResponse sets the GetPurchaseHistoryResponse handler function

func (*Protocol) GetServiceItemRightRequest

func (protocol *Protocol) GetServiceItemRightRequest(handler func(err error, packet nex.PacketInterface, callID uint32, getServiceItemRightParam *service_item_wii_sports_club_types.ServiceItemGetServiceItemRightParam) uint32)

GetServiceItemRightRequest sets the GetServiceItemRightRequest handler function

func (*Protocol) GetServiceItemRightResponse

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

GetServiceItemRightResponse sets the GetServiceItemRightResponse handler function

func (*Protocol) HTTPGetRequest

func (protocol *Protocol) HTTPGetRequest(handler func(err error, packet nex.PacketInterface, callID uint32, url *service_item_wii_sports_club_types.ServiceItemHTTPGetParam) uint32)

HTTPGetRequest sets the HTTPGetRequest handler function

func (*Protocol) HTTPGetResponse

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

HTTPGetResponse sets the HTTPGetResponse handler function

func (*Protocol) HandlePacket

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

HandlePacket sends the packet to the correct RMC method handler

func (*Protocol) Hello

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

Hello sets the Hello handler function

func (*Protocol) ListServiceItemRequest

func (protocol *Protocol) ListServiceItemRequest(handler func(err error, packet nex.PacketInterface, callID uint32, listServiceItemParam *service_item_wii_sports_club_types.ServiceItemListServiceItemParam) uint32)

ListServiceItemRequest sets the ListServiceItemRequest handler function

func (*Protocol) ListServiceItemResponse

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

ListServiceItemResponse sets the ListServiceItemResponse handler function

func (*Protocol) LoadUserInfo

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

LoadUserInfo sets the LoadUserInfo handler function

func (*Protocol) PurchaseServiceItemRequest

func (protocol *Protocol) PurchaseServiceItemRequest(handler func(err error, packet nex.PacketInterface, callID uint32, purchaseServiceItemParam *service_item_wii_sports_club_types.ServiceItemPurchaseServiceItemParam) uint32)

PurchaseServiceItemRequest sets the PurchaseServiceItemRequest handler function

func (*Protocol) PurchaseServiceItemResponse

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

PurchaseServiceItemResponse sets the PurchaseServiceItemResponse handler function

func (*Protocol) RequestTicketRestoration

func (protocol *Protocol) RequestTicketRestoration(handler func(err error, packet nex.PacketInterface, callID uint32, requestTicketRestorationParam *service_item_wii_sports_club_types.ServiceItemRequestTicketRestorationParam) uint32)

RequestTicketRestoration sets the RequestTicketRestoration handler function

func (*Protocol) SaveUserInfo

func (protocol *Protocol) SaveUserInfo(handler func(err error, packet nex.PacketInterface, callID uint32, userInfo *service_item_wii_sports_club_types.ServiceItemUserInfo) uint32)

SaveUserInfo sets the SaveUserInfo handler function

func (*Protocol) Setup

func (protocol *Protocol) Setup()

Setup initializes the protocol

func (*Protocol) StartChallenge

func (protocol *Protocol) StartChallenge(handler func(err error, packet nex.PacketInterface, callID uint32, startChallengeParam *service_item_wii_sports_club_types.ServiceItemStartChallengeParam) uint32)

StartChallenge sets the StartChallenge handler function

func (*Protocol) UpdateAndGetTicketInfo

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

UpdateAndGetTicketInfo sets the UpdateAndGetTicketInfo handler function

Directories

Path Synopsis
Package types implements all the types used by the Service Item (Wii Sports Club) protocol
Package types implements all the types used by the Service Item (Wii Sports Club) protocol

Jump to

Keyboard shortcuts

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