di

package
v0.0.0-...-5346f80 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2020 License: MIT Imports: 33 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientComponent

type ClientComponent interface {
	HydraClient(ctx context.Context) *client.OryHydra
	EmailSender(ctx context.Context) email.Sender
}

ClientComponent is an interface of api clients

func NewClientComponent

func NewClientComponent(cfg *config.Config) (ClientComponent, error)

NewClientComponent returns new client component

type StoreComponent

type StoreComponent interface {
	UserStore(ctx context.Context) store.UserStore
	SessionStore(ctx context.Context) store.SessionStore
	ProfileStore(ctx context.Context) store.ProfileStore
	UserBlogStore(ctx context.Context) store.UserBlogStore
	FeedStore(ctx context.Context) store.FeedStore
	EntryStore(ctx context.Context) store.EntryStore
	RoleStore(ctx context.Context) store.RoleStore
	HeartbeatStore(ctx context.Context) store.HeartbeatStore
	DepartmentStore(ctx context.Context) store.DepartmentStore
	InvitationStore(ctx context.Context) store.InvitationStore
	GitHubStore(ctx context.Context) store.GitHubStore
	EmailConfirmationStore(ctx context.Context) store.EmailConfirmationStore
	PasswordResetStore(ctx context.Context) store.PasswordResetStore
	AchievementStore(ctx context.Context) store.AchievementStore
	ImageStore(ctx context.Context) store.ImageStore
}

StoreComponent is an interface of stores

func NewStoreComponent

func NewStoreComponent(cfg *config.Config) (StoreComponent, error)

NewStoreComponent returns new store component

type TestStoreComponent

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

func MustCreateTestStoreComponent

func MustCreateTestStoreComponent(cfg *config.Config) *TestStoreComponent

MustCreateTestStoreComponent creates test store component or exits

func (TestStoreComponent) AchievementStore

func (s TestStoreComponent) AchievementStore(ctx context.Context) store.AchievementStore

func (TestStoreComponent) DepartmentStore

func (s TestStoreComponent) DepartmentStore(ctx context.Context) store.DepartmentStore

func (TestStoreComponent) EmailConfirmationStore

func (s TestStoreComponent) EmailConfirmationStore(ctx context.Context) store.EmailConfirmationStore

func (TestStoreComponent) EntryStore

func (s TestStoreComponent) EntryStore(ctx context.Context) store.EntryStore

func (TestStoreComponent) FeedStore

func (s TestStoreComponent) FeedStore(ctx context.Context) store.FeedStore

func (TestStoreComponent) GitHubStore

func (s TestStoreComponent) GitHubStore(ctx context.Context) store.GitHubStore

func (TestStoreComponent) HeartbeatStore

func (s TestStoreComponent) HeartbeatStore(ctx context.Context) store.HeartbeatStore

func (TestStoreComponent) ImageStore

func (s TestStoreComponent) ImageStore(ctx context.Context) store.ImageStore

func (TestStoreComponent) InvitationStore

func (s TestStoreComponent) InvitationStore(ctx context.Context) store.InvitationStore

func (*TestStoreComponent) MustClose

func (c *TestStoreComponent) MustClose()

func (TestStoreComponent) PasswordResetStore

func (s TestStoreComponent) PasswordResetStore(ctx context.Context) store.PasswordResetStore

func (TestStoreComponent) ProfileStore

func (s TestStoreComponent) ProfileStore(ctx context.Context) store.ProfileStore

func (TestStoreComponent) RoleStore

func (s TestStoreComponent) RoleStore(ctx context.Context) store.RoleStore

func (TestStoreComponent) SessionStore

func (s TestStoreComponent) SessionStore(ctx context.Context) store.SessionStore

func (TestStoreComponent) UserBlogStore

func (s TestStoreComponent) UserBlogStore(ctx context.Context) store.UserBlogStore

func (TestStoreComponent) UserStore

func (s TestStoreComponent) UserStore(ctx context.Context) store.UserStore

Jump to

Keyboard shortcuts

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