api

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CantabularMetadataDatasetReadPermission string = "cantabularmetadatadataset:read"
)

Variables

This section is empty.

Functions

func OverrideMetadataTable

func OverrideMetadataTable(dims []string, mt *cantabular.MetadataTableQuery) error

OverrideMetadataTable modifies the dimensions and results of the MetadataTableQuery to always use "ltla". This is the geocode used in the recipe and we need to ensure the result from the metadata server matches the recipe. This ensures also the following GetMetadataDataset uses "ltla".

Types

type CantMetaAPI added in v1.1.0

type CantMetaAPI interface {
	MetadataDatasetQuery(ctx context.Context, req cantabular.MetadataDatasetQueryRequest) (*cantabular.MetadataDatasetQuery, error)
	MetadataTableQuery(ctx context.Context, req cantabular.MetadataTableQueryRequest) (*cantabular.MetadataTableQuery, error)
}

cantExtAPI

type CantabularMetadataExtractorAPI

type CantabularMetadataExtractorAPI struct {
	Router      *mux.Router
	CantMetaAPI CantMetaAPI
	Cfg         *config.Config
	// contains filtered or unexported fields
}

func Setup

Setup function sets up the api and returns an api

func (*CantabularMetadataExtractorAPI) GetMetadata added in v1.2.0

func (api *CantabularMetadataExtractorAPI) GetMetadata(ctx context.Context, datasetID, lang string) (*cantabular.MetadataQueryResult, error)

func (*CantabularMetadataExtractorAPI) GetMetadataTable

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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