importer

package
v0.0.0-...-9bb202a Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2024 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CurrentMeeting model.EasyWkMeeting

Functions

func GetPdfFileContent

func GetPdfFileContent(file string) (string, error)

GetPdfFileContent fetches pdf from source (local path or online source) and returns content as text string

func GetPdfReader

func GetPdfReader(file string) (*pdf.Reader, error)

GetPdfReader fetches pdf from source (local path or online source) and returns pdf.Reader

func ImportDsvDefinitionFile

func ImportDsvDefinitionFile(file string, meeting string, exclude []int, include []int) (*importModel.ImportFileStats, error)

func ImportDsvResultFile

func ImportDsvResultFile(file string, meeting string, exclude []int, include []int) (*importModel.ImportFileStats, error)

func ImportPdfResultList

func ImportPdfResultList(text string, meeting string, exclude []int, include []int, stg importModel.ImportPdfResultListSettings) (*importModel.ImportFileStats, error)

ImportPdfResultList takes the path to a pdf file that contains a result list. All teams, athletes and results will be imported. If exclude is set, given event numbers will be excluded from import. If include is set, only given event numbers will be imported.

For import process details see documentation on GitHub.

func ImportPdfResultListFile

func ImportPdfResultListFile(file string, meeting string, exclude []int, include []int, stg importModel.ImportPdfResultListSettings) (*importModel.ImportFileStats, error)

ImportPdfResultListFile takes the path to a pdf file that contains a result list and runs the import ImportPdfResultList

func ImportPdfStartList

func ImportPdfStartList(text string, meeting string, exclude []int, include []int, stg importModel.ImportPdfStartListSettings) (*importModel.ImportFileStats, error)

ImportPdfStartList takes the path to a pdf file that contains a start list. All events, teams, athletes, heats and starts will be imported. If exclude is set, given event numbers will be excluded from import. If include is set, only given event numbers will be imported.

For import process details see documentation on GitHub.

func ImportPdfStartListFile

func ImportPdfStartListFile(file string, meeting string, exclude []int, include []int, stg importModel.ImportPdfStartListSettings) (*importModel.ImportFileStats, error)

ImportPdfStartListFile takes the path to a pdf file that contains a start list and runs the import ImportPdfStartList

func ImportResult

func ImportResult(event int, heat int, lane int, time time.Duration, meter int, reaction bool, finished bool) error

func IsEventImportable

func IsEventImportable(ev int, ex []int, in []int) bool

func ReadPdf

func ReadPdf(path string) (string, error)

ReadPdf opens pdf under given path and reads plain text to a buffer and returns content as string

func SetEasyWkMeeting

func SetEasyWkMeeting()

func SetHeatFinishTime

func SetHeatFinishTime(event int, heat int) error

func SetHeatStartTime

func SetHeatStartTime(event int, heat int) error

func SetHeatTime

func SetHeatTime(event int, heatNumber int, startAt time.Time, finishedAt time.Time) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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