Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/golang/snappy
/ functions
Functions
117 in github.com/golang/snappy
⨍
Functions
117
◇
Types & classes
3
↓ 24 callers
Function
benchFile
(b *testing.B, i int, decode bool)
snappy_test.go:1369
↓ 16 callers
Method
Write
(p []byte)
snappy_test.go:1181
↓ 12 callers
Function
benchWords
(b *testing.B, n int, decode bool)
snappy_test.go:1267
↓ 10 callers
Function
cmp
(a, b []byte)
snappy_test.go:63
↓ 9 callers
Function
Decode
Decode returns the decoded form of src. The returned slice may be a sub- slice of dst if dst was large enough to hold the entire decoded block. Otherw
decode.go:57
↓ 9 callers
Method
Flush
Flush flushes the Writer to its underlying io.Writer.
encode.go:269
↓ 9 callers
Function
NewReader
NewReader returns a new Reader that decompresses from r, using the framing format described at https://github.com/google/snappy/blob/master/framing_fo
decode.go:79
↓ 8 callers
Method
Close
Close calls Flush and then closes the Writer.
encode.go:282
↓ 8 callers
Function
Encode
Encode returns the encoded form of src. The returned slice may be a sub- slice of dst if dst was large enough to hold the entire encoded block. Otherw
encode.go:20
↓ 7 callers
Function
NewBufferedWriter
NewBufferedWriter returns a new Writer that compresses to w, using the framing format described at https://github.com/google/snappy/blob/master/framin
encode.go:135
↓ 6 callers
Method
readFull
(p []byte, allowEOF bool)
decode.go:111
↓ 5 callers
Function
hash
(u, shift uint32)
encode_other.go:101
↓ 5 callers
Function
load32
(b []byte, i int)
encode_other.go:9
↓ 4 callers
Method
Write
Write satisfies the io.Writer interface.
encode.go:176
↓ 4 callers
Function
roundtrip
(b, ebuf, dbuf []byte)
snappy_test.go:78
↓ 3 callers
Function
MaxEncodedLen
MaxEncodedLen returns the maximum length of a snappy block, given its uncompressed length. It will return a negative value if srcLen is too large to
encode.go:78
↓ 3 callers
Function
NewWriter
NewWriter returns a new Writer that compresses to w. The Writer returned does not buffer writes. There is no need to Flush or Close such a Writer. D
encode.go:121
↓ 3 callers
Function
benchEncode
(b *testing.B, src []byte)
snappy_test.go:1229
↓ 3 callers
Function
crc
crc implements the checksum specified in section 3 of https://github.com/google/snappy/blob/master/framing_format.txt
snappy.go:95
↓ 3 callers
Function
extendMatch
extendMatch has the same semantics as in encode_other.go. go:noescape
encode_asm.go:25
↓ 3 callers
Function
readFile
(b testing.TB, filename string)
snappy_test.go:1246
↓ 3 callers
Method
write
(p []byte)
encode.go:211
↓ 2 callers
Function
DecodedLen
DecodedLen returns the length of the decoded block.
decode.go:25
↓ 2 callers
Method
Reset
Reset discards the writer's state and switches the Snappy writer to write to w. This permits reusing a Writer rather than allocating a new one.
encode.go:166
↓ 2 callers
Method
Reset
Reset discards any buffered data, resets all state, and switches the Snappy reader to read from r. This permits reusing a Reader rather than allocatin
decode.go:103
↓ 2 callers
Function
benchDecode
(b *testing.B, src []byte)
snappy_test.go:1219
↓ 2 callers
Function
decodedLen
decodedLen returns the length of the decoded block and the number of bytes that the length header occupied.
decode.go:32
↓ 2 callers
Function
downloadBenchmarkFiles
(b testing.TB, basename string)
snappy_test.go:1327
↓ 2 callers
Function
emitLiteral
emitLiteral has the same semantics as in encode_other.go. go:noescape
encode_asm.go:15
↓ 2 callers
Function
emitLiteral
emitLiteral writes a literal chunk and returns the number of bytes written. It assumes that: dst is long enough to hold the encoded bytes 1 <= len(
encode_other.go:25
↓ 2 callers
Method
fill
()
decode.go:121
↓ 2 callers
Function
runTestSameEncodingAsCpp
(src []byte)
snappy_test.go:600
↓ 2 callers
Function
skipTestSameEncodingAsCpp
()
snappy_test.go:590
↓ 2 callers
Function
testOrBenchmark
(b testing.TB)
snappy_test.go:1239
↓ 1 callers
Method
Read
Read satisfies the io.Reader interface.
decode.go:237
↓ 1 callers
Method
ReadByte
ReadByte satisfies the io.ByteReader interface.
decode.go:252
↓ 1 callers
Function
decode
decode has the same semantics as in decode_other.go. go:noescape
decode_asm.go:15
↓ 1 callers
Function
emitCopy
emitCopy has the same semantics as in encode_other.go. go:noescape
encode_asm.go:20
↓ 1 callers
Function
emitCopy
emitCopy writes a copy chunk and returns the number of bytes written. It assumes that: dst is long enough to hold the encoded bytes 1 <= offset &&
encode_other.go:50
↓ 1 callers
Function
encodeBlock
encodeBlock has the same semantics as in encode_other.go. go:noescape
encode_asm.go:30
↓ 1 callers
Function
expand
expand returns a slice of length n containing repeated copies of src.
snappy_test.go:1258
↓ 1 callers
Function
load64
(b []byte, i int)
encode_other.go:14
↓ 1 callers
Function
run
()
cmd/snappytool/main.go:17
Function
BenchmarkExtendMatch
(b *testing.B)
snappy_test.go:1411
Function
BenchmarkRandomEncode
(b *testing.B)
snappy_test.go:1291
Function
BenchmarkWordsDecode1e1
(b *testing.B)
snappy_test.go:1278
Function
BenchmarkWordsDecode1e2
(b *testing.B)
snappy_test.go:1279
Function
BenchmarkWordsDecode1e3
(b *testing.B)
snappy_test.go:1280
Function
BenchmarkWordsDecode1e4
(b *testing.B)
snappy_test.go:1281
Function
BenchmarkWordsDecode1e5
(b *testing.B)
snappy_test.go:1282
Function
BenchmarkWordsDecode1e6
(b *testing.B)
snappy_test.go:1283
Function
BenchmarkWordsEncode1e1
(b *testing.B)
snappy_test.go:1284
Function
BenchmarkWordsEncode1e2
(b *testing.B)
snappy_test.go:1285
Function
BenchmarkWordsEncode1e3
(b *testing.B)
snappy_test.go:1286
Function
BenchmarkWordsEncode1e4
(b *testing.B)
snappy_test.go:1287
Function
BenchmarkWordsEncode1e5
(b *testing.B)
snappy_test.go:1288
Function
BenchmarkWordsEncode1e6
(b *testing.B)
snappy_test.go:1289
Function
Benchmark_UFlat0
Naming convention is kept similar to what snappy's C++ implementation uses.
snappy_test.go:1386
Function
Benchmark_UFlat1
(b *testing.B)
snappy_test.go:1387
Function
Benchmark_UFlat10
(b *testing.B)
snappy_test.go:1396
Function
Benchmark_UFlat11
(b *testing.B)
snappy_test.go:1397
Function
Benchmark_UFlat2
(b *testing.B)
snappy_test.go:1388
Function
Benchmark_UFlat3
(b *testing.B)
snappy_test.go:1389
Function
Benchmark_UFlat4
(b *testing.B)
snappy_test.go:1390
Function
Benchmark_UFlat5
(b *testing.B)
snappy_test.go:1391
Function
Benchmark_UFlat6
(b *testing.B)
snappy_test.go:1392
Function
Benchmark_UFlat7
(b *testing.B)
snappy_test.go:1393
Function
Benchmark_UFlat8
(b *testing.B)
snappy_test.go:1394
Function
Benchmark_UFlat9
(b *testing.B)
snappy_test.go:1395
Function
Benchmark_ZFlat0
(b *testing.B)
snappy_test.go:1398
Function
Benchmark_ZFlat1
(b *testing.B)
snappy_test.go:1399
Function
Benchmark_ZFlat10
(b *testing.B)
snappy_test.go:1408
Function
Benchmark_ZFlat11
(b *testing.B)
snappy_test.go:1409
Function
Benchmark_ZFlat2
(b *testing.B)
snappy_test.go:1400
Function
Benchmark_ZFlat3
(b *testing.B)
snappy_test.go:1401
Function
Benchmark_ZFlat4
(b *testing.B)
snappy_test.go:1402
Function
Benchmark_ZFlat5
(b *testing.B)
snappy_test.go:1403
Function
Benchmark_ZFlat6
(b *testing.B)
snappy_test.go:1404
Function
Benchmark_ZFlat7
(b *testing.B)
snappy_test.go:1405
Function
Benchmark_ZFlat8
(b *testing.B)
snappy_test.go:1406
Function
Benchmark_ZFlat9
(b *testing.B)
snappy_test.go:1407
Function
TestDecode
(t *testing.T)
snappy_test.go:162
Function
TestDecodeCopy4
(t *testing.T)
snappy_test.go:382
Function
TestDecodeGoldenInput
(t *testing.T)
snappy_test.go:509
Function
TestDecodeLengthOffset
TestDecodeLengthOffset tests decoding an encoding of the form literal + copy-length-offset + literal. For example: "abcdefghijkl" + "efghij" + "AB".
snappy_test.go:412
Function
TestEmitCopy
(t *testing.T)
snappy_test.go:834
Function
TestEmitLiteral
(t *testing.T)
snappy_test.go:797
Function
TestEmpty
(t *testing.T)
snappy_test.go:89
Function
TestEncodeGoldenInput
(t *testing.T)
snappy_test.go:528
Function
TestEncodeNoiseThenRepeats
TestEncodeNoiseThenRepeats encodes input for which the first half is very incompressible and the second half is very compressible. The encoded form's
snappy_test.go:698
Function
TestExtendMatch
(t *testing.T)
snappy_test.go:559
Function
TestExtendMatchGoldenInput
(t *testing.T)
snappy_test.go:544
Function
TestFlush
(t *testing.T)
snappy_test.go:945
Function
TestFramingFormat
(t *testing.T)
snappy_test.go:716
Function
TestInvalidVarint
(t *testing.T)
snappy_test.go:133
Function
TestMaxEncodedLenOfMaxBlockSize
(t *testing.T)
snappy_test.go:55
Function
TestNewBufferedWriter
(t *testing.T)
snappy_test.go:902
Function
TestNumUnderlyingWrites
TestNumUnderlyingWrites tests that each Writer flush only makes one or two Write calls on its underlying io.Writer, depending on whether or not the fl
snappy_test.go:1189
Function
TestReaderReadByte
(t *testing.T)
snappy_test.go:1040
Function
TestReaderReset
(t *testing.T)
snappy_test.go:1002
next →
1–100 of 117, ranked by callers