Class PrepareHandle

Synopsis

#include <src/uvw/prepare.h>

class PrepareHandle final: public Handle<PrepareHandle, uv_prepare_t>

Description

The PrepareHandle handle.

Prepare handles will emit a PrepareEvent event once per loop iteration, right before polling for I/O.

To create a PrepareHandle through a Loop, no arguments are required.

Inheritance

Ancestors: Handle

Methods

initInitializes the handle.
startStarts the handle.
stopStops the handle.

Source

Lines 29-55 in src/uvw/prepare.h.

class PrepareHandle final: public Handle<PrepareHandle, uv_prepare_t> {
    static void startCallback(uv_prepare_t *handle);

public:
    using Handle::Handle;

    /**
     * @brief Initializes the handle.
     * @return True in case of success, false otherwise.
     */
    bool init();

    /**
     * @brief Starts the handle.
     *
     * A PrepareEvent event will be emitted once per loop iteration, right
     * before polling for I/O.
     *
     * The handle will start emitting PrepareEvent when needed.
     */
    void start();

    /**
     * @brief Stops the handle.
     */
    void stop();
};





Add Discussion as Guest

Log in