mirror of
https://github.com/grafana/grafana.git
synced 2024-11-25 10:20:29 -06:00
108acee08e
* Initial GCM schema work - Split types for convenience - Update conditionals where needed - Update type references * Add additional supporting types * Add some more accessory and legacy types * Add missing type * Rename backend folder * Add missing generated file * Review
23 lines
440 B
Go
23 lines
440 B
Go
package cloudmonitoring
|
|
|
|
type preprocessorType int
|
|
|
|
const (
|
|
PreprocessorTypeNone preprocessorType = iota
|
|
PreprocessorTypeRate
|
|
PreprocessorTypeDelta
|
|
)
|
|
|
|
func toPreprocessorType(preprocessorTypeString string) preprocessorType {
|
|
switch preprocessorTypeString {
|
|
case "none":
|
|
return PreprocessorTypeNone
|
|
case "rate":
|
|
return PreprocessorTypeRate
|
|
case "delta":
|
|
return PreprocessorTypeDelta
|
|
default:
|
|
return PreprocessorTypeNone
|
|
}
|
|
}
|