Documentation ¶
Index ¶
- func LoadContext(reader io.Reader) (*base.Context, error)
- func LoadContextFile(contextFile string) (*base.Context, error)
- func LoadStart() *base.Runner
- func LoadStartByContext(context *base.Context) *base.Runner
- func LoadStartByFile(typhonContextFile string) *base.Runner
- func LoadStartByFileE(typhonContextFile string) (*base.Runner, error)
- func LoadStartE() (*base.Runner, error)
- func ViperUnset(key string) error
- type ChangeType
- type DiffItem
- type ViperListener
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadContext ¶
LoadContext loads the typhon context by reader.
func LoadContextFile ¶
LoadContextFile load the typhon context by file contextFile
func LoadStartByContext ¶
LoadStartByContext load the runner from the context.
func LoadStartByFile ¶
LoadStartByFile loads and starts the typhon client.
func LoadStartByFileE ¶
LoadStartByFileE loads and starts the typhon client.
func LoadStartE ¶
LoadStartE loads and starts the typhon client.
Types ¶
type ChangeType ¶
type ChangeType int
ChangeType defines the type of chaging.
const ( // Modified ... Modified ChangeType = iota // Added ... Added // Removed ... Removed // Same ... Same )
type DiffItem ¶
type DiffItem struct { ChangeType ChangeType Key interface{} LeftValue interface{} RightValue interface{} }
DiffItem defines ChangeEvent for properties diff
type ViperListener ¶
type ViperListener struct {
Prefix string
}
ViperListener defines the viper setter listener
func (ViperListener) OnChange ¶
func (l ViperListener) OnChange(event base.ConfFileChangeEvent) (msg string, ok bool)
OnChange defines the callback when changes detected.
Click to show internal directories.
Click to hide internal directories.