voteresult_string.go 679 B

1234567891011121314151617181920212223242526
  1. // Code generated by "stringer -type=VoteResult"; DO NOT EDIT.
  2. package quorum
  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[VotePending-1]
  9. _ = x[VoteLost-2]
  10. _ = x[VoteWon-3]
  11. }
  12. const _VoteResult_name = "VotePendingVoteLostVoteWon"
  13. var _VoteResult_index = [...]uint8{0, 11, 19, 26}
  14. func (i VoteResult) String() string {
  15. i -= 1
  16. if i >= VoteResult(len(_VoteResult_index)-1) {
  17. return "VoteResult(" + strconv.FormatInt(int64(i+1), 10) + ")"
  18. }
  19. return _VoteResult_name[_VoteResult_index[i]:_VoteResult_index[i+1]]
  20. }