diff --git a/pool.go b/pool.go index 4fcae8a..ad9542e 100644 --- a/pool.go +++ b/pool.go @@ -34,8 +34,8 @@ var ( }() ) -// basePool is the base interface for all pool types. -type basePool interface { +// BasePool defines methods common to all pool types. +type BasePool interface { // Returns the number of worker goroutines that are currently active (executing a task) in the pool. RunningWorkers() int64 @@ -94,7 +94,7 @@ type basePool interface { // Represents a pool of goroutines that can execute tasks concurrently. type Pool interface { - basePool + BasePool // Submits a task to the pool without waiting for it to complete. // The pool will not accept new tasks after it has been stopped. diff --git a/result.go b/result.go index 6db8750..3f0d4d4 100644 --- a/result.go +++ b/result.go @@ -8,7 +8,7 @@ import ( // ResultPool is a pool that can be used to submit tasks that return a result. type ResultPool[R any] interface { - basePool + BasePool // Submits a task to the pool and returns a future that can be used to wait for the task to complete and get the result. // The pool will not accept new tasks after it has been stopped.