Documentation ¶
Overview ¶
Copyright 2022 CodeNotary, Inc. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAlreadyClosed = errors.New("already closed")
View Source
var ErrCancellationRequested = errors.New("cancellation requested")
View Source
var ErrMaxWaitessLimitExceeded = errors.New("max waiting limit exceeded")
Functions ¶
This section is empty.
Types ¶
type WatchersHub ¶ added in v1.0.0
type WatchersHub struct {
// contains filtered or unexported fields
}
func New ¶
func New(doneUpto uint64, maxWaiting int) *WatchersHub
func (*WatchersHub) Close ¶ added in v1.0.0
func (w *WatchersHub) Close() error
func (*WatchersHub) DoneUpto ¶ added in v1.0.0
func (w *WatchersHub) DoneUpto(t uint64) error
func (*WatchersHub) Status ¶ added in v1.0.0
func (w *WatchersHub) Status() (doneUpto uint64, waiting int, err error)
func (*WatchersHub) WaitFor ¶ added in v1.0.0
func (w *WatchersHub) WaitFor(t uint64, cancellation <-chan struct{}) error
Click to show internal directories.
Click to hide internal directories.