MCPcopy Create free account
hub / github.com/livekit/livekit / String

Method String

pkg/sfu/streamallocator/streamallocator.go:151–177  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

149}
150
151func (e Event) String() string {
152 value := ""
153 switch e.signal {
154 case streamAllocatorSignalAllocateTrack, streamAllocatorSignalResume:
155 value = fmt.Sprintf("trackID: %s", e.trackID)
156 case streamAllocatorSignalEstimate, streamAllocatorSignalSetChannelCapacity:
157 value = fmt.Sprintf("channelCapacity: %d", e.channelCapacity)
158 case streamAllocatorSignalFeedback:
159 value = fmt.Sprintf("twccFeedback: %+v", e.twccFeedback)
160 case streamAllocatorSignalProbeClusterSwitch:
161 value = fmt.Sprintf("probeClusterInfo: %+v", e.probeClusterInfo)
162 case streamAllocatorSignalSendProbe:
163 value = fmt.Sprintf("probeBytesToSend: %d", e.probeBytesToSend)
164 case streamAllocatorSignalPacerProbeObserverClusterComplete:
165 value = fmt.Sprintf("probeClusterId: %v", e.probeClusterId)
166 case streamAllocatorSignalSetAllowPause:
167 value = fmt.Sprintf("allowPause: %v", e.allowPause)
168 case streamAllocatorSignalCongestionStateChange:
169 value = fmt.Sprintf("congestStatecChangeData: %+v", e.congestionStateChangeData)
170 }
171
172 if value == "" {
173 return fmt.Sprintf("StreamAllocator:Event{signal: %s}", e.signal)
174 }
175
176 return fmt.Sprintf("StreamAllocator:Event{signal: %s, %s}", e.signal, value)
177}
178
179// ---------------------------------------------------------------------------
180

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected