input

package
v1.15.0 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package input provides access to embedded puzzles input files.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrNotFound returns when puzzle input is not yet unlocked or invalid date passed.
	ErrNotFound = errors.New("puzzle inout not found")
	// ErrUnauthorized returns when session is empty or invalid.
	ErrUnauthorized = errors.New("unauthorized")
)

Functions

This section is empty.

Types

type Date added in v0.19.0

type Date struct {
	Year string
	Day  string
}

Date holds date info.

func (Date) String added in v0.19.0

func (d Date) String() string

type Fetcher added in v1.10.4

type Fetcher interface {
	Fetch(ctx context.Context, d Date, session string) ([]byte, error)
}

Fetcher is an input get client.

func NewFetcher added in v1.10.4

func NewFetcher(c IHTTPClient, timeout time.Duration) Fetcher

NewFetcher constructor for Fetcher.

type IHTTPClient added in v1.10.4

type IHTTPClient interface {
	Do(*http.Request) (*http.Response, error)
}

IHTTPClient provides the interface for custom HTTP client implementations.

Jump to

Keyboard shortcuts

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