Skip to content

An OS API/system call library #5206

@mikomikotaishi

Description

@mikomikotaishi

Is your feature request related to a problem? Please describe.
Many libraries, like the Win32 API or POSIX C libraries, are C libraries and require arcane knowledge of ancient APIs to interact with the operating system with. This makes it difficult or even requiring un-idiomatic, C-style code in otherwise C++-style projects.

Describe the solution you'd like
I would like like to see C++ wrappers and OOP-style wrappers for calling operating system APIs, including Windows, macOS, and Linux (something like Poco::Platform::*, Poco::Platform::Win32::* or Poco::Platform::Windows::*, Poco::Platform::Posix::*, etc.) which provide improved facilities to interact with the operating system or make system calls.

Describe alternatives you've considered
There are some wrapper libraries for C++ for POSIX, but they are extremely obscure and probably abandoned. For Windows, there is win32metadata (for languages other than C, but apparently not C++) cppwinrt (based on C++17, but has apparently been put in maintenance mode and won't receive any new features). I thought it might be possible that Boost C++ libraries might have something like this, but it seems not.

Additional context
It might be worthwhile also integrating some of the features from boost::system, which has its own way for wrapping errors over a platform-agnostic API.

While it seems there is already some ability to manipulate the Windows Registry (Poco::Util::WinRegistryConfiguration, Poco::Util::WinRegistryKey, Poco::Util::WinService) as well as Poco::SyslogChannel for interacting with the Unix syslog service, what I am proposing is intended for additional control over platform-specific services. It might be worth moving these classes in to this namespace as well (or aliasing with using statements).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions