tables

package
v2.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2024 License: BSD-3-Clause Imports: 16 Imported by: 3

Documentation

Overview

package tables implements the `FeatureTable interface` interface for indexing Who's On First Feature records in SQLite database tables.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeginTransactionError

func BeginTransactionError(t sqlite.Table, err error) error

BeginTransactionError returns a new error with a default message for database transaction initialization problems wrapping 'err' and prepending with the value of 't's Name() method.

func CommitTransactionError

func CommitTransactionError(t sqlite.Table, err error) error

CommitTransactionError returns a new error with a default message for problems committing database transactions wrapping 'err' and prepending with the value of 't's Name() method.

func CommonTablesWithDatabase

func CommonTablesWithDatabase(ctx context.Context, db sqlite.Database) ([]sqlite.Table, error)

func CommonTablesWithDatabaseAndOptions

func CommonTablesWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, table_opts *CommonTablesOptions) ([]sqlite.Table, error)

func DatabaseConnectionError

func DatabaseConnectionError(t sqlite.Table, err error) error

DatabaseConnectionError returns a new error with a default message for database connection problems wrapping 'err' and prepending with the value of 't's Name() method.

func ExecuteStatementError

func ExecuteStatementError(t sqlite.Table, err error) error

ExecuteStatementError returns a new error with a default message for problems executing database (SQL) statements wrapping 'err' and prepending with the value of 't's Name() method.

func InitializeTableError

func InitializeTableError(t sqlite.Table, err error) error

InitializeTableError returns a new error with a default message for database initialization problems wrapping 'err' and prepending with the value of 't's Name() method.

func MissingPropertyError

func MissingPropertyError(t sqlite.Table, prop string, err error) error

MissingPropertyError returns a new error with a default message for problems deriving a given property ('prop') from a record, wrapping 'err' and prepending with the value of 't's Name() method.

func NewAncestorsTable

func NewAncestorsTable(ctx context.Context) (sqlite.Table, error)

func NewAncestorsTableWithDatabase

func NewAncestorsTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewConcordancesTable

func NewConcordancesTable(ctx context.Context) (sqlite.Table, error)

func NewConcordancesTableWithDatabase

func NewConcordancesTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewGeoJSONTable

func NewGeoJSONTable(ctx context.Context) (sqlite.Table, error)

func NewGeoJSONTableWithDatabase

func NewGeoJSONTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewGeoJSONTableWithDatabaseAndOptions

func NewGeoJSONTableWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *GeoJSONTableOptions) (sqlite.Table, error)

func NewGeoJSONTableWithOptions

func NewGeoJSONTableWithOptions(ctx context.Context, opts *GeoJSONTableOptions) (sqlite.Table, error)

func NewGeometriesTable

func NewGeometriesTable(ctx context.Context) (sqlite.Table, error)

func NewGeometriesTableWithDatabase

func NewGeometriesTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewGeometriesTableWithDatabaseAndOptions

func NewGeometriesTableWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *GeometriesTableOptions) (sqlite.Table, error)

func NewGeometriesTableWithOptions

func NewGeometriesTableWithOptions(ctx context.Context, opts *GeometriesTableOptions) (sqlite.Table, error)

func NewNamesTable

func NewNamesTable(ctx context.Context) (sqlite.Table, error)

func NewNamesTableWithDatabase

func NewNamesTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewPropertiesTable

func NewPropertiesTable(ctx context.Context) (sqlite.Table, error)

func NewPropertiesTableWithDatabase

func NewPropertiesTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewPropertiesTableWithDatabaseAndOptions

func NewPropertiesTableWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *PropertiesTableOptions) (sqlite.Table, error)

func NewPropertiesTableWithOptions

func NewPropertiesTableWithOptions(ctx context.Context, opts *PropertiesTableOptions) (sqlite.Table, error)

func NewRTreeTable

func NewRTreeTable(ctx context.Context) (sqlite.Table, error)

func NewRTreeTableWithDatabase

func NewRTreeTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewRTreeTableWithDatabaseAndOptions

func NewRTreeTableWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *RTreeTableOptions) (sqlite.Table, error)

func NewRTreeTableWithOptions

func NewRTreeTableWithOptions(ctx context.Context, opts *RTreeTableOptions) (sqlite.Table, error)

func NewSPRTable

func NewSPRTable(ctx context.Context) (sqlite.Table, error)

func NewSPRTableWithDatabase

func NewSPRTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewSPRTableWithDatabaseAndOptions

func NewSPRTableWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *SPRTableOptions) (sqlite.Table, error)

func NewSPRTableWithOptions

func NewSPRTableWithOptions(ctx context.Context, opts *SPRTableOptions) (sqlite.Table, error)

func NewSearchTable

func NewSearchTable(ctx context.Context) (sqlite.Table, error)

func NewSearchTableWithDatabase

func NewSearchTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func NewSupersedesTable

func NewSupersedesTable(ctx context.Context) (sqlite.Table, error)

func NewSupersedesTableWithDatabase

func NewSupersedesTableWithDatabase(ctx context.Context, db sqlite.Database) (sqlite.Table, error)

func PointInPolygonTablesWithDatabase

func PointInPolygonTablesWithDatabase(ctx context.Context, db sqlite.Database) ([]sqlite.Table, error)

func PrepareStatementError

func PrepareStatementError(t sqlite.Table, err error) error

PrepareStatementError returns a new error with a default message for problems preparing database (SQL) statements wrapping 'err' and prepending with the value of 't's Name() method.

func RTreeTablesWithDatabase

func RTreeTablesWithDatabase(ctx context.Context, db sqlite.Database) ([]sqlite.Table, error)

func RTreeTablesWithDatabaseAndOptions

func RTreeTablesWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *TableOptions) ([]sqlite.Table, error)

func SearchTablesWithDatabase

func SearchTablesWithDatabase(ctx context.Context, db sqlite.Database) ([]sqlite.Table, error)

func SearchTablesWithDatabaseAndOptions

func SearchTablesWithDatabaseAndOptions(ctx context.Context, db sqlite.Database, opts *TableOptions) ([]sqlite.Table, error)

func SpatialTablesWithDatabase

func SpatialTablesWithDatabase(ctx context.Context, db sqlite.Database) ([]sqlite.Table, error)

func WrapError

func WrapError(t sqlite.Table, err error) error

WrapError returns a new error wrapping 'err' and prepending with the value of 't's Name() method.

Types

type AncestorsRow

type AncestorsRow struct {
	Id                int64
	AncestorID        int64
	AncestorPlacetype string
	LastModified      int64
}

type AncestorsTable

type AncestorsTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*AncestorsTable) IndexFeature

func (t *AncestorsTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*AncestorsTable) IndexRecord

func (t *AncestorsTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*AncestorsTable) InitializeTable

func (t *AncestorsTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*AncestorsTable) Name

func (t *AncestorsTable) Name() string

func (*AncestorsTable) Schema

func (t *AncestorsTable) Schema() string

type CommonTablesOptions

type CommonTablesOptions struct {
	GeoJSON       *GeoJSONTableOptions // DEPRECATED
	IndexAltFiles bool
}

type ConcordancesRow

type ConcordancesRow struct {
	Id           int64
	OtherID      string
	OtherSource  string
	LastModified int64
}

type ConcordancesTable

type ConcordancesTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*ConcordancesTable) IndexFeature

func (t *ConcordancesTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*ConcordancesTable) IndexRecord

func (t *ConcordancesTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*ConcordancesTable) InitializeTable

func (t *ConcordancesTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*ConcordancesTable) Name

func (t *ConcordancesTable) Name() string

func (*ConcordancesTable) Schema

func (t *ConcordancesTable) Schema() string

type GeoJSONRow

type GeoJSONRow struct {
	Id           int64
	Body         string
	LastModified int64
}

type GeoJSONTable

type GeoJSONTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*GeoJSONTable) IndexFeature

func (t *GeoJSONTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*GeoJSONTable) IndexRecord

func (t *GeoJSONTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*GeoJSONTable) InitializeTable

func (t *GeoJSONTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*GeoJSONTable) Name

func (t *GeoJSONTable) Name() string

func (*GeoJSONTable) Schema

func (t *GeoJSONTable) Schema() string

type GeoJSONTableOptions

type GeoJSONTableOptions struct {
	IndexAltFiles          bool
	AllowMissingSourceGeom bool
}

func DefaultGeoJSONTableOptions

func DefaultGeoJSONTableOptions() (*GeoJSONTableOptions, error)

type GeometriesRow

