csvreader

package
v0.0.0-...-1bdabf6 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2015 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Overview

csvreader reads the "provincia" files on a local directory decodes the csv and stores them in a Redis database.

Index

Constants

View Source
const (
	//IP Addres and port where the Redis Data base can be located.
	ADDRESS = "127.0.0.1:6379"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PadronCsvReader

type PadronCsvReader struct {
	TmpDir string
	// contains filtered or unexported fields
}

PadronCsvReader acts as an object container for this package

func NewPadronCsvReader

func NewPadronCsvReader(provincia string) *PadronCsvReader

NewPadronCsvReader creates a reader for the cvs donloaded for each "provincia".

func (*PadronCsvReader) ReadDistElectoral

func (p *PadronCsvReader) ReadDistElectoral()

ReadDistElectoral read the electoral codes from the Distelect file and stores the results in a CodeElectT struct that is later saved in a map that is eventually used by ReadProvincia to decode the eleccode into real places names.

func (*PadronCsvReader) ReadProvincia

func (p *PadronCsvReader) ReadProvincia()

ReadProvincia reads de csv for a provincia and stores the results in a Redis database

Jump to

Keyboard shortcuts

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