36 lines
718 B
C++
36 lines
718 B
C++
|
/***
|
||
|
Copyright (C) 2022 J Reece Wilson (a/k/a "Reece"). All rights reserved.
|
||
|
|
||
|
File: IPCHandle.hpp
|
||
|
Date: 2022-4-13
|
||
|
Author: Reece
|
||
|
***/
|
||
|
#pragma once
|
||
|
|
||
|
namespace Aurora::IPC
|
||
|
{
|
||
|
struct IPCHandle
|
||
|
{
|
||
|
bool flags[4];
|
||
|
|
||
|
union
|
||
|
{
|
||
|
char path[16];
|
||
|
struct
|
||
|
{
|
||
|
AuUInt32 cookie;
|
||
|
AuUInt32 pid;
|
||
|
};
|
||
|
};
|
||
|
|
||
|
void NewId(bool a, bool b, bool c, bool d);
|
||
|
bool FromString(const AuString &in);
|
||
|
AuString ToString() const;
|
||
|
AuString ToNTPath() const;
|
||
|
AuUInt32 ToUnixServerCookie() const;
|
||
|
|
||
|
#if defined(AURORA_IS_POSIX_DERIVED)
|
||
|
pid_t ToUnixPid() const;
|
||
|
#endif
|
||
|
};
|
||
|
}
|