MCPcopy Index your code
hub / github.com/golang/groupcache / byteViewSink

Struct byteViewSink

sinks.go:113–124  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111}
112
113type byteViewSink struct {
114 dst *ByteView
115
116 // if this code ever ends up tracking that at least one set*
117 // method was called, don't make it an error to call set
118 // methods multiple times. Lorry's payload.go does that, and
119 // it makes sense. The comment at the top of this file about
120 // "exactly one of the Set methods" is overly strict. We
121 // really care about at least once (in a handler), but if
122 // multiple handlers fail (or multiple functions in a program
123 // using a Sink), it's okay to re-use the same one.
124}
125
126func (s *byteViewSink) setView(v ByteView) error {
127 *s.dst = v

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected