Documentation
¶
Index ¶
- Variables
- type BlankSectionNameError
- type EntryNotInSectionError
- type InvalidKeyError
- type InvalidValueError
- type KeyFile
- func (f *KeyFile) DeleteKey(section, key string) bool
- func (f *KeyFile) DeleteSection(section string) bool
- func (f *KeyFile) GetBool(section, key string) (bool, error)
- func (f *KeyFile) GetBoolList(section, key string) ([]bool, error)
- func (f *KeyFile) GetFloat64(section, key string) (float64, error)
- func (f *KeyFile) GetFloat64List(section, key string) ([]float64, error)
- func (f *KeyFile) GetInt(section, key string) (int, error)
- func (f *KeyFile) GetInt64(section, key string) (int64, error)
- func (f *KeyFile) GetIntList(section, key string) ([]int, error)
- func (f *KeyFile) GetKeyComments(section, key string) string
- func (f *KeyFile) GetKeys(section string) []string
- func (f *KeyFile) GetLocaleString(section, key, locale string) (string, error)
- func (f *KeyFile) GetLocaleStringList(section, key, locale string) ([]string, error)
- func (f *KeyFile) GetSection(section string) (map[string]string, error)
- func (f *KeyFile) GetSectionComments(section string) string
- func (f *KeyFile) GetSections() []string
- func (f *KeyFile) GetString(section, key string) (string, error)
- func (f *KeyFile) GetStringList(section, key string) ([]string, error)
- func (f *KeyFile) GetUint64(section, key string) (uint64, error)
- func (f *KeyFile) GetValue(section, key string) (string, error)
- func (f *KeyFile) LoadFromData(data []byte) error
- func (f *KeyFile) LoadFromFile(filename string) error
- func (f *KeyFile) LoadFromReader(reader io.Reader) error
- func (kf *KeyFile) SaveToFile(file string) error
- func (f *KeyFile) SaveToWriter(w io.Writer) error
- func (f *KeyFile) SetBool(section, key string, value bool)
- func (f *KeyFile) SetBoolList(section, key string, values []bool)
- func (f *KeyFile) SetFloat64(section, key string, value float64)
- func (f *KeyFile) SetFloat64List(section, key string, values []float64)
- func (f *KeyFile) SetInt(section, key string, value int)
- func (f *KeyFile) SetInt64(section, key string, value int64)
- func (f *KeyFile) SetIntList(section, key string, values []int)
- func (f *KeyFile) SetKeyComments(section, key, comments string) bool
- func (f *KeyFile) SetSectionComments(section, comments string) bool
- func (f *KeyFile) SetString(section, key, value string)
- func (f *KeyFile) SetStringList(section, key string, values []string)
- func (f *KeyFile) SetUint64(section, key string, value uint64)
- func (f *KeyFile) SetValue(section, key, value string) bool
- type KeyNotFoundError
- type ParseError
- type SectionNotFoundError
- type ValueInvalidUTF8Error
Constants ¶
This section is empty.
Variables ¶
View Source
var LineBreak = "\n"
Functions ¶
This section is empty.
Types ¶
type BlankSectionNameError ¶
type BlankSectionNameError struct{}
func (BlankSectionNameError) Error ¶
func (err BlankSectionNameError) Error() string
type EntryNotInSectionError ¶
type EntryNotInSectionError struct {
Line string
}
func (EntryNotInSectionError) Error ¶
func (err EntryNotInSectionError) Error() string
type InvalidKeyError ¶
type InvalidKeyError struct {
Key string
}
func (InvalidKeyError) Error ¶
func (err InvalidKeyError) Error() string
type InvalidValueError ¶
type InvalidValueError struct {
Value string
}
func (InvalidValueError) Error ¶
func (err InvalidValueError) Error() string
type KeyFile ¶
type KeyFile struct { ListSeparator byte // contains filtered or unexported fields }
func NewKeyFile ¶
func NewKeyFile() *KeyFile
func (*KeyFile) DeleteSection ¶
It returns true if the section was deleted, and false if the section didn't exist
func (*KeyFile) GetFloat64List ¶
func (*KeyFile) GetKeyComments ¶
func (*KeyFile) GetLocaleString ¶
func (*KeyFile) GetLocaleStringList ¶
func (*KeyFile) GetSection ¶
func (*KeyFile) GetSectionComments ¶
func (*KeyFile) GetSections ¶
func (*KeyFile) GetStringList ¶
func (*KeyFile) LoadFromData ¶
func (*KeyFile) LoadFromFile ¶
func (*KeyFile) SaveToFile ¶
func (*KeyFile) SetBoolList ¶
func (*KeyFile) SetFloat64 ¶
func (*KeyFile) SetFloat64List ¶
func (*KeyFile) SetIntList ¶
func (*KeyFile) SetKeyComments ¶
func (*KeyFile) SetSectionComments ¶
func (*KeyFile) SetStringList ¶
type KeyNotFoundError ¶
type KeyNotFoundError struct {
Name string
}
func (KeyNotFoundError) Error ¶
func (err KeyNotFoundError) Error() string
type ParseError ¶
type ParseError struct {
Line string
}
func (ParseError) Error ¶
func (err ParseError) Error() string
type SectionNotFoundError ¶
type SectionNotFoundError struct {
Name string
}
func (SectionNotFoundError) Error ¶
func (err SectionNotFoundError) Error() string
type ValueInvalidUTF8Error ¶
func (ValueInvalidUTF8Error) Error ¶
func (err ValueInvalidUTF8Error) Error() string
Click to show internal directories.
Click to hide internal directories.