github.com/quay/claircore@v1.5.28/pkg/ovalutil/compressor_string.go (about) 1 // Code generated by "stringer -type Compressor -linecomment"; DO NOT EDIT. 2 3 package ovalutil 4 5 import "strconv" 6 7 func _() { 8 // An "invalid array index" compiler error signifies that the constant values have changed. 9 // Re-run the stringer command to generate them again. 10 var x [1]struct{} 11 _ = x[CompressionAuto-0] 12 _ = x[CompressionNone-1] 13 _ = x[CompressionGzip-2] 14 _ = x[CompressionBzip2-3] 15 _ = x[CompressionZstd-4] 16 } 17 18 const _Compressor_name = "autononegzipbzip2zstd" 19 20 var _Compressor_index = [...]uint8{0, 4, 8, 12, 17, 21} 21 22 func (i Compressor) String() string { 23 if i >= Compressor(len(_Compressor_index)-1) { 24 return "Compressor(" + strconv.FormatInt(int64(i), 10) + ")" 25 } 26 return _Compressor_name[_Compressor_index[i]:_Compressor_index[i+1]] 27 }