gotils

package module
v0.0.0-...-33ef2b4 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2017 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CsvReader

func CsvReader(buff io.Reader) ([][]string, error)

func CsvToMap

func CsvToMap(records [][]string) ([]map[string]interface{}, error)

func DatReader

func DatReader(data string, prefix DatReads) map[string]interface{}

func DatReaderDecode

func DatReaderDecode(data string, prefix DatReads, decodeFrom string, decodeTo string) map[string]interface{}

func DatToSliceDecode

func DatToSliceDecode(data string, prefix DatReads, decodeFrom string, decodeTo string) []string

func Open

func Open(filepath string) (io.Reader, error)

func ParseStruct

func ParseStruct(data map[string]interface{}, result interface{}) (interface{}, error)

func ReadLines

func ReadLines(buff io.Reader, decodeFrom string, decodeTo string) ([]string, error)

func ReadLinesMap

func ReadLinesMap(buff io.Reader, decodeFrom string, decodeTo string) (map[int]string, error)

func XMLDecode

func XMLDecode(data []byte, v interface{}) (interface{}, error)

XMLDecode - send v as address `&v`

Types

type DatRead

type DatRead struct {
	Name   string
	ReadAt ReadAt
}

type DatReads

type DatReads []DatRead

type ReadAt

type ReadAt struct {
	StartAt int
	EndAt   int
}

Jump to

Keyboard shortcuts

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