View Source Evision.AsyncArray (Evision v0.2.9)
Summary
Types
@type t() :: %Evision.AsyncArray{ref: reference()}
Type that represents an AsyncArray
struct.
ref.
reference()
The underlying erlang resource variable.
Functions
AsyncArray
Return
- self:
Evision.AsyncArray.t()
Python prototype (for reference only):
AsyncArray() -> <AsyncArray object>
@spec get(Keyword.t()) :: any() | {:error, String.t()}
@spec get(t()) :: Evision.Mat.t() | {:error, String.t()}
get
Positional Arguments
- self:
Evision.AsyncArray.t()
Return
dst:
Evision.Mat.t()
.destination array
Fetch the result.
Waits for result until container has valid result. Throws exception if exception was stored as a result. Throws exception on invalid container state. Note: Result or stored exception can be fetched only once.
Python prototype (for reference only):
get([, dst]) -> dst
@spec get(t(), [{atom(), term()}, ...] | nil) :: Evision.Mat.t() | {:error, String.t()}
@spec get(t(), number()) :: Evision.Mat.t() | false | {:error, String.t()}
Variant 1:
get
Positional Arguments
self:
Evision.AsyncArray.t()
timeoutNs:
double
.timeout in nanoseconds, -1 for infinite wait
Return
retval:
bool
dst:
Evision.Mat.t()
.destination array
Retrieving the result with timeout
@returns true if result is ready, false if the timeout has expired Note: Result or stored exception can be fetched only once.
Python prototype (for reference only):
get(timeoutNs[, dst]) -> retval, dst
Variant 2:
get
Positional Arguments
- self:
Evision.AsyncArray.t()
Return
dst:
Evision.Mat.t()
.destination array
Fetch the result.
Waits for result until container has valid result. Throws exception if exception was stored as a result. Throws exception on invalid container state. Note: Result or stored exception can be fetched only once.
Python prototype (for reference only):
get([, dst]) -> dst
@spec get(t(), number(), [{atom(), term()}, ...] | nil) :: Evision.Mat.t() | false | {:error, String.t()}
get
Positional Arguments
self:
Evision.AsyncArray.t()
timeoutNs:
double
.timeout in nanoseconds, -1 for infinite wait
Return
retval:
bool
dst:
Evision.Mat.t()
.destination array
Retrieving the result with timeout
@returns true if result is ready, false if the timeout has expired Note: Result or stored exception can be fetched only once.
Python prototype (for reference only):
get(timeoutNs[, dst]) -> retval, dst
@spec release(Keyword.t()) :: any() | {:error, String.t()}
@spec release(t()) :: t() | {:error, String.t()}
release
Positional Arguments
- self:
Evision.AsyncArray.t()
Python prototype (for reference only):
release() -> None
@spec valid(Keyword.t()) :: any() | {:error, String.t()}
@spec valid(t()) :: boolean() | {:error, String.t()}
valid
Positional Arguments
- self:
Evision.AsyncArray.t()
Return
- retval:
bool
Python prototype (for reference only):
valid() -> retval
wait_for
Positional Arguments
- self:
Evision.AsyncArray.t()
- timeoutNs:
double
Return
- retval:
bool
Python prototype (for reference only):
wait_for(timeoutNs) -> retval