14#include <AUI/Traits/values.h>
15#include <AUI/IO/IInputStream.h>
16#include <AUI/IO/IOutputStream.h>
40 using pipe_t = HANDLE;
46 Pipe(Pipe&& rhs)
noexcept {
47 operator=(std::move(rhs));
51 Pipe& operator=(Pipe&& rhs)
noexcept {
54 rhs.mIn = rhs.mOut =
static_cast<pipe_t
>(0);
63 pipe_t
out() const noexcept {
71 pipe_t
in() const noexcept {
108 size_t read(
char* dst,
size_t size)
override;
109 void write(
const char* src,
size_t size)
override;
Definition IOutputStream.h:18
void write(const char *src, size_t size) override
Writes exact size bytes to stream. Blocking (waiting for write all data) is allowed.
pipe_t stealIn() noexcept
Steals ownership of the in pipe outside of the Pipe class.
Definition Pipe.h:103
pipe_t stealOut() noexcept
Steals ownership of the out pipe outside of the Pipe class.
Definition Pipe.h:91
size_t read(char *dst, size_t size) override
Reads up to size bytes from stream. Blocking (waiting for new data) is allowed.
void closeOut() noexcept
Close out. Also known as close(pipe[0])
pipe_t in() const noexcept
In pipe. Also known as pipe[1].
Definition Pipe.h:71
pipe_t out() const noexcept
Out pipe. Also known as pipe[0].
Definition Pipe.h:63
void closeIn() noexcept
Close in. Also known as close(pipe[1])
Forbids copy of your class.
Definition values.h:45