class data_io_stream


template <
    typename IOResource
>
class data_io_stream
    : public data_input_stream<IOResource>
    , public data_output_stream<IOResource>

Public Aliases

using wrapped_resource_type = IOResource

The type of the wrapped I/O resource.

Public Member Functions

explicit
data_io_stream (
    wrapped_resource_type& resource,
    std::endian endianness = std::endian::big
)
noexcept

Constructs a data I/O stream from the given I/O resource and with the given endianness. The data I/O stream will hold a non-owning reference to the resource, which is expected to stay valid when using the data I/O stream.

Parameters:
  • resource:

    The I/O resource to read from and write to.

  • endianness:

    The endianness that the data is expected to be in.

wrapped_resource_type*
operator -> ()
const noexcept

Returns a pointer to the wrapped I/O resource, enabling use of the arrow operator.



Copyright © 2022-2025 Daniel T. McGinnis

CCL was first published in 2022, and is still actively maintained.

This website was first published in 2022, and is still actively maintained.

This specific web page was first published in 2022.