app

package
v0.941.0-MLPAB1757extr... Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: MIT Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	None handleOpt = 1 << iota
	RequireSession
)

Variables

This section is empty.

Functions

func App

func App(
	logger *logging.Logger,
	localizer page.Localizer,
	lang localize.Lang,
	tmpls template.Templates,
	sessionStore SessionStore,
	lpaDynamoClient DynamoClient,
	appPublicURL string,
	payClient *pay.Client,
	notifyClient *notify.Client,
	addressClient *place.Client,
	rumConfig page.RumConfig,
	staticHash string,
	paths page.AppPaths,
	oneLoginClient *onelogin.Client,
	oneloginURL string,
	s3Client S3Client,
	eventClient *event.Client,
	lpaStoreClient *lpastore.Client,
) http.Handler

func NewDocumentStore added in v0.794.0

func NewDocumentStore(dynamoClient DynamoClient, s3Client S3Client, eventClient EventClient, randomUUID func() string, now func() time.Time) *documentStore

func NewShareCodeStore added in v0.660.0

func NewShareCodeStore(dynamoClient ShareCodeStoreDynamoClient) *shareCodeStore

func NewUidStore added in v0.805.0

func NewUidStore(dynamoClient DynamoUpdateClient, now func() time.Time) *uidStore

Types

type DocumentStore added in v0.794.0

type DocumentStore interface {
	GetAll(context.Context) (page.Documents, error)
	Put(context.Context, page.Document) error
	UpdateScanResults(context.Context, string, string, bool) error
}

type DynamoClient

type DynamoClient interface {
	One(ctx context.Context, pk, sk string, v interface{}) error
	OneByPartialSk(ctx context.Context, pk, partialSk string, v interface{}) error
	AllByPartialSk(ctx context.Context, pk, partialSk string, v interface{}) error
	LatestForActor(ctx context.Context, sk string, v interface{}) error
	AllForActor(ctx context.Context, sk string, v interface{}) error
	AllByKeys(ctx context.Context, pks []dynamo.Key) ([]map[string]dynamodbtypes.AttributeValue, error)
	AllKeysByPk(ctx context.Context, pk string) ([]dynamo.Key, error)
	Put(ctx context.Context, v interface{}) error
	Create(ctx context.Context, v interface{}) error
	DeleteKeys(ctx context.Context, keys []dynamo.Key) error
	DeleteOne(ctx context.Context, pk, sk string) error
	Update(ctx context.Context, pk, sk string, values map[string]dynamodbtypes.AttributeValue, expression string) error
	BatchPut(ctx context.Context, items []interface{}) error
	OneByUID(ctx context.Context, uid string, v interface{}) error
}

type DynamoUpdateClient added in v0.805.0

type DynamoUpdateClient interface {
	Update(ctx context.Context, pk, sk string, values map[string]types.AttributeValue, expression string) error
}

type ErrorHandler added in v0.930.0

type ErrorHandler func(http.ResponseWriter, *http.Request, error)

type EventClient

type EventClient interface {
	SendUidRequested(context.Context, event.UidRequested) error
	SendApplicationUpdated(context.Context, event.ApplicationUpdated) error
	SendPreviousApplicationLinked(context.Context, event.PreviousApplicationLinked) error
	SendReducedFeeRequested(context.Context, event.ReducedFeeRequested) error
}

type Logger

type Logger interface {
	Print(v ...interface{})
}

type S3Client added in v0.759.0

type S3Client interface {
	PutObject(context.Context, string, []byte) error
	DeleteObject(context.Context, string) error
	DeleteObjects(ctx context.Context, keys []string) error
	PutObjectTagging(context.Context, string, map[string]string) error
}

type SessionStore

type SessionStore interface {
	Get(r *http.Request, name string) (*sessions.Session, error)
	New(r *http.Request, name string) (*sessions.Session, error)
	Save(r *http.Request, w http.ResponseWriter, s *sessions.Session) error
}

type ShareCodeStoreDynamoClient added in v0.869.0

type ShareCodeStoreDynamoClient interface {
	One(ctx context.Context, pk, sk string, v interface{}) error
	Put(ctx context.Context, v interface{}) error
}

type UidClient

type UidClient interface {
	CreateCase(context.Context, *uid.CreateCaseRequestBody) (uid.CreateCaseResponse, error)
}

Jump to

Keyboard shortcuts

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