ReXGlue SDK
Loading...
Searching...
No Matches
process.h File Reference

Process control, console, environment and crash reports. More...

#include <cstdio>
#include <filesystem>
#include <memory>
#include <optional>
#include <span>
#include <string>
#include <string_view>
#include <utility>
#include <vector>
#include <rex/platform.h>
#include <rex/result.h>
#include <rex/types.h>
#include <rex/utility.h>

Go to the source code of this file.

Classes

class  rex::platform::InstanceLock
struct  rex::platform::OpenFileLimit
struct  rex::platform::CrashReporterOptions

Namespaces

namespace  rex
namespace  rex::platform

Typedefs

using rex::platform::CrashAddressDescriber = u32 (*)(u64 host_address, std::span<char> out)

Enumerations

enum class  rex::MessageType : u8 { kInfo , kWarning , kError }

Functions

Result< void > rex::platform::Relaunch (std::span< const std::string > args)
Result< void > rex::platform::Relaunch (const std::filesystem::path &exe, std::span< const std::string > args, const std::filesystem::path &working_directory={})
bool rex::platform::CanRelaunch ()
Result< OpenFileLimit > rex::platform::RaiseOpenFileLimit ()
std::string rex::platform::DescribeResourceUse ()
bool rex::platform::IsTerminal (FILE *stream)
bool rex::platform::EnableANSIEscapes (FILE *stream)
void rex::platform::SetUTF8OutputCodePage ()
bool rex::platform::IsDebuggerAttached ()
void rex::platform::Break ()
std::optional< std::string > rex::platform::GetEnvironmentValue (std::string_view name)
bool rex::platform::SetEnvironmentValue (std::string_view name, std::string_view value)
bool rex::platform::UnsetEnvironmentValue (std::string_view name)
std::vector< std::pair< std::string, std::string > > rex::platform::EnumerateEnvironment ()
void rex::ShowMessageBox (MessageType type, std::string_view message)
Result< void > rex::platform::InstallCrashReporter (const CrashReporterOptions &options)
void rex::platform::UninstallCrashReporter ()
void rex::platform::SetCrashAddressDescriber (CrashAddressDescriber describer)
void rex::platform::PrepareThreadForCrash ()

Detailed Description

Process control, console, environment and crash reports.

License
BSD 3-Clause License See LICENSE file in the project root for full license text.
Remarks
The debugger and message box parts are derived from Xenia's xenia/base/debugging.h (Ben Vanik, 2014) and xenia/base/system.h (Ben Vanik, 2020).