/
githubmirror
/
rclone
Обзор
Документация
Войти
/
githubmirror
/
rclone
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
fs/cutoffmode.go
22 строки
456 B
Nick Craig-Wood
fs: re-implement CutoffMode, LogLevel, TerminalColorMode with Enum
03 окт 2023, 17:14
03 окт 2023, 17:14
3092f82
Код
Авторство
О чём код?
package fs type cutoffModeChoices struct{} func (cutoffModeChoices) Choices() []string { return []string{ CutoffModeHard: "HARD", CutoffModeSoft: "SOFT", CutoffModeCautious: "CAUTIOUS", } } // CutoffMode describes the possible delete modes in the config type CutoffMode = Enum[cutoffModeChoices] // CutoffMode constants const ( CutoffModeHard CutoffMode = iota CutoffModeSoft CutoffModeCautious CutoffModeDefault = CutoffModeHard )