end)
<
==============================================================================
`uv_req_t` — Base request *luv-base-request* *uv_req_t*
`uv_req_t` is the base type for all libuv request types.
uv.cancel({req}) *uv.cancel()*
> method form `req:cancel()`
Parameters:
- `req`: `userdata` for sub-type of |uv_req_t|
Cancel a pending request. Fails if the request is executing or
has finished executing. Only cancellation of |uv_fs_t|,
`uv_getaddrinfo_t`, `uv_getnameinfo_t` and `uv_work_t`
requests is currently supported.
Returns: `0` or `fail`
uv.req_get_type({req}) *uv.req_get_type()*
> method form `req:get_type()`
Parameters:
- `req`: `userdata` for sub-type of |uv_req_t|
Returns the name of the struct for a given request (e.g.
`"fs"` for |uv_fs_t|) and the libuv enum integer for the
request's type (`uv_req_type`).
Returns: `string, integer`
==============================================================================
`uv_handle_t` — Base handle *luv-base-handle* *uv_handle_t*
`uv_handle_t` is the base type for all libuv handle types. All API functions
defined here work with any handle type.
uv.is_active({handle}) *uv.is_active()*
> method form `handle:is_active()`
Parameters:
- `handle`: `userdata` for sub-type of |uv_handle_t|
Returns `true` if the handle is active, `false` if it's
inactive. What "active” means depends on the type of handle:
- A |uv_async_t| handle is always active and cannot be
deactivated, except by closing it with |uv.close()|.
- A |uv_pipe_t|, |uv_tcp_t|, |uv_udp_t|, etc.
handle - basically any handle that deals with I/O - is
active when it is doing something that involves I/O, like
reading, writing, connecting, accepting new connections,
etc.
- A |uv_check_t|, |uv_idle_t|, |uv_timer_t|,
etc. handle is active when it has been started with a call
to |uv.check_start()|, |uv.idle_start()|,
|uv.timer_start()| etc. until it has been stopped with a
call to its respective stop function.
Returns: `boolean` or `fail`
uv.is_closing({handle}) *uv.is_closing()*
> method form `handle:is_closing()`
Parameters:
- `handle`: `userdata` for sub-type of |uv_handle_t|
Returns `true` if the handle is closing or closed, `false`
otherwise.
Returns: `boolean` or `fail`
Note: This function should only be used between the
initialization of the handle and the arrival of the close
callback.
uv.close({handle} [, {callback}]) *uv.close()*
> method form `handle:close([callback])`
Parameters:
- `handle`: `userdata` for sub-type of |uv_handle_t|
- `callback`: `callable` or `nil`
Request handle to be closed. `callback` will be called
asynchronously after this call. This MUST be called on each
handle before memory is released.
Handles that wrap file descriptors are closed immediately but
`callback` will still be deferred to the next iteration of the
event loop. It gives you a chance