ods

package module
v0.0.0-...-b65f8a6 Latest Latest
Warning

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

Go to latest
Published: May 10, 2021 License: BSD-2-Clause Imports: 5 Imported by: 3

README

ods2csv

This is a Go package to read contents of a .ods (openoffice spreadsheet) file. Formula, value or date in a cell can be accessed. See example for usage. This library is made to demonstrate the capability of "https://github.com/LIJUCHACKO/XmlDB" (A native xml database)

Note: Merged cells are not support

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadSheetThread

func ReadSheetThread(DB *xmlDB.Database, spreadsheet int, chres chan Result)

func ReplaceHTMLSpecialEntities

func ReplaceHTMLSpecialEntities(input string) string

Types

type Cell

type Cell struct {
	Type      string //Type float,string ...    ( office:value-type= )
	Value     string //Value                    ( office:value= )
	DateValue string //DateValue                ( office:date-value= )
	Formula   string //formula                  ( table:formula= )
	Text      string //Text

}

type Odsfile

type Odsfile struct {
	Sheets []Sheet
}

func ReadODSFile

func ReadODSFile(odsfilename string) (Odsfile, error)

type Result

type Result struct {
	Sheeti Sheet
	// contains filtered or unexported fields
}

type Row

type Row struct {
	Cells []Cell
}

type Sheet

type Sheet struct {
	Name string
	Rows []Row
}

func ReadSheet

func ReadSheet(DB *xmlDB.Database, spreadsheet int) (Sheet, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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