readini

package
v0.0.0-...-0a9a6cf Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2016 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Element

type Element map[string]string

section下面的键值对

type IniFile

type IniFile struct {
	Object map[string][]Element
	// contains filtered or unexported fields
}

ini文件结构(对象) section为key

func NewIniFile

func NewIniFile() *IniFile

IniFile的构造函数

func (*IniFile) GetSection

func (i *IniFile) GetSection() []string

获取所有的Section

func (*IniFile) GetValue

func (i *IniFile) GetValue(section string) (string, []Element)

获取section下的键值对数据

func (*IniFile) GetValueInSection

func (i *IniFile) GetValueInSection(section, key string) (string, string)

获取某个section下的某个键的值

func (*IniFile) Parse

func (i *IniFile) Parse(str string)

解析一行中的内容

func (*IniFile) Readfile

func (i *IniFile) Readfile(filename string)

读取文件

Jump to

Keyboard shortcuts

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