config

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config interface {
	TranslatePath(path string) string
	UnmarshalKey(key string, rawVal interface{}) error
}

type Identity

type Identity struct {
	ID        string      `yaml:"id"`
	Default   bool        `yaml:"default,omitempty"`
	Path      string      `yaml:"path"`
	CacheSize int         `yaml:"cacheSize"`
	Type      string      `yaml:"type,omitempty"`
	Opts      interface{} `yaml:"opts,omitempty"`
}

func (*Identity) String

func (i *Identity) String() string

type IdentityConfig

type IdentityConfig struct {
	Config  Config
	Wallets *Wallets
}

func NewIdentityConfig

func NewIdentityConfig(config Config) (*IdentityConfig, error)

func (*IdentityConfig) CacheSizeForOwnerID

func (i *IdentityConfig) CacheSizeForOwnerID(id string) int

func (*IdentityConfig) DefaultCacheSize

func (i *IdentityConfig) DefaultCacheSize() int

func (*IdentityConfig) IdentitiesForRole

func (i *IdentityConfig) IdentitiesForRole(role driver.IdentityRole) ([]*Identity, error)

func (*IdentityConfig) TranslatePath

func (i *IdentityConfig) TranslatePath(path string) string

type Wallets

type Wallets struct {
	DefaultCacheSize int         `yaml:"defaultCacheSize,omitempty"`
	Certifiers       []*Identity `yaml:"certifiers,omitempty"`
	Owners           []*Identity `yaml:"owners,omitempty"`
	Issuers          []*Identity `yaml:"issuers,omitempty"`
	Auditors         []*Identity `yaml:"auditors,omitempty"`
}

Jump to

Keyboard shortcuts

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