Documentation ¶
Overview ¶
Package messages provides encoding/decoding feature of GTPv1 protocol.
Index ¶
- Constants
- Variables
- func Marshal(g Message) ([]byte, error)
- func NewHeaderFlags(v, p, e, s, n int) uint8
- func Serialize(m Message) ([]byte, error)
- type CreatePDPContextRequest
- func (c *CreatePDPContextRequest) DecodeFromBytes(b []byte) error
- func (c *CreatePDPContextRequest) Len() int
- func (c *CreatePDPContextRequest) Marshal() ([]byte, error)
- func (c *CreatePDPContextRequest) MarshalLen() int
- func (c *CreatePDPContextRequest) MarshalTo(b []byte) error
- func (c *CreatePDPContextRequest) MessageTypeName() string
- func (c *CreatePDPContextRequest) Serialize() ([]byte, error)
- func (c *CreatePDPContextRequest) SerializeTo(b []byte) error
- func (c *CreatePDPContextRequest) SetLength()
- func (c *CreatePDPContextRequest) TEID() uint32
- func (c *CreatePDPContextRequest) UnmarshalBinary(b []byte) error
- type CreatePDPContextResponse
- func (c *CreatePDPContextResponse) DecodeFromBytes(b []byte) error
- func (c *CreatePDPContextResponse) Len() int
- func (c *CreatePDPContextResponse) Marshal() ([]byte, error)
- func (c *CreatePDPContextResponse) MarshalLen() int
- func (c *CreatePDPContextResponse) MarshalTo(b []byte) error
- func (c *CreatePDPContextResponse) MessageTypeName() string
- func (c *CreatePDPContextResponse) Serialize() ([]byte, error)
- func (c *CreatePDPContextResponse) SerializeTo(b []byte) error
- func (c *CreatePDPContextResponse) SetLength()
- func (c *CreatePDPContextResponse) TEID() uint32
- func (c *CreatePDPContextResponse) UnmarshalBinary(b []byte) error
- type DeletePDPContextRequest
- func (d *DeletePDPContextRequest) DecodeFromBytes(b []byte) error
- func (d *DeletePDPContextRequest) Len() int
- func (d *DeletePDPContextRequest) Marshal() ([]byte, error)
- func (d *DeletePDPContextRequest) MarshalLen() int
- func (d *DeletePDPContextRequest) MarshalTo(b []byte) error
- func (d *DeletePDPContextRequest) MessageTypeName() string
- func (d *DeletePDPContextRequest) Serialize() ([]byte, error)
- func (d *DeletePDPContextRequest) SerializeTo(b []byte) error
- func (d *DeletePDPContextRequest) SetLength()
- func (d *DeletePDPContextRequest) TEID() uint32
- func (d *DeletePDPContextRequest) UnmarshalBinary(b []byte) error
- type DeletePDPContextResponse
- func (d *DeletePDPContextResponse) DecodeFromBytes(b []byte) error
- func (d *DeletePDPContextResponse) Len() int
- func (d *DeletePDPContextResponse) Marshal() ([]byte, error)
- func (d *DeletePDPContextResponse) MarshalLen() int
- func (d *DeletePDPContextResponse) MarshalTo(b []byte) error
- func (d *DeletePDPContextResponse) MessageTypeName() string
- func (d *DeletePDPContextResponse) Serialize() ([]byte, error)
- func (d *DeletePDPContextResponse) SerializeTo(b []byte) error
- func (d *DeletePDPContextResponse) SetLength()
- func (d *DeletePDPContextResponse) TEID() uint32
- func (d *DeletePDPContextResponse) UnmarshalBinary(b []byte) error
- type EchoRequest
- func (e *EchoRequest) DecodeFromBytes(b []byte) error
- func (e *EchoRequest) Len() int
- func (e *EchoRequest) Marshal() ([]byte, error)
- func (e *EchoRequest) MarshalLen() int
- func (e *EchoRequest) MarshalTo(b []byte) error
- func (e *EchoRequest) MessageTypeName() string
- func (e *EchoRequest) Serialize() ([]byte, error)
- func (e *EchoRequest) SerializeTo(b []byte) error
- func (e *EchoRequest) SetLength()
- func (e *EchoRequest) TEID() uint32
- func (e *EchoRequest) UnmarshalBinary(b []byte) error
- type EchoResponse
- func (e *EchoResponse) DecodeFromBytes(b []byte) error
- func (e *EchoResponse) Len() int
- func (e *EchoResponse) Marshal() ([]byte, error)
- func (e *EchoResponse) MarshalLen() int
- func (e *EchoResponse) MarshalTo(b []byte) error
- func (e *EchoResponse) MessageTypeName() string
- func (e *EchoResponse) Serialize() ([]byte, error)
- func (e *EchoResponse) SerializeTo(b []byte) error
- func (e *EchoResponse) SetLength()
- func (e *EchoResponse) TEID() uint32
- func (e *EchoResponse) UnmarshalBinary(b []byte) error
- type ErrorIndication
- func (e *ErrorIndication) DecodeFromBytes(b []byte) error
- func (e *ErrorIndication) Len() int
- func (e *ErrorIndication) Marshal() ([]byte, error)
- func (e *ErrorIndication) MarshalLen() int
- func (e *ErrorIndication) MarshalTo(b []byte) error
- func (e *ErrorIndication) MessageTypeName() string
- func (e *ErrorIndication) Serialize() ([]byte, error)
- func (e *ErrorIndication) SerializeTo(b []byte) error
- func (e *ErrorIndication) SetLength()
- func (e *ErrorIndication) TEID() uint32
- func (e *ErrorIndication) UnmarshalBinary(b []byte) error
- type Generic
- func (g *Generic) AddIE(ie ...*ies.IE)
- func (g *Generic) DecodeFromBytes(b []byte) error
- func (g *Generic) Len() int
- func (g *Generic) Marshal() ([]byte, error)
- func (g *Generic) MarshalLen() int
- func (g *Generic) MarshalTo(b []byte) error
- func (g *Generic) MessageTypeName() string
- func (g *Generic) Serialize() ([]byte, error)
- func (g *Generic) SerializeTo(b []byte) error
- func (g *Generic) SetLength()
- func (g *Generic) TEID() uint32
- func (g *Generic) UnmarshalBinary(b []byte) error
- type Header
- func (h *Header) DecodeFromBytes(b []byte) error
- func (h *Header) HasSequence() bool
- func (h *Header) Len() int
- func (h *Header) Marshal() ([]byte, error)
- func (h *Header) MarshalLen() int
- func (h *Header) MarshalTo(b []byte) error
- func (h *Header) MessageType() uint8
- func (h *Header) Sequence() uint16
- func (h *Header) Serialize() ([]byte, error)
- func (h *Header) SerializeTo(b []byte) error
- func (h *Header) SetLength()
- func (h *Header) SetSequenceNumber(seq uint16)
- func (h *Header) SetTEID(teid uint32)
- func (h *Header) String() string
- func (h *Header) UnmarshalBinary(b []byte) error
- func (h *Header) Version() int
- type Message
- type TPDU
- func (t *TPDU) Decapsulate() []byte
- func (t *TPDU) DecodeFromBytes(b []byte) error
- func (t *TPDU) Len() int
- func (t *TPDU) Marshal() ([]byte, error)
- func (t *TPDU) MarshalLen() int
- func (t *TPDU) MarshalTo(b []byte) error
- func (t *TPDU) MessageTypeName() string
- func (t *TPDU) Serialize() ([]byte, error)
- func (t *TPDU) SerializeTo(b []byte) error
- func (t *TPDU) SetLength()
- func (t *TPDU) TEID() uint32
- func (t *TPDU) UnmarshalBinary(b []byte) error
- type UpdatePDPContextRequest
- func (u *UpdatePDPContextRequest) DecodeFromBytes(b []byte) error
- func (u *UpdatePDPContextRequest) Len() int
- func (u *UpdatePDPContextRequest) Marshal() ([]byte, error)
- func (u *UpdatePDPContextRequest) MarshalLen() int
- func (u *UpdatePDPContextRequest) MarshalTo(b []byte) error
- func (u *UpdatePDPContextRequest) MessageTypeName() string
- func (u *UpdatePDPContextRequest) Serialize() ([]byte, error)
- func (u *UpdatePDPContextRequest) SerializeTo(b []byte) error
- func (u *UpdatePDPContextRequest) SetLength()
- func (u *UpdatePDPContextRequest) TEID() uint32
- func (u *UpdatePDPContextRequest) UnmarshalBinary(b []byte) error
- type UpdatePDPContextResponse
- func (u *UpdatePDPContextResponse) DecodeFromBytes(b []byte) error
- func (u *UpdatePDPContextResponse) Len() int
- func (u *UpdatePDPContextResponse) Marshal() ([]byte, error)
- func (u *UpdatePDPContextResponse) MarshalLen() int
- func (u *UpdatePDPContextResponse) MarshalTo(b []byte) error
- func (u *UpdatePDPContextResponse) MessageTypeName() string
- func (u *UpdatePDPContextResponse) Serialize() ([]byte, error)
- func (u *UpdatePDPContextResponse) SerializeTo(b []byte) error
- func (u *UpdatePDPContextResponse) SetLength()
- func (u *UpdatePDPContextResponse) TEID() uint32
- func (u *UpdatePDPContextResponse) UnmarshalBinary(b []byte) error
- type VersionNotSupported
- func (v *VersionNotSupported) DecodeFromBytes(b []byte) error
- func (v *VersionNotSupported) Len() int
- func (v *VersionNotSupported) Marshal() ([]byte, error)
- func (v *VersionNotSupported) MarshalLen() int
- func (v *VersionNotSupported) MarshalTo(b []byte) error
- func (v *VersionNotSupported) MessageTypeName() string
- func (v *VersionNotSupported) Serialize() ([]byte, error)
- func (v *VersionNotSupported) SerializeTo(b []byte) error
- func (v *VersionNotSupported) SetLength()
- func (v *VersionNotSupported) TEID() uint32
- func (v *VersionNotSupported) UnmarshalBinary(b []byte) error
Constants ¶
const ( MsgTypeEchoRequest uint8 MsgTypeEchoResponse MsgTypeVersionNotSupported MsgTypeNodeAliveRequest MsgTypeNodeAliveResponse MsgTypeRedirectionRequest MsgTypeRedirectionResponse MsgTypeCreatePDPContextRequest // 16 MsgTypeCreatePDPContextResponse MsgTypeUpdatePDPContextRequest MsgTypeUpdatePDPContextResponse MsgTypeDeletePDPContextRequest MsgTypeDeletePDPContextResponse MsgTypeCreateAAPDPContextRequest MsgTypeCreateAAPDPContextResponse MsgTypeDeleteAAPDPContextRequest MsgTypeDeleteAAPDPContextResponse MsgTypeErrorIndication MsgTypePDUNotificationRequest MsgTypePDUNotificationResponse MsgTypePDUNotificationRejectRequest MsgTypePDUNotificationRejectResponse MsgTypeSendRoutingInfoRequest MsgTypeSendRoutingInfoResponse MsgTypeFailureReportRequest MsgTypeFailureReportResponse MsgTypeNoteMSPresentRequest MsgTypeNoteMSPresentResponse MsgTypeIdentificationRequest // 48 MsgTypeIdentificationResponse MsgTypeSGSNContextRequest MsgTypeSGSNContextResponse MsgTypeSGSNContextAcknowledge MsgTypeDataRecordTransferRequest uint8 = 240 MsgTypeDataRecordTransferResponse uint8 = 241 MsgTypeTPDU uint8 = 255 )
Message Type definitions.
Variables ¶
var ( ErrInvalidLength = errors.New("got invalid length ") ErrTooShortToMarshal = errors.New("too short to serialize") ErrTooShortToParse = errors.New("too short to decode as GTPv1") ErrInvalidMessageType = errors.New("got invalid message type") )
Error definitions.
Functions ¶
func Marshal ¶ added in v0.4.2
Marshal returns the byte sequence generated from a Message instance. Better to use MarshalXxx instead if you know the name of message to be serialized.
func NewHeaderFlags ¶
NewHeaderFlags returns a Header Flag built by its components given as arguments.
Types ¶
type CreatePDPContextRequest ¶
type CreatePDPContextRequest struct { *Header IMSI *ies.IE RAI *ies.IE Recovery *ies.IE SelectionMode *ies.IE TEIDDataI *ies.IE TEIDCPlane *ies.IE NSAPI *ies.IE LinkedNSAPI *ies.IE ChargingCharacteristics *ies.IE TraceReference *ies.IE TraceType *ies.IE EndUserAddress *ies.IE APN *ies.IE PCO *ies.IE SGSNAddressForSignalling *ies.IE SGSNAddressForUserTraffic *ies.IE MSISDN *ies.IE QoSProfile *ies.IE TFT *ies.IE TriggerID *ies.IE OMCIdentity *ies.IE CommonFlags *ies.IE APNRestriction *ies.IE RATType *ies.IE UserLocationInformation *ies.IE MSTimeZone *ies.IE IMEI *ies.IE CAMELChargingInformationContainer *ies.IE AdditionalTraceInfo *ies.IE CorrelationID *ies.IE EvolvedARPI *ies.IE ExtendedCommonFlags *ies.IE UCI *ies.IE APNAMBR *ies.IE SignallingPriorityIndication *ies.IE CNOperatorSelectionEntity *ies.IE MappedUEUsageType *ies.IE UPFunctionSelectionIndicationFlags *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
CreatePDPContextRequest is a CreatePDPContextRequest Header and its IEs above.
func DecodeCreatePDPContextRequest ¶
func DecodeCreatePDPContextRequest(b []byte) (*CreatePDPContextRequest, error)
DecodeCreatePDPContextRequest decodes bytes as CreatePDPContextRequest.
DEPRECATED: use ParseCreatePDPContextRequest instead.
func NewCreatePDPContextRequest ¶
func NewCreatePDPContextRequest(teid uint32, seq uint16, ie ...*ies.IE) *CreatePDPContextRequest
NewCreatePDPContextRequest creates a new GTPv1 CreatePDPContextRequest.
func ParseCreatePDPContextRequest ¶ added in v0.4.2
func ParseCreatePDPContextRequest(b []byte) (*CreatePDPContextRequest, error)
ParseCreatePDPContextRequest decodes a given byte sequence as a CreatePDPContextRequest.
func (*CreatePDPContextRequest) DecodeFromBytes ¶
func (c *CreatePDPContextRequest) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as CreatePDPContextRequest.
DEPRECATED: use CreatePDPContextRequest.UnmarshalBinary instead.
func (*CreatePDPContextRequest) Len ¶
func (c *CreatePDPContextRequest) Len() int
Len returns the actual length of CreatePDPContextRequest.
DEPRECATED: use CreatePDPContextRequest.MarshalLen instead.
func (*CreatePDPContextRequest) Marshal ¶ added in v0.4.2
func (c *CreatePDPContextRequest) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a CreatePDPContextRequest.
func (*CreatePDPContextRequest) MarshalLen ¶ added in v0.4.2
func (c *CreatePDPContextRequest) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*CreatePDPContextRequest) MarshalTo ¶ added in v0.4.2
func (c *CreatePDPContextRequest) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*CreatePDPContextRequest) MessageTypeName ¶
func (c *CreatePDPContextRequest) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*CreatePDPContextRequest) Serialize ¶
func (c *CreatePDPContextRequest) Serialize() ([]byte, error)
Serialize serializes CreatePDPContextRequest into bytes.
DEPRECATED: use CreatePDPContextRequest.Marshal instead.
func (*CreatePDPContextRequest) SerializeTo ¶
func (c *CreatePDPContextRequest) SerializeTo(b []byte) error
SerializeTo serializes CreatePDPContextRequest into bytes given as b.
DEPRECATED: use CreatePDPContextRequest.MarshalTo instead.
func (*CreatePDPContextRequest) SetLength ¶
func (c *CreatePDPContextRequest) SetLength()
SetLength sets the length in Length field.
func (*CreatePDPContextRequest) TEID ¶
func (c *CreatePDPContextRequest) TEID() uint32
TEID returns the TEID in human-readable string.
func (*CreatePDPContextRequest) UnmarshalBinary ¶ added in v0.4.2
func (c *CreatePDPContextRequest) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a CreatePDPContextRequest.
type CreatePDPContextResponse ¶
type CreatePDPContextResponse struct { *Header Cause *ies.IE ReorderingRequired *ies.IE Recovery *ies.IE TEIDDataI *ies.IE TEIDCPlane *ies.IE NSAPI *ies.IE ChargingID *ies.IE EndUserAddress *ies.IE PCO *ies.IE GGSNAddressForCPlane *ies.IE GGSNAddressForUserTraffic *ies.IE AltGGSNAddressForCPlane *ies.IE AltGGSNAddressForUserTraffic *ies.IE QoSProfile *ies.IE ChargingGatewayAddress *ies.IE AltChargingGatewayAddress *ies.IE CommonFlags *ies.IE APNRestriction *ies.IE MSInfoChangeReportingAction *ies.IE BearerControlMode *ies.IE EvolvedARPI *ies.IE ExtendedCommonFlag *ies.IE CSGInformationReportingAction *ies.IE APNAMBR *ies.IE GGSNBackOffTime *ies.IE ExtendedCommonFlagsII *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
CreatePDPContextResponse is a CreatePDPContextResponse Header and its IEs above.
func DecodeCreatePDPContextResponse ¶
func DecodeCreatePDPContextResponse(b []byte) (*CreatePDPContextResponse, error)
DecodeCreatePDPContextResponse decodes bytes as CreatePDPContextResponse.
DEPRECATED: use ParseCreatePDPContextResponse instead.
func NewCreatePDPContextResponse ¶
func NewCreatePDPContextResponse(teid uint32, seq uint16, ie ...*ies.IE) *CreatePDPContextResponse
NewCreatePDPContextResponse creates a new GTPv1 CreatePDPContextResponse.
func ParseCreatePDPContextResponse ¶ added in v0.4.2
func ParseCreatePDPContextResponse(b []byte) (*CreatePDPContextResponse, error)
ParseCreatePDPContextResponse decodes a given byte sequence as a CreatePDPContextResponse.
func (*CreatePDPContextResponse) DecodeFromBytes ¶
func (c *CreatePDPContextResponse) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as CreatePDPContextResponse.
DEPRECATED: use CreatePDPContextResponse.UnmarshalBinary instead.
func (*CreatePDPContextResponse) Len ¶
func (c *CreatePDPContextResponse) Len() int
Len returns the actual length of CreatePDPContextResponse.
DEPRECATED: use CreatePDPContextResponse.MarshalLen instead.
func (*CreatePDPContextResponse) Marshal ¶ added in v0.4.2
func (c *CreatePDPContextResponse) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a CreatePDPContextResponse.
func (*CreatePDPContextResponse) MarshalLen ¶ added in v0.4.2
func (c *CreatePDPContextResponse) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*CreatePDPContextResponse) MarshalTo ¶ added in v0.4.2
func (c *CreatePDPContextResponse) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*CreatePDPContextResponse) MessageTypeName ¶
func (c *CreatePDPContextResponse) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*CreatePDPContextResponse) Serialize ¶
func (c *CreatePDPContextResponse) Serialize() ([]byte, error)
Serialize serializes CreatePDPContextResponse into bytes.
DEPRECATED: use CreatePDPContextResponse.Marshal instead.
func (*CreatePDPContextResponse) SerializeTo ¶
func (c *CreatePDPContextResponse) SerializeTo(b []byte) error
SerializeTo serializes CreatePDPContextResponse into bytes given as b.
DEPRECATED: use CreatePDPContextResponse.MarshalTo instead.
func (*CreatePDPContextResponse) SetLength ¶
func (c *CreatePDPContextResponse) SetLength()
SetLength sets the length in Length field.
func (*CreatePDPContextResponse) TEID ¶
func (c *CreatePDPContextResponse) TEID() uint32
TEID returns the TEID in human-readable string.
func (*CreatePDPContextResponse) UnmarshalBinary ¶ added in v0.4.2
func (c *CreatePDPContextResponse) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a CreatePDPContextResponse.
type DeletePDPContextRequest ¶
type DeletePDPContextRequest struct { *Header Cause *ies.IE TeardownInd *ies.IE NSAPI *ies.IE PCO *ies.IE ULI *ies.IE MSTimeZone *ies.IE ExtendedCommonFlags *ies.IE ULITimestamp *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
DeletePDPContextRequest is a DeletePDPContextRequest Header and its IEs above.
func DecodeDeletePDPContextRequest ¶
func DecodeDeletePDPContextRequest(b []byte) (*DeletePDPContextRequest, error)
DecodeDeletePDPContextRequest decodes bytes as DeletePDPContextRequest.
DEPRECATED: use ParseDeletePDPContextRequest instead.
func NewDeletePDPContextRequest ¶
func NewDeletePDPContextRequest(teid uint32, seq uint16, ie ...*ies.IE) *DeletePDPContextRequest
NewDeletePDPContextRequest creates a new GTPv1 DeletePDPContextRequest.
func ParseDeletePDPContextRequest ¶ added in v0.4.2
func ParseDeletePDPContextRequest(b []byte) (*DeletePDPContextRequest, error)
ParseDeletePDPContextRequest decodes a given byte sequence as a DeletePDPContextRequest.
func (*DeletePDPContextRequest) DecodeFromBytes ¶
func (d *DeletePDPContextRequest) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as DeletePDPContextRequest.
DEPRECATED: use DeletePDPContextRequest.UnmarshalBinary instead.
func (*DeletePDPContextRequest) Len ¶
func (d *DeletePDPContextRequest) Len() int
Len returns the actual length of DeletePDPContextRequest.
DEPRECATED: use DeletePDPContextRequest.MarshalLen instead.
func (*DeletePDPContextRequest) Marshal ¶ added in v0.4.2
func (d *DeletePDPContextRequest) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a DeletePDPContextRequest.
func (*DeletePDPContextRequest) MarshalLen ¶ added in v0.4.2
func (d *DeletePDPContextRequest) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*DeletePDPContextRequest) MarshalTo ¶ added in v0.4.2
func (d *DeletePDPContextRequest) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*DeletePDPContextRequest) MessageTypeName ¶
func (d *DeletePDPContextRequest) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*DeletePDPContextRequest) Serialize ¶
func (d *DeletePDPContextRequest) Serialize() ([]byte, error)
Serialize serializes DeletePDPContextRequest into bytes.
DEPRECATED: use DeletePDPContextRequest.Marshal instead.
func (*DeletePDPContextRequest) SerializeTo ¶
func (d *DeletePDPContextRequest) SerializeTo(b []byte) error
SerializeTo serializes DeletePDPContextRequest into bytes given as b.
DEPRECATED: use DeletePDPContextRequest.MarshalTo instead.
func (*DeletePDPContextRequest) SetLength ¶
func (d *DeletePDPContextRequest) SetLength()
SetLength sets the length in Length field.
func (*DeletePDPContextRequest) TEID ¶
func (d *DeletePDPContextRequest) TEID() uint32
TEID returns the TEID in human-readable string.
func (*DeletePDPContextRequest) UnmarshalBinary ¶ added in v0.4.2
func (d *DeletePDPContextRequest) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a DeletePDPContextRequest.
type DeletePDPContextResponse ¶
type DeletePDPContextResponse struct { *Header Cause *ies.IE PCO *ies.IE ULI *ies.IE MSTimeZone *ies.IE ULITimestamp *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
DeletePDPContextResponse is a DeletePDPContextResponse Header and its IEs above.
func DecodeDeletePDPContextResponse ¶
func DecodeDeletePDPContextResponse(b []byte) (*DeletePDPContextResponse, error)
DecodeDeletePDPContextResponse decodes bytes as DeletePDPContextResponse.
DEPRECATED: use ParseDeletePDPContextResponse instead.
func NewDeletePDPContextResponse ¶
func NewDeletePDPContextResponse(teid uint32, seq uint16, ie ...*ies.IE) *DeletePDPContextResponse
NewDeletePDPContextResponse creates a new GTPv1 DeletePDPContextResponse.
func ParseDeletePDPContextResponse ¶ added in v0.4.2
func ParseDeletePDPContextResponse(b []byte) (*DeletePDPContextResponse, error)
ParseDeletePDPContextResponse decodes a given byte sequence as a DeletePDPContextResponse.
func (*DeletePDPContextResponse) DecodeFromBytes ¶
func (d *DeletePDPContextResponse) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as DeletePDPContextResponse.
DEPRECATED: use DeletePDPContextResponse.UnmarshalBinary instead.
func (*DeletePDPContextResponse) Len ¶
func (d *DeletePDPContextResponse) Len() int
Len returns the actual length of DeletePDPContextResponse.
DEPRECATED: use DeletePDPContextResponse.MarshalLen instead.
func (*DeletePDPContextResponse) Marshal ¶ added in v0.4.2
func (d *DeletePDPContextResponse) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a DeletePDPContextResponse.
func (*DeletePDPContextResponse) MarshalLen ¶ added in v0.4.2
func (d *DeletePDPContextResponse) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*DeletePDPContextResponse) MarshalTo ¶ added in v0.4.2
func (d *DeletePDPContextResponse) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*DeletePDPContextResponse) MessageTypeName ¶
func (d *DeletePDPContextResponse) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*DeletePDPContextResponse) Serialize ¶
func (d *DeletePDPContextResponse) Serialize() ([]byte, error)
Serialize serializes DeletePDPContextResponse into bytes.
DEPRECATED: use DeletePDPContextResponse.Marshal instead.
func (*DeletePDPContextResponse) SerializeTo ¶
func (d *DeletePDPContextResponse) SerializeTo(b []byte) error
SerializeTo serializes DeletePDPContextResponse into bytes given as b.
DEPRECATED: use DeletePDPContextResponse.MarshalTo instead.
func (*DeletePDPContextResponse) SetLength ¶
func (d *DeletePDPContextResponse) SetLength()
SetLength sets the length in Length field.
func (*DeletePDPContextResponse) TEID ¶
func (d *DeletePDPContextResponse) TEID() uint32
TEID returns the TEID in human-readable string.
func (*DeletePDPContextResponse) UnmarshalBinary ¶ added in v0.4.2
func (d *DeletePDPContextResponse) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a DeletePDPContextResponse.
type EchoRequest ¶
EchoRequest is a EchoRequest Header and its IEs above.
func DecodeEchoRequest ¶
func DecodeEchoRequest(b []byte) (*EchoRequest, error)
DecodeEchoRequest decodes bytes as EchoRequest.
DEPRECATED: use ParseEchoRequest instead.
func NewEchoRequest ¶
func NewEchoRequest(seq uint16, ie ...*ies.IE) *EchoRequest
NewEchoRequest creates a new GTP.
func ParseEchoRequest ¶ added in v0.4.2
func ParseEchoRequest(b []byte) (*EchoRequest, error)
ParseEchoRequest decodes a given byte sequence as a EchoRequest.
func (*EchoRequest) DecodeFromBytes ¶
func (e *EchoRequest) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as EchoRequest.
DEPRECATED: use EchoRequest.UnmarshalBinary instead.
func (*EchoRequest) Len ¶
func (e *EchoRequest) Len() int
Len returns the actual length of EchoRequest.
DEPRECATED: use EchoRequest.MarshalLen instead.
func (*EchoRequest) Marshal ¶ added in v0.4.2
func (e *EchoRequest) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a EchoRequest.
func (*EchoRequest) MarshalLen ¶ added in v0.4.2
func (e *EchoRequest) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*EchoRequest) MarshalTo ¶ added in v0.4.2
func (e *EchoRequest) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*EchoRequest) MessageTypeName ¶
func (e *EchoRequest) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*EchoRequest) Serialize ¶
func (e *EchoRequest) Serialize() ([]byte, error)
Serialize serializes EchoRequest into bytes.
DEPRECATED: use EchoRequest.Marshal instead.
func (*EchoRequest) SerializeTo ¶
func (e *EchoRequest) SerializeTo(b []byte) error
SerializeTo serializes EchoRequest into bytes given as b.
DEPRECATED: use EchoRequest.MarshalTo instead.
func (*EchoRequest) SetLength ¶
func (e *EchoRequest) SetLength()
SetLength sets the length in Length field.
func (*EchoRequest) TEID ¶
func (e *EchoRequest) TEID() uint32
TEID returns the TEID in human-readable string.
func (*EchoRequest) UnmarshalBinary ¶ added in v0.4.2
func (e *EchoRequest) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a EchoRequest.
type EchoResponse ¶
type EchoResponse struct { *Header Recovery *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
EchoResponse is a EchoResponse Header and its IEs above.
func DecodeEchoResponse ¶
func DecodeEchoResponse(b []byte) (*EchoResponse, error)
DecodeEchoResponse decodes bytes as EchoResponse.
DEPRECATED: use ParseEchoResponse instead.
func NewEchoResponse ¶
func NewEchoResponse(seq uint16, ie ...*ies.IE) *EchoResponse
NewEchoResponse creates a new GTPv1 EchoResponse.
func ParseEchoResponse ¶ added in v0.4.2
func ParseEchoResponse(b []byte) (*EchoResponse, error)
ParseEchoResponse decodes a given byte sequence as a EchoResponse.
func (*EchoResponse) DecodeFromBytes ¶
func (e *EchoResponse) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as EchoResponse.
DEPRECATED: use EchoResponse.UnmarshalBinary instead.
func (*EchoResponse) Len ¶
func (e *EchoResponse) Len() int
Len returns the actual length of EchoResponse.
DEPRECATED: use EchoResponse.MarshalLen instead.
func (*EchoResponse) Marshal ¶ added in v0.4.2
func (e *EchoResponse) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a EchoResponse.
func (*EchoResponse) MarshalLen ¶ added in v0.4.2
func (e *EchoResponse) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*EchoResponse) MarshalTo ¶ added in v0.4.2
func (e *EchoResponse) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*EchoResponse) MessageTypeName ¶
func (e *EchoResponse) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*EchoResponse) Serialize ¶
func (e *EchoResponse) Serialize() ([]byte, error)
Serialize serializes EchoResponse into bytes.
DEPRECATED: use EchoResponse.Marshal instead.
func (*EchoResponse) SerializeTo ¶
func (e *EchoResponse) SerializeTo(b []byte) error
SerializeTo serializes EchoResponse into bytes given as b.
DEPRECATED: use EchoResponse.MarshalTo instead.
func (*EchoResponse) SetLength ¶
func (e *EchoResponse) SetLength()
SetLength sets the length in Length field.
func (*EchoResponse) TEID ¶
func (e *EchoResponse) TEID() uint32
TEID returns the TEID in human-readable string.
func (*EchoResponse) UnmarshalBinary ¶ added in v0.4.2
func (e *EchoResponse) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a EchoResponse.
type ErrorIndication ¶
type ErrorIndication struct { *Header TEIDDataI *ies.IE GTPUPeerAddress *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
ErrorIndication is a ErrorIndication Header and its IEs above.
func DecodeErrorIndication ¶
func DecodeErrorIndication(b []byte) (*ErrorIndication, error)
DecodeErrorIndication decodes bytes as ErrorIndication.
DEPRECATED: use ParseErrorIndication instead.
func NewErrorIndication ¶
func NewErrorIndication(teid uint32, seq uint16, ie ...*ies.IE) *ErrorIndication
NewErrorIndication creates a new GTPv1 NewErrorIndication.
func ParseErrorIndication ¶ added in v0.4.2
func ParseErrorIndication(b []byte) (*ErrorIndication, error)
ParseErrorIndication decodes a given byte sequence as a ErrorIndication.
func (*ErrorIndication) DecodeFromBytes ¶
func (e *ErrorIndication) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as ErrorIndication.
DEPRECATED: use ErrorIndication.UnmarshalBinary instead.
func (*ErrorIndication) Len ¶
func (e *ErrorIndication) Len() int
Len returns the actual length of ErrorIndication.
DEPRECATED: use ErrorIndication.MarshalLen instead.
func (*ErrorIndication) Marshal ¶ added in v0.4.2
func (e *ErrorIndication) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a ErrorIndication.
func (*ErrorIndication) MarshalLen ¶ added in v0.4.2
func (e *ErrorIndication) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*ErrorIndication) MarshalTo ¶ added in v0.4.2
func (e *ErrorIndication) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*ErrorIndication) MessageTypeName ¶
func (e *ErrorIndication) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*ErrorIndication) Serialize ¶
func (e *ErrorIndication) Serialize() ([]byte, error)
Serialize serializes ErrorIndication into bytes.
DEPRECATED: use ErrorIndication.Marshal instead.
func (*ErrorIndication) SerializeTo ¶
func (e *ErrorIndication) SerializeTo(b []byte) error
SerializeTo serializes ErrorIndication into bytes given as b.
DEPRECATED: use ErrorIndication.MarshalTo instead.
func (*ErrorIndication) SetLength ¶
func (e *ErrorIndication) SetLength()
SetLength sets the length in Length field.
func (*ErrorIndication) TEID ¶
func (e *ErrorIndication) TEID() uint32
TEID returns the TEID in human-readable string.
func (*ErrorIndication) UnmarshalBinary ¶ added in v0.4.2
func (e *ErrorIndication) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a ErrorIndication.
type Generic ¶
Generic is a Generic Header and its IEs above. This is for handling a non-implemented type of message.
func NewGeneric ¶
NewGeneric creates a new GTPv1 Generic.
func ParseGeneric ¶ added in v0.4.2
ParseGeneric decodes a given byte sequence as a Generic.
func (*Generic) DecodeFromBytes ¶
DecodeFromBytes decodes bytes as Generic.
DEPRECATED: use Generic.UnmarshalBinary instead.
func (*Generic) Len ¶
Len returns the actual length of Generic.
DEPRECATED: use Generic.MarshalLen instead.
func (*Generic) Marshal ¶ added in v0.4.2
Marshal returns the byte sequence generated from a Generic.
func (*Generic) MarshalLen ¶ added in v0.4.2
MarshalLen returns the serial length of Data.
func (*Generic) MarshalTo ¶ added in v0.4.2
MarshalTo puts the byte sequence in the byte array given as b.
func (*Generic) MessageTypeName ¶
MessageTypeName returns the name of protocol.
func (*Generic) Serialize ¶
Serialize serializes Generic into bytes.
DEPRECATED: use Generic.Marshal instead.
func (*Generic) SerializeTo ¶
SerializeTo serializes Generic into bytes given as b.
DEPRECATED: use Generic.MarshalTo instead.
func (*Generic) SetLength ¶
func (g *Generic) SetLength()
SetLength sets the length in Length field.
func (*Generic) UnmarshalBinary ¶ added in v0.4.2
UnmarshalBinary decodes a given byte sequence as a Generic.
type Header ¶
type Header struct { Flags uint8 Type uint8 Length uint16 TEID uint32 SequenceNumber uint16 Reserved uint16 Payload []byte }
Header is a GTPv1 common header.
func ParseHeader ¶ added in v0.4.2
ParseHeader decodes given byte sequence as a GTPv1 header.
func (*Header) DecodeFromBytes ¶
DecodeFromBytes decodes bytes as Header.
DEPRECATED: use Header.UnmarshalBinary instead.
func (*Header) HasSequence ¶
HasSequence determines whether a GTP Header has TEID inside by checking the flag.
func (*Header) Len ¶
Len returns the actual length of Header.
DEPRECATED: use Header.MarshalLen instead.
func (*Header) Marshal ¶ added in v0.4.2
Marshal returns the byte sequence generated from an IE instance.
func (*Header) MarshalLen ¶ added in v0.4.2
MarshalLen returns the serial length of Header.
func (*Header) MarshalTo ¶ added in v0.4.2
MarshalTo puts the byte sequence in the byte array given as b.
func (*Header) MessageType ¶
MessageType returns the type of message.
func (*Header) Serialize ¶
Serialize serializes Header into bytes.
DEPRECATED: use Header.Marshal instead.
func (*Header) SerializeTo ¶
SerializeTo serializes Header into bytes given as b.
DEPRECATED: use Header.MarshalTo instead.
func (*Header) SetSequenceNumber ¶
SetSequenceNumber sets the SequenceNumber in Header.
func (*Header) UnmarshalBinary ¶ added in v0.4.2
UnmarshalBinary sets the values retrieved from byte sequence in GTPv1 header.
type Message ¶
type Message interface { MarshalTo([]byte) error UnmarshalBinary(b []byte) error MarshalLen() int Version() int MessageType() uint8 MessageTypeName() string TEID() uint32 SetTEID(uint32) Sequence() uint16 SetSequenceNumber(uint16) // deprecated SerializeTo([]byte) error DecodeFromBytes(b []byte) error }
Message is an interface that defines Message messages.
type TPDU ¶
type TPDU struct {
*Header
}
TPDU is a TPDU.
func NewTPDUWithSequence ¶
NewTPDUWithSequence creates a new G-PDU message.
func (*TPDU) Decapsulate ¶
Decapsulate returns payload as raw []byte.
func (*TPDU) DecodeFromBytes ¶
DecodeFromBytes decodes bytes as TPDU.
DEPRECATED: use TPDU.UnmarshalBinary instead.
func (*TPDU) MarshalLen ¶ added in v0.4.2
MarshalLen returns the serial length of Data.
func (*TPDU) MarshalTo ¶ added in v0.4.2
MarshalTo puts the byte sequence in the byte array given as b.
func (*TPDU) MessageTypeName ¶
MessageTypeName returns the name of protocol.
func (*TPDU) Serialize ¶
Serialize serializes TPDU into bytes.
DEPRECATED: use TPDU.Marshal instead.
func (*TPDU) SerializeTo ¶
SerializeTo serializes TPDU into bytes given as b.
DEPRECATED: use TPDU.MarshalTo instead.
func (*TPDU) UnmarshalBinary ¶ added in v0.4.2
UnmarshalBinary decodes a given byte sequence as a TPDU.
type UpdatePDPContextRequest ¶
type UpdatePDPContextRequest struct { *Header IMSI *ies.IE RAI *ies.IE Recovery *ies.IE TEIDDataI *ies.IE TEIDCPlane *ies.IE NSAPI *ies.IE TraceReference *ies.IE TraceType *ies.IE PCO *ies.IE SGSNAddressForCPlane *ies.IE SGSNAddressForUserTraffic *ies.IE AlternativeSGSNAddressForCPlane *ies.IE AlternativeSGSNAddressForUserTraffic *ies.IE QoSProfile *ies.IE TFT *ies.IE TriggerID *ies.IE OMCIdentity *ies.IE CommonFlags *ies.IE RATType *ies.IE ULI *ies.IE MSTimeZone *ies.IE AdditionalTraceInfo *ies.IE DirectTunnelFlags *ies.IE EvolvedARPI *ies.IE ExtendedCommonFlags *ies.IE UCI *ies.IE APNAMBR *ies.IE SignallingPriorityIndication *ies.IE CNOperatorSelectionEntity *ies.IE IMEI *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
UpdatePDPContextRequest is a UpdatePDPContextRequest Header and its IEs above.
func DecodeUpdatePDPContextRequest ¶
func DecodeUpdatePDPContextRequest(b []byte) (*UpdatePDPContextRequest, error)
DecodeUpdatePDPContextRequest decodes bytes as UpdatePDPContextRequest.
DEPRECATED: use ParseUpdatePDPContextRequest instead.
func NewUpdatePDPContextRequest ¶
func NewUpdatePDPContextRequest(teid uint32, seq uint16, ie ...*ies.IE) *UpdatePDPContextRequest
NewUpdatePDPContextRequest creates a new GTPv1 UpdatePDPContextRequest.
func ParseUpdatePDPContextRequest ¶ added in v0.4.2
func ParseUpdatePDPContextRequest(b []byte) (*UpdatePDPContextRequest, error)
ParseUpdatePDPContextRequest decodes a given byte sequence as a UpdatePDPContextRequest.
func (*UpdatePDPContextRequest) DecodeFromBytes ¶
func (u *UpdatePDPContextRequest) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as UpdatePDPContextRequest.
DEPRECATED: use UpdatePDPContextRequest.UnmarshalBinary instead.
func (*UpdatePDPContextRequest) Len ¶
func (u *UpdatePDPContextRequest) Len() int
Len returns the actual length of UpdatePDPContextRequest.
DEPRECATED: use UpdatePDPContextRequest.MarshalLen instead.
func (*UpdatePDPContextRequest) Marshal ¶ added in v0.4.2
func (u *UpdatePDPContextRequest) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a UpdatePDPContextRequest.
func (*UpdatePDPContextRequest) MarshalLen ¶ added in v0.4.2
func (u *UpdatePDPContextRequest) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*UpdatePDPContextRequest) MarshalTo ¶ added in v0.4.2
func (u *UpdatePDPContextRequest) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*UpdatePDPContextRequest) MessageTypeName ¶
func (u *UpdatePDPContextRequest) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*UpdatePDPContextRequest) Serialize ¶
func (u *UpdatePDPContextRequest) Serialize() ([]byte, error)
Serialize serializes UpdatePDPContextRequest into bytes.
DEPRECATED: use UpdatePDPContextRequest.Marshal instead.
func (*UpdatePDPContextRequest) SerializeTo ¶
func (u *UpdatePDPContextRequest) SerializeTo(b []byte) error
SerializeTo serializes UpdatePDPContextRequest into bytes given as b.
DEPRECATED: use UpdatePDPContextRequest.MarshalTo instead.
func (*UpdatePDPContextRequest) SetLength ¶
func (u *UpdatePDPContextRequest) SetLength()
SetLength sets the length in Length field.
func (*UpdatePDPContextRequest) TEID ¶
func (u *UpdatePDPContextRequest) TEID() uint32
TEID returns the TEID in human-readable string.
func (*UpdatePDPContextRequest) UnmarshalBinary ¶ added in v0.4.2
func (u *UpdatePDPContextRequest) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a UpdatePDPContextRequest.
type UpdatePDPContextResponse ¶
type UpdatePDPContextResponse struct { *Header Cause *ies.IE Recovery *ies.IE TEIDDataI *ies.IE TEIDCPlane *ies.IE ChargingID *ies.IE PCO *ies.IE GGSNAddressForCPlane *ies.IE GGSNAddressForUserTraffic *ies.IE AltGGSNAddressForCPlane *ies.IE AltGGSNAddressForUserTraffic *ies.IE QoSProfile *ies.IE ChargingGatewayAddress *ies.IE AltChargingGatewayAddress *ies.IE CommonFlags *ies.IE APNRestriction *ies.IE BearerControlMode *ies.IE MSInfoChangeReportingAction *ies.IE EvolvedARPI *ies.IE CSGInformationReportingAction *ies.IE APNAMBR *ies.IE PrivateExtension *ies.IE AdditionalIEs []*ies.IE }
UpdatePDPContextResponse is a UpdatePDPContextResponse Header and its IEs above.
func DecodeUpdatePDPContextResponse ¶
func DecodeUpdatePDPContextResponse(b []byte) (*UpdatePDPContextResponse, error)
DecodeUpdatePDPContextResponse decodes bytes as UpdatePDPContextResponse.
DEPRECATED: use ParseUpdatePDPContextResponse instead.
func NewUpdatePDPContextResponse ¶
func NewUpdatePDPContextResponse(teid uint32, seq uint16, ie ...*ies.IE) *UpdatePDPContextResponse
NewUpdatePDPContextResponse creates a new GTPv1 UpdatePDPContextResponse.
func ParseUpdatePDPContextResponse ¶ added in v0.4.2
func ParseUpdatePDPContextResponse(b []byte) (*UpdatePDPContextResponse, error)
ParseUpdatePDPContextResponse decodes a given byte sequence as a UpdatePDPContextResponse.
func (*UpdatePDPContextResponse) DecodeFromBytes ¶
func (u *UpdatePDPContextResponse) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as UpdatePDPContextResponse.
DEPRECATED: use UpdatePDPContextResponse.UnmarshalBinary instead.
func (*UpdatePDPContextResponse) Len ¶
func (u *UpdatePDPContextResponse) Len() int
Len returns the actual length of UpdatePDPContextResponse.
DEPRECATED: use UpdatePDPContextResponse.MarshalLen instead.
func (*UpdatePDPContextResponse) Marshal ¶ added in v0.4.2
func (u *UpdatePDPContextResponse) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a UpdatePDPContextResponse.
func (*UpdatePDPContextResponse) MarshalLen ¶ added in v0.4.2
func (u *UpdatePDPContextResponse) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*UpdatePDPContextResponse) MarshalTo ¶ added in v0.4.2
func (u *UpdatePDPContextResponse) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*UpdatePDPContextResponse) MessageTypeName ¶
func (u *UpdatePDPContextResponse) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*UpdatePDPContextResponse) Serialize ¶
func (u *UpdatePDPContextResponse) Serialize() ([]byte, error)
Serialize serializes UpdatePDPContextResponse into bytes.
DEPRECATED: use UpdatePDPContextResponse.Marshal instead.
func (*UpdatePDPContextResponse) SerializeTo ¶
func (u *UpdatePDPContextResponse) SerializeTo(b []byte) error
SerializeTo serializes UpdatePDPContextResponse into bytes given as b.
DEPRECATED: use UpdatePDPContextResponse.MarshalTo instead.
func (*UpdatePDPContextResponse) SetLength ¶
func (u *UpdatePDPContextResponse) SetLength()
SetLength sets the length in Length field.
func (*UpdatePDPContextResponse) TEID ¶
func (u *UpdatePDPContextResponse) TEID() uint32
TEID returns the TEID in human-readable string.
func (*UpdatePDPContextResponse) UnmarshalBinary ¶ added in v0.4.2
func (u *UpdatePDPContextResponse) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a UpdatePDPContextResponse.
type VersionNotSupported ¶
VersionNotSupported is a VersionNotSupported Header and its IEs above.
func DecodeVersionNotSupported ¶
func DecodeVersionNotSupported(b []byte) (*VersionNotSupported, error)
DecodeVersionNotSupported decodes bytes as VersionNotSupported.
DEPRECATED: use ParseVersionNotSupported instead.
func NewVersionNotSupported ¶
func NewVersionNotSupported(teid uint32, seq uint16, ie ...*ies.IE) *VersionNotSupported
NewVersionNotSupported creates a new GTPv1 VersionNotSupported.
func ParseVersionNotSupported ¶ added in v0.4.2
func ParseVersionNotSupported(b []byte) (*VersionNotSupported, error)
ParseVersionNotSupported decodes a given byte sequence as a VersionNotSupported.
func (*VersionNotSupported) DecodeFromBytes ¶
func (v *VersionNotSupported) DecodeFromBytes(b []byte) error
DecodeFromBytes decodes bytes as VersionNotSupported.
DEPRECATED: use VersionNotSupported.UnmarshalBinary instead.
func (*VersionNotSupported) Len ¶
func (v *VersionNotSupported) Len() int
Len returns the actual length of VersionNotSupported.
DEPRECATED: use VersionNotSupported.MarshalLen instead.
func (*VersionNotSupported) Marshal ¶ added in v0.4.2
func (v *VersionNotSupported) Marshal() ([]byte, error)
Marshal returns the byte sequence generated from a VersionNotSupported.
func (*VersionNotSupported) MarshalLen ¶ added in v0.4.2
func (v *VersionNotSupported) MarshalLen() int
MarshalLen returns the serial length of Data.
func (*VersionNotSupported) MarshalTo ¶ added in v0.4.2
func (v *VersionNotSupported) MarshalTo(b []byte) error
MarshalTo puts the byte sequence in the byte array given as b.
func (*VersionNotSupported) MessageTypeName ¶
func (v *VersionNotSupported) MessageTypeName() string
MessageTypeName returns the name of protocol.
func (*VersionNotSupported) Serialize ¶
func (v *VersionNotSupported) Serialize() ([]byte, error)
Serialize serializes VersionNotSupported into bytes.
DEPRECATED: use VersionNotSupported.Marshal instead.
func (*VersionNotSupported) SerializeTo ¶
func (v *VersionNotSupported) SerializeTo(b []byte) error
SerializeTo serializes VersionNotSupported into bytes given as b.
DEPRECATED: use VersionNotSupported.MarshalTo instead.
func (*VersionNotSupported) SetLength ¶
func (v *VersionNotSupported) SetLength()
SetLength sets the length in Length field.
func (*VersionNotSupported) TEID ¶
func (v *VersionNotSupported) TEID() uint32
TEID returns the TEID in human-readable string.
func (*VersionNotSupported) UnmarshalBinary ¶ added in v0.4.2
func (v *VersionNotSupported) UnmarshalBinary(b []byte) error
UnmarshalBinary decodes a given byte sequence as a VersionNotSupported.
Source Files ¶
- create-pdp-context-req.go
- create-pdp-context-req_deprecated.go
- create-pdp-context-res.go
- create-pdp-context-res_deprecated.go
- delete-pdp-context-req.go
- delete-pdp-context-req_deprecated.go
- delete-pdp-context-res.go
- delete-pdp-context-res_deprecated.go
- echo-req.go
- echo-req_deprecated.go
- echo-res.go
- echo-res_deprecated.go
- error-indication.go
- error-indication_deprecated.go
- errors.go
- generic.go
- generic_deprecated.go
- header.go
- header_deprecated.go
- message.go
- message_deprecated.go
- t-pdu.go
- t-pdu_deprecated.go
- update-pdp-context-req.go
- update-pdp-context-req_deprecated.go
- update-pdp-context-res.go
- update-pdp-context-res_deprecated.go
- version-not-supported.go
- version-not-supported_deprecated.go