memorystorage

package
v0.2023.21 Latest Latest
Warning

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

Go to latest
Published: May 22, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MemoryTokenStorage

type MemoryTokenStorage struct {
	// Tokens is the map of stored Tokens. The keys are object keys of the SPIAccessToken objects.
	Tokens map[client.ObjectKey]api.Token
	// ErrorOnInitialize if not nil, the error is thrown when the Initialize method is called.
	ErrorOnInitialize error
	// ErrorOnStore if not nil, the error is thrown when the Store method is called.
	ErrorOnStore error
	// ErrorOnGet if not nil, the error is thrown when the Get method is called.
	ErrorOnGet error
	// ErrorOnDelete if not nil, the error is thrown when the Delete method is called.
	ErrorOnDelete error
	// contains filtered or unexported fields
}

MemoryTokenStorage is an in-memory implementation of the TokenStorage interface intended to be used in tests.

func (*MemoryTokenStorage) Delete

func (*MemoryTokenStorage) Get

func (*MemoryTokenStorage) Initialize

func (m *MemoryTokenStorage) Initialize(_ context.Context) error

func (*MemoryTokenStorage) Store

func (m *MemoryTokenStorage) Store(_ context.Context, owner *api.SPIAccessToken, token *api.Token) error

Jump to

Keyboard shortcuts

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