Documentation
¶
Index ¶
Constants ¶
View Source
const DatasetID = "id"
View Source
const DatasetType = "type"
View Source
const IsBasedOn = "is_based_on"
View Source
const SortOrder = "sort_order"
Variables ¶
View Source
var MaxIDs = func() int {
return maxIDs
}
MaxIDs returns the maximum number of IDs acceptable in a list
Functions ¶
This section is empty.
Types ¶
type DatasetAPI ¶
type DatasetAPI struct {
Router *mux.Router
EnablePrePublishView bool
MaxRequestOptions int
// contains filtered or unexported fields
}
DatasetAPI manages importing filters against a dataset
func Setup ¶ added in v1.22.0
func Setup(ctx context.Context, cfg *config.Configuration, router *mux.Router, dataStore store.DataStore, urlBuilder *url.Builder, downloadGenerators map[models.DatasetType]DownloadsGenerator, authMiddleware auth.Middleware, enableURLRewriting bool, smDatasetAPI *application.StateMachineDatasetAPI, permissionsChecker auth.PermissionsChecker, idClient *clientsidentity.Client, searchContentUpdatedProducer *SearchContentUpdatedProducer, cloudflareClient cloudflare.Clienter) *DatasetAPI
Setup creates a new Dataset API instance and register the API routes based on the application configuration.
func (*DatasetAPI) SetFilesAPIClient ¶ added in v1.78.0
func (api *DatasetAPI) SetFilesAPIClient(client filesAPISDK.Clienter, authToken string)
SetFilesAPIClient sets the files API client and auth token for the API
type DownloadsGenerator ¶
type DownloadsGenerator interface {
Generate(ctx context.Context, datasetID, instanceID, edition, version string) error
}
DownloadsGenerator pre generates full file downloads for the specified dataset/edition/version
type PublishCheck ¶
PublishCheck Checks if an version has been published
func (*PublishCheck) Check ¶
func (d *PublishCheck) Check(handle func(http.ResponseWriter, *http.Request), action string) http.HandlerFunc
Check wraps a HTTP handle. Checks that the state is not published TODO: Refactor this to reduce the complexity
type SearchContentUpdatedProducer ¶ added in v1.94.0
type SearchContentUpdatedProducer struct {
Producer download.KafkaProducer
}
Click to show internal directories.
Click to hide internal directories.