blocktype_string.go 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. // Code generated by "stringer -type=blockType,literalsBlockType,seqCompMode,tableIndex"; DO NOT EDIT.
  2. package zstd
  3. import "strconv"
  4. func _() {
  5. // An "invalid array index" compiler error signifies that the constant values have changed.
  6. // Re-run the stringer command to generate them again.
  7. var x [1]struct{}
  8. _ = x[blockTypeRaw-0]
  9. _ = x[blockTypeRLE-1]
  10. _ = x[blockTypeCompressed-2]
  11. _ = x[blockTypeReserved-3]
  12. }
  13. const _blockType_name = "blockTypeRawblockTypeRLEblockTypeCompressedblockTypeReserved"
  14. var _blockType_index = [...]uint8{0, 12, 24, 43, 60}
  15. func (i blockType) String() string {
  16. if i >= blockType(len(_blockType_index)-1) {
  17. return "blockType(" + strconv.FormatInt(int64(i), 10) + ")"
  18. }
  19. return _blockType_name[_blockType_index[i]:_blockType_index[i+1]]
  20. }
  21. func _() {
  22. // An "invalid array index" compiler error signifies that the constant values have changed.
  23. // Re-run the stringer command to generate them again.
  24. var x [1]struct{}
  25. _ = x[literalsBlockRaw-0]
  26. _ = x[literalsBlockRLE-1]
  27. _ = x[literalsBlockCompressed-2]
  28. _ = x[literalsBlockTreeless-3]
  29. }
  30. const _literalsBlockType_name = "literalsBlockRawliteralsBlockRLEliteralsBlockCompressedliteralsBlockTreeless"
  31. var _literalsBlockType_index = [...]uint8{0, 16, 32, 55, 76}
  32. func (i literalsBlockType) String() string {
  33. if i >= literalsBlockType(len(_literalsBlockType_index)-1) {
  34. return "literalsBlockType(" + strconv.FormatInt(int64(i), 10) + ")"
  35. }
  36. return _literalsBlockType_name[_literalsBlockType_index[i]:_literalsBlockType_index[i+1]]
  37. }
  38. func _() {
  39. // An "invalid array index" compiler error signifies that the constant values have changed.
  40. // Re-run the stringer command to generate them again.
  41. var x [1]struct{}
  42. _ = x[compModePredefined-0]
  43. _ = x[compModeRLE-1]
  44. _ = x[compModeFSE-2]
  45. _ = x[compModeRepeat-3]
  46. }
  47. const _seqCompMode_name = "compModePredefinedcompModeRLEcompModeFSEcompModeRepeat"
  48. var _seqCompMode_index = [...]uint8{0, 18, 29, 40, 54}
  49. func (i seqCompMode) String() string {
  50. if i >= seqCompMode(len(_seqCompMode_index)-1) {
  51. return "seqCompMode(" + strconv.FormatInt(int64(i), 10) + ")"
  52. }
  53. return _seqCompMode_name[_seqCompMode_index[i]:_seqCompMode_index[i+1]]
  54. }
  55. func _() {
  56. // An "invalid array index" compiler error signifies that the constant values have changed.
  57. // Re-run the stringer command to generate them again.
  58. var x [1]struct{}
  59. _ = x[tableLiteralLengths-0]
  60. _ = x[tableOffsets-1]
  61. _ = x[tableMatchLengths-2]
  62. }
  63. const _tableIndex_name = "tableLiteralLengthstableOffsetstableMatchLengths"
  64. var _tableIndex_index = [...]uint8{0, 19, 31, 48}
  65. func (i tableIndex) String() string {
  66. if i >= tableIndex(len(_tableIndex_index)-1) {
  67. return "tableIndex(" + strconv.FormatInt(int64(i), 10) + ")"
  68. }
  69. return _tableIndex_name[_tableIndex_index[i]:_tableIndex_index[i+1]]
  70. }