openidmeta

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Data

type Data struct {
	Config []byte
	JWKS   []byte
}

Data holds openid discovery metadata.

type Reader

type Reader interface {
	Read(key string) (Data, bool)
}

Reader lets the consumer read entries from Store.

type Store

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

Store is a thread safe in-memory store that can be used to read and write openid discovery metadata. Mind that the store does not perform any validation on the inputs.

func NewStore

func NewStore() *Store

NewStore returns a ready for use Store.

func (*Store) Delete

func (s *Store) Delete(key string)

Delete removes an entry from the Store.

func (*Store) Len

func (s *Store) Len() int

Len returns the number of entries in the Store.

func (*Store) Read

func (s *Store) Read(key string) (Data, bool)

Read retrieves an entry from the Store.

func (*Store) Write

func (s *Store) Write(key string, data Data)

Write sets and entry to the Store. If the entry exists it is overwritten.

type Writer

type Writer interface {
	Write(key string, data Data)
	Delete(key string)
}

Writer lets the consumer write entries to Store.

Jump to

Keyboard shortcuts

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