filecache

package
v1.0.10 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2022 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WriteCache

func WriteCache(file *os.File, cache *FileCache) error

Types

type AccessTokenBox

type AccessTokenBox struct {
	ApiBaseUrl     string
	LoginTokenHash uint64
	AccessToken    string
	RefreshToken   string
}

type FileCache

type FileCache struct {
	Version      int
	AccessTokens []AccessTokenBox
	Metrics      Metrics
}

func ReadCache

func ReadCache(flag int) (*os.File, *FileCache, error)

TODO use golang.org/x/sys/unix FcntlFlock()

type Metrics

type Metrics struct {
	Disabled bool
	Host     *string `yaml:",omitempty"`
}

Jump to

Keyboard shortcuts

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