Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetScopeWaitManager ¶
func GetScopeWaitManager(scp app.DataScope, name string) (value commservices.ScopeWaitManager, err error)
GetScopeWaitManager get ScopeWaitManager value from data scope
func NewScopeWaitManager ¶
func NewScopeWaitManager(ctxScope app.Scope) commservices.ScopeWaitManager
NewScopeWaitManager create new ScopeWaitManager instance
func WaitManagerFactory ¶
func WaitManagerFactory(dp app.DependencyProvider) (ri interface{}, err error)
WaitManagerFactory create new WaitManager instance
Types ¶
type ScopeWaitManager ¶
type ScopeWaitManager struct {
// contains filtered or unexported fields
}
ScopeWaitManager is wait group manager
func (*ScopeWaitManager) Add ¶
func (manager *ScopeWaitManager) Add(name string, delta int)
Add task counter to waitgroup
func (*ScopeWaitManager) Done ¶
func (manager *ScopeWaitManager) Done(name string)
Done decrements the WaitGroup counter by one.
func (*ScopeWaitManager) Wait ¶
func (manager *ScopeWaitManager) Wait(name string)
Wait blocks until the WaitGroup counter is zero.
type WaitManager ¶
type WaitManager struct{}
WaitManager is namespace storage for scope
func NewWaitManager ¶
func NewWaitManager() WaitManager
NewWaitManager create new WaitManager instance
func (WaitManager) ForScope ¶
func (manager WaitManager) ForScope(ctxScope app.Scope) (swm commservices.ScopeWaitManager, err error)
ForScope return scope manager
Click to show internal directories.
Click to hide internal directories.