core

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitializeSqliteDatabase

func InitializeSqliteDatabase(databasePath string, logLevel log.Level) (*gorm.DB, error)

func ParseStaticGtfsFromPath

func ParseStaticGtfsFromPath(path string) (*model.GtfsStaticFeed, error)

Parses a static GTFS feed into a struct. Handles a local folder, or local zipped file

func ParseStaticGtfsFromUrl

func ParseStaticGtfsFromUrl(url string) (*model.GtfsStaticFeed, error)

func Store

func Store(sqliteDbPath string, staticGtfsUrl string, logLevel log.Level) error

func WriteStaticGtfsFeedToDatabase

func WriteStaticGtfsFeedToDatabase(feed *model.GtfsStaticFeed, db *gorm.DB) error

Types

type GtfsFile

type GtfsFile struct {
	Name    string
	FileObj io.ReadSeeker
}

type GtfsFileCollection

type GtfsFileCollection struct {
	GtfsFiles []GtfsFile
}

Jump to

Keyboard shortcuts

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