atp

package
v0.0.0-...-545087f Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HeaderSize  = 8
	MaxDataSize = atalk.DDPMaxDataSize - HeaderSize // 578
)

Variables

This section is empty.

Functions

func UnmarshalPacket

func UnmarshalPacket(data []byte) (any, error)

Types

type TRel

type TRel struct {
	// Control information: 1 1 0 0 0 0 0 0
	TransactionID uint16
}

func (*TRel) Marshal

func (p *TRel) Marshal() ([]byte, error)

type TReq

type TReq struct {
	// Control information: 0 1 (XO) 0 0 (Timeout indicator)
	ExactlyOnce          bool
	TRelTimeoutIndicator uint8 // only if XO is set
	Bitmap               uint8
	TransactionID        uint16
	UserBytes            [4]byte
	Data                 []byte
}

func (*TReq) Marshal

func (p *TReq) Marshal() ([]byte, error)

type TResp

type TResp struct {
	// Control information: 1 0 0 (EOM) (STS) 0 0 0
	EndOfMessage          bool
	SendTransactionStatus bool
	Sequence              uint8
	TransactionID         uint16
	UserBytes             [4]byte
	Data                  []byte
}

func (*TResp) Marshal

func (p *TResp) Marshal() ([]byte, error)

Jump to

Keyboard shortcuts

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