Attributes
Members list
Value members
Concrete methods
Create a resource combining access to a list of resources
Create a resource combining access to a list of resources
Value parameters
- ress
-
the list of single resources
Attributes
- Returns
-
the resource of the list of elements provided by the single resources
Create a Resource from the allocation and release operation. The returned resource will allocate a new instance, i.e., call alloc, for every call to use and allocated.
Create a Resource from the allocation and release operation. The returned resource will allocate a new instance, i.e., call alloc, for every call to use and allocated.
Value parameters
- alloc
-
the allocation (generating) operation
- close
-
the release (close) operation
Attributes
- Returns
-
a new Resource exposing the allocatable object in a safe way
Create a resource combining access to two separate resources.
Create a resource combining access to two separate resources.
Value parameters
- join
-
an operator to combine the elements from both resources to that of the combined resource
- res1
-
the first resource
- res2
-
the second resource
Attributes
- Returns
-
a new resource wrapping access to the combined element
Create a resource that does not need asynchronous allocation nor cleanup.
Create a resource that does not need asynchronous allocation nor cleanup.
Value parameters
- data
-
the generator that provides the resource element
Attributes
- Returns
-
a resource wrapping the data provider
Create a concurrent computation resource from an allocator function. It can use the given capability to spawn Futures and return a handle to communicate with them. Allocation is only complete after that allocator returns. The resource is only allocated on use.
Create a concurrent computation resource from an allocator function. It can use the given capability to spawn Futures and return a handle to communicate with them. Allocation is only complete after that allocator returns. The resource is only allocated on use.
If the Async.Spawn capability is used for Async.awaiting, it may only be done synchronously by the spawnBody.
No presumption is made on reusability of the Resource. Thus, if the spawnBody is re-runnable, so is the Resource created from it.
Value parameters
- spawnBody
-
the allocator to setup and start asynchronous computation
Attributes
- Returns
-
a new resource wrapping access to the spawnBody's results