Documentation ¶
Overview ¶
Package xlsx implements excel file readers in starlark
outline: xlsx xlsx implements excel file readers in starlark. currently a highly-experimental package that will definitely change at some point in the future functions: get_url(url string) fetch an excel file from a url types: File an excel file methods: get_sheets() dict return a dict of sheets in this excel file get_rows(sheetname) list get all populated rows / columns as a list-of-list strings
Index ¶
Constants ¶
View Source
const ModuleName = "xlsx.star"
ModuleName defines the expected name for this Module when used in starlark's load() function, eg: load('xlsx.star', 'xlsx')
Variables ¶
This section is empty.
Functions ¶
Types ¶
type File ¶
type File struct {
// contains filtered or unexported fields
}
File is an xlsx-format excel file
func (*File) GetRows ¶
func (f *File) GetRows(thread *starlark.Thread, _ *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (starlark.Value, error)
GetRows grabs rows for a given sheet
func (*File) GetSheets ¶
func (f *File) GetSheets(thread *starlark.Thread, _ *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (starlark.Value, error)
GetSheets returns a map of ints to sheet names, sheet numbers are 1-based
func (*File) Struct ¶
func (f *File) Struct() *starlarkstruct.Struct
Struct turns a file into a *starlark.Struct
type Module ¶
type Module struct { }
Module joins http tools to a dataset, allowing dataset to follow along with http requests
func (*Module) GetURL ¶
func (m *Module) GetURL(thread *starlark.Thread, _ *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (starlark.Value, error)
GetURL gets a file for a given URL
func (*Module) StringDict ¶
func (m *Module) StringDict() starlark.StringDict
StringDict returns all module methods in a starlark.StringDict
func (*Module) Struct ¶
func (m *Module) Struct() *starlarkstruct.Struct
Struct returns this module's methods as a starlark Struct
Click to show internal directories.
Click to hide internal directories.