mirror of
https://github.com/Mezeporta/Erupe.git
synced 2025-12-16 17:05:03 +01:00
Autogenerate packet type stubs
This commit is contained in:
28
network/mhfpacket/mhfpacket.go
Normal file
28
network/mhfpacket/mhfpacket.go
Normal file
@@ -0,0 +1,28 @@
|
||||
package mhfpacket
|
||||
|
||||
import (
|
||||
"github.com/Andoryuuta/Erupe/network"
|
||||
"github.com/Andoryuuta/byteframe"
|
||||
)
|
||||
|
||||
// Parser is the interface that wraps the Parse method.
|
||||
type Parser interface {
|
||||
Parse(bf *byteframe.ByteFrame) error
|
||||
}
|
||||
|
||||
// Builder is the interface that wraps the Build method.
|
||||
type Builder interface {
|
||||
Build(bf *byteframe.ByteFrame) error
|
||||
}
|
||||
|
||||
// Opcoder is the interface that wraps the Opcode method.
|
||||
type Opcoder interface {
|
||||
Opcode() network.PacketID
|
||||
}
|
||||
|
||||
// MHFPacket is the interface that groups the Parse, Build, and Opcode methods.
|
||||
type MHFPacket interface {
|
||||
Parser
|
||||
Builder
|
||||
Opcoder
|
||||
}
|
||||
Reference in New Issue
Block a user