github.com/minio/minio@v0.0.0-20240328213742-3f72439b8a27/cmd/rebalstatus_string.go (about)

     1  // Code generated by "stringer -type=rebalStatus -trimprefix=rebal erasure-server-pool-rebalance.go"; DO NOT EDIT.
     2  
     3  package cmd
     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[rebalNone-0]
    12  	_ = x[rebalStarted-1]
    13  	_ = x[rebalCompleted-2]
    14  	_ = x[rebalStopped-3]
    15  	_ = x[rebalFailed-4]
    16  }
    17  
    18  const _rebalStatus_name = "NoneStartedCompletedStoppedFailed"
    19  
    20  var _rebalStatus_index = [...]uint8{0, 4, 11, 20, 27, 33}
    21  
    22  func (i rebalStatus) String() string {
    23  	if i >= rebalStatus(len(_rebalStatus_index)-1) {
    24  		return "rebalStatus(" + strconv.FormatInt(int64(i), 10) + ")"
    25  	}
    26  	return _rebalStatus_name[_rebalStatus_index[i]:_rebalStatus_index[i+1]]
    27  }