| Home | Libraries | People | FAQ | More

#### is_async_write_stream

Determine if `T` meets the requirements of AsyncWriteStream.

##### Synopsis

Defined in header `<boost/beast/core/stream_traits.hpp>`

    template<
        class T>
    using is_async_write_stream = see-below;

##### Description

Metafunctions are used to perform compile time checking of template types. This type will be `std::true_type` if `T` meets the requirements, else the type will be `std::false_type`.

##### Example

Use with `static_assert`:

    template<class AsyncWriteStream>
    void f(AsyncWriteStream& stream)
    {
        static_assert(is_async_write_stream<AsyncWriteStream>::value,
            "AsyncWriteStream type requirements not met");
    ...

Use with `std::enable_if` (SFINAE):

    template<class AsyncWriteStream>
    typename std::enable_if<is_async_write_stream<AsyncWriteStream>::value>::type
    f(AsyncWriteStream& stream);

Convenience header `<boost/beast/core.hpp>`