file

package
v0.0.0-...-d69b078 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 12, 2015 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConfStore

func NewConfStore() engine.ConfStore

NewConfStore returns a new file ConfStore object

func NewReader

func NewReader(filelist []string) io.Reader

func RegisterConfStore

func RegisterConfStore()

RegisterConfStore returns the module name

func RegisterConfigDecoder

func RegisterConfigDecoder()

RegisterConfigDecoder with the engine.

Types

type ConfStore

type ConfStore struct {
	Config *Config
	// contains filtered or unexported fields
}

ConfStore object

func (*ConfStore) Setup

func (cs *ConfStore) Setup(eng *engine.Engine, cfg engine.Config) error

Setup the file confstore

func (*ConfStore) Start

func (cs *ConfStore) Start() error

Start the ConfStore

func (*ConfStore) Stop

func (cs *ConfStore) Stop() error

Stop the ConfStore

type Config

type Config struct {
	LogOutput string `mapstructure:"log_output" version:"1"`
	ConfigDir string `mapstructure:"config_dir" version:"1"`
	Watch     bool   `mapstructure:"watch" version:"1"`
}

Config ...

func NewConfig

func NewConfig() *Config

NewConfig returns a stacker Config with defaults

func (*Config) Hash

func (sc *Config) Hash() string

Hash returns the unique hash for this config object

func (*Config) Target

func (c *Config) Target() *engine.NameSpace

Target returns the namespace of the target of this config

func (*Config) Version

func (sc *Config) Version() int

Version ...

type Decoder

type Decoder struct{}

Decoder ...

func (*Decoder) DecodeConfig

func (d *Decoder) DecodeConfig(data interface{}) (engine.Config, error)

DecodeConfig returns a parsed config object

type File

type File struct {
	Path string
	MD5  string
}

File represents a single config file

type Reader

type Reader struct {
	// contains filtered or unexported fields
}

Reader reads

func (*Reader) Read

func (r *Reader) Read(p []byte) (n int, err error)

Read reads data into p

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL