Source File
unmarshal_cache.go
Belonging Package
github.com/pion/sdp/v3
// SPDX-FileCopyrightText: 2023 The Pion community <https://pion.ly>// SPDX-License-Identifier: MITpackage sdptype unmarshalCache struct {sessionAttributes []AttributemediaAttributes []Attribute}func ( *unmarshalCache) () {.sessionAttributes = .sessionAttributes[:0].mediaAttributes = .mediaAttributes[:0]}func ( *unmarshalCache) () *Attribute {.sessionAttributes = append(.sessionAttributes, Attribute{})return &.sessionAttributes[len(.sessionAttributes)-1]}func ( *unmarshalCache) () []Attribute {if len(.sessionAttributes) == 0 {return nil}:= make([]Attribute, len(.sessionAttributes))copy(, .sessionAttributes).sessionAttributes = .sessionAttributes[:0]return}func ( *unmarshalCache) () *Attribute {.mediaAttributes = append(.mediaAttributes, Attribute{})return &.mediaAttributes[len(.mediaAttributes)-1]}func ( *unmarshalCache) () []Attribute {if len(.mediaAttributes) == 0 {return nil}:= make([]Attribute, len(.mediaAttributes))copy(, .mediaAttributes).mediaAttributes = .mediaAttributes[:0]return}
![]() |
The pages are generated with Golds v0.8.2. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |