func (s DiamondState) IsValid() bool {
	switch s {
	case DiamondInitialized, DiamondDone, DiamondCanceled:
		return true
	default:
		return false
	}
}
IsValid checks the value of a diamond state
package model
import (
	"fmt"
	"path"
	"time"
	"github.com/segmentio/ksuid"
)
type ConflictMode string
const (
	IgnoreConflicts ConflictMode = "ignored"
	EnableCheckpoints ConflictMode = "enable-checkpoints"
	EnableConflicts ConflictMode = "enable-conflicts"
	ForbidConflicts ConflictMode = "forbids-conflicts"
)
type DiamondState string
const (
	DiamondInitialized DiamondState = "initialized"
	DiamondDone DiamondState = "done"
	DiamondCanceled DiamondState = "canceled"
)
const (
	done                         = "done"
	running                      = "running"
	ext                          = ".yaml"
	diamondPrefix                = "diamond-"
	splitPrefix                  = "split-"
	diamondFinalDescriptorFile   = diamondPrefix + done + ext
	splitFinalDescriptorFile     = splitPrefix + done + ext
	diamondInitialDescriptorFile = diamondPrefix + running + ext
	splitInitialDescriptorFile   = splitPrefix + running + ext
)