Skip to content

Commit

Permalink
Merge pull request #5 from fancycode/goconf_accessors
Browse files Browse the repository at this point in the history
Expose more goconf methods through the Config interface.
  • Loading branch information
fancycode committed Jun 1, 2016
2 parents c3429c4 + 32f30ad commit 31b7f25
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 0 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ go:
- 1.3
- 1.4
- 1.5
- 1.6
- tip

install:
- go get github.com/dlintw/goconf
Expand Down
3 changes: 3 additions & 0 deletions config.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ import (
// GetXXXDefault methods return dflt if the named option in section has no
// value. Use HasOption to determine the status of an option thus defaulted.
type Config interface {
HasSection(section string) bool
GetSections() []string
GetOptions(section string) ([]string, error)
HasOption(section, option string) bool
GetBool(section, option string) (bool, error)
GetBoolDefault(section, option string, dflt bool) bool
Expand Down

0 comments on commit 31b7f25

Please sign in to comment.