Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActivityConf ¶
type ActivityConf struct {
tableau.ActivityConf
}
func (*ActivityConf) CheckCompatibility ¶
func (x *ActivityConf) CheckCompatibility(hub, newHub *tableau.Hub) error
type ChapterConf ¶
type ChapterConf struct {
tableau.ChapterConf
}
func (*ChapterConf) CheckCompatibility ¶
func (x *ChapterConf) CheckCompatibility(hub, newHub *tableau.Hub) error
type Option ¶
type Option func(*Options)
Option is the functional option type.
func BreakFailedCount ¶
BreakFailedCount sets BreakFailedCount option.
func Filter ¶
func Filter(filter load.FilterFunc) Option
Filter can only filter in certain specific messagers based on the condition that you provide.
func IgnoreUnknownFields ¶
func IgnoreUnknownFields() Option
IgnoreUnknownFields sets IgnoreUnknownFields option as true.
func Paths ¶
Paths maps each messager name to a corresponding config file path. If specified, then the main messager will be parsed from the file directly, other than the specified load dir.
NOTE: only JSON, Bin, and Text formats are supported.
func ProtoPackage ¶
ProtoPackage sets ProtoPackage option.
func SkipLoadErrors ¶
func SkipLoadErrors() Option
SkipLoadErrors sets SkipLoadErrors option as true.
func SubdirRewrites ¶
SubdirRewrites sets SubdirRewrites option.
type Options ¶
type Options struct { // Filter can only filter in certain specific messagers based on the // condition that you provide. // // Default: nil. Filter load.FilterFunc // Break check loop if failed count is equal to or more than BreakFailedCount. // // Default: 1. BreakFailedCount int // Rewrite subdir path (relative to workbook name option in .proto file). // // Default: nil. SubdirRewrites map[string]string // The proto package name of .proto files. // // Default: "protoconf". ProtoPackage string // Whether to ignore unknown JSON fields during parsing. // // Default: false. IgnoreUnknownFields bool // Whether to ignore errors during loading. // // Errors may occur during loading old config files when do compatibility // check. For example, some new worksheets you recently add are not // existed, or proto schema are not compatible, just ignore the loading // errors (then these proto message objects are nil after loading), so that // compatibility check can continue to run. // // Default: false. SkipLoadErrors bool // Paths maps each messager name to a corresponding config file path. // If specified, then the main messager will be parsed from the file // directly, other than the specified load dir. // // NOTE: only JSON, Bin, and Text formats are supported. // // Default: nil. Paths map[string]string }
func ParseOptions ¶
ParseOptions parses functional options and merge them to default Options.