releasecalendar

package
v2.261.0 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2024 License: MIT Imports: 11 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client added in v2.92.4

type Client struct {
	// contains filtered or unexported fields
}

Client is a release calendar api client which can be used to make requests to the server. It extends the generic healthcheck Client structure.

func NewAPIClient added in v2.92.4

func NewAPIClient(releaseCalendarApiUrl string) *Client

NewAPIClient creates a new instance of ReleaseCalendarAPI Client with a given release calendar api url

func NewWithHealthClient added in v2.92.4

func NewWithHealthClient(hcCli *health.Client) *Client

NewWithHealthClient creates a new instance of ReleaseCalendarAPI Client, reusing the URL and Clienter from the provided healthcheck client.

func (*Client) Checker added in v2.92.4

func (c *Client) Checker(ctx context.Context, check *healthcheck.CheckState) error

Checker calls the release calendar API health endpoint and returns a check object to the caller.

func (*Client) GetLegacyRelease added in v2.92.4

func (c *Client) GetLegacyRelease(ctx context.Context, userAccessToken, collectionID, lang, uri string) (*Release, error)

GetLegacyRelease returns a legacy release

func (*Client) HealthClient added in v2.92.4

func (c *Client) HealthClient() *health.Client

HealthClient returns the underlying Healthcheck Client for this release calendar API client

func (*Client) URL added in v2.92.4

func (c *Client) URL() string

URL returns the URL used by this client

type Contact

type Contact struct {
	Email     string `json:"email"`
	Name      string `json:"name"`
	Telephone string `json:"telephone"`
}

Contact represents the contact details for the release

type Link struct {
	Summary string `json:"summary"`
	Title   string `json:"title"`
	URI     string `json:"uri"`
}

Link represents a link to a related resource

type Release

type Release struct {
	DateChanges               []ReleaseDateChange `json:"date_changes"`
	Description               ReleaseDescription  `json:"description"`
	Links                     []Link              `json:"links"`
	Markdown                  []string            `json:"markdown"`
	RelatedDatasets           []Link              `json:"related_datasets"`
	RelatedAPIDatasets        []Link              `json:"related_api_datasets"`
	RelatedDocuments          []Link              `json:"related_documents"`
	RelatedMethodology        []Link              `json:"related_methodology"`
	RelatedMethodologyArticle []Link              `json:"related_methodology_article"`
	URI                       string              `json:"uri"`
}

Release represents a release

func (Release) Census added in v2.142.0

func (r Release) Census() bool

type ReleaseDateChange

type ReleaseDateChange struct {
	ChangeNotice string `json:"change_notice"`
	Date         string `json:"previous_date"`
}

ReleaseDateChange represent a date change of a release

type ReleaseDescription

type ReleaseDescription struct {
	CancellationNotice []string `json:"cancellation_notice"`
	Cancelled          bool     `json:"cancelled"`
	Contact            Contact  `json:"contact"`
	Finalised          bool     `json:"finalised"`
	NationalStatistic  bool     `json:"national_statistic"`
	WelshStatistic     bool     `json:"welsh_statistic"`
	Survey             string   `json:"survey"`
	NextRelease        string   `json:"next_release"`
	ProvisionalDate    string   `json:"provisional_date"`
	Published          bool     `json:"published"`
	ReleaseDate        string   `json:"release_date"`
	Summary            string   `json:"summary"`
	Title              string   `json:"title"`
}

ReleaseDescription represents the description of a release

Jump to

Keyboard shortcuts

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