type GeometriesRow struct {
	Id           int64
	Body         string
	LastModified int64
}

type GeometriesTable

type GeometriesTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*GeometriesTable) IndexFeature

func (t *GeometriesTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*GeometriesTable) IndexRecord

func (t *GeometriesTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*GeometriesTable) InitializeTable

func (t *GeometriesTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*GeometriesTable) Name

func (t *GeometriesTable) Name() string

func (*GeometriesTable) Schema

func (t *GeometriesTable) Schema() string

type GeometriesTableOptions

type GeometriesTableOptions struct {
	IndexAltFiles bool
}

func DefaultGeometriesTableOptions

func DefaultGeometriesTableOptions() (*GeometriesTableOptions, error)

type NamesRow

type NamesRow struct {
	Id           int64
	Placetype    string
	Country      string
	Language     string
	ExtLang      string
	Script       string
	Region       string
	Variant      string
	Extension    string
	PrivateUse   string
	Name         string
	LastModified int64
}

type NamesTable

type NamesTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*NamesTable) IndexFeature

func (t *NamesTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*NamesTable) IndexRecord

func (t *NamesTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*NamesTable) InitializeTable

func (t *NamesTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*NamesTable) Name

func (t *NamesTable) Name() string

func (*NamesTable) Schema

func (t *NamesTable) Schema() string

type PropertiesRow

type PropertiesRow struct {
	Id           int64
	Body         string
	LastModified int64
}

type PropertiesTable

type PropertiesTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*PropertiesTable) IndexFeature

func (t *PropertiesTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*PropertiesTable) IndexRecord

func (t *PropertiesTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*PropertiesTable) InitializeTable

func (t *PropertiesTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*PropertiesTable) Name

func (t *PropertiesTable) Name() string

func (*PropertiesTable) Schema

func (t *PropertiesTable) Schema() string

type PropertiesTableOptions

type PropertiesTableOptions struct {
	IndexAltFiles bool
}

func DefaultPropertiesTableOptions

func DefaultPropertiesTableOptions() (*PropertiesTableOptions, error)

type RTreeTable

type RTreeTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*RTreeTable) IndexFeature

func (t *RTreeTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*RTreeTable) IndexRecord

func (t *RTreeTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*RTreeTable) InitializeTable

func (t *RTreeTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*RTreeTable) Name

func (t *RTreeTable) Name() string

func (*RTreeTable) Schema

func (t *RTreeTable) Schema() string

type RTreeTableOptions

type RTreeTableOptions struct {
	IndexAltFiles bool
}

func DefaultRTreeTableOptions

func DefaultRTreeTableOptions() (*RTreeTableOptions, error)

type SPRTable

type SPRTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*SPRTable) IndexFeature

func (t *SPRTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*SPRTable) IndexRecord

func (t *SPRTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*SPRTable) InitializeTable

func (t *SPRTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*SPRTable) Name

func (t *SPRTable) Name() string

func (*SPRTable) Schema

func (t *SPRTable) Schema() string

type SPRTableOptions

type SPRTableOptions struct {
	IndexAltFiles bool
}

func DefaultSPRTableOptions

func DefaultSPRTableOptions() (*SPRTableOptions, error)

type SearchTable

type SearchTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*SearchTable) IndexFeature

func (t *SearchTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*SearchTable) IndexRecord

func (t *SearchTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*SearchTable) InitializeTable

func (t *SearchTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*SearchTable) Name

func (t *SearchTable) Name() string

func (*SearchTable) Schema

func (t *SearchTable) Schema() string

type SupersedesTable

type SupersedesTable struct {
	features.FeatureTable
	// contains filtered or unexported fields
}

func (*SupersedesTable) IndexFeature

func (t *SupersedesTable) IndexFeature(ctx context.Context, db sqlite.Database, f []byte) error

func (*SupersedesTable) IndexRecord

func (t *SupersedesTable) IndexRecord(ctx context.Context, db sqlite.Database, i interface{}) error

func (*SupersedesTable) InitializeTable

func (t *SupersedesTable) InitializeTable(ctx context.Context, db sqlite.Database) error

func (*SupersedesTable) Name

func (t *SupersedesTable) Name() string

func (*SupersedesTable) Schema

func (t *SupersedesTable) Schema() string

type TableOptions

type TableOptions struct {
	IndexAltFiles bool
}

Jump to

Keyboard shortcuts

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