MCPcopy Create free account
hub / github.com/imgproxy/imgproxy / Remove

Method Remove

xmlparser/buffer.go:60–64  ·  view source on GitHub ↗

Remove removes the last n bytes.

(n int)

Source from the content-addressed store, hash-verified

58
59// Remove removes the last n bytes.
60func (b *buffer) Remove(n int) {
61 l := len(*b)
62 n = min(n, l)
63 *b = (*b)[:l-n]
64}
65
66// Bytes returns the contents of the buffer as a byte slice.
67func (b *buffer) Bytes() []byte {

Callers 10

readTextMethod · 0.80
readAttrValueMethod · 0.80
readProcInstMethod · 0.80
readCommentMethod · 0.80
readCDataMethod · 0.80
readDoctypeMethod · 0.80
TestPresetsFromFileFunction · 0.80
TestPresetsFileEmptyFunction · 0.80
TestStringSliceFileFunction · 0.80

Calls

no outgoing calls

Tested by 4

TestPresetsFromFileFunction · 0.64
TestPresetsFileEmptyFunction · 0.64
TestStringSliceFileFunction · 0.64