1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 17:47:44 +00:00

LibCore: Add File::{stdin, stdout, stderr}()

This should make it easier to get a Core::File for standard streams.
This commit is contained in:
Peter Elliott 2020-08-17 15:58:07 -06:00 committed by Andreas Kling
parent 6c2d0dea91
commit f69b419c05
2 changed files with 34 additions and 0 deletions

View file

@ -57,6 +57,10 @@ public:
};
bool open(int fd, IODevice::OpenMode, ShouldCloseFileDescription);
static NonnullRefPtr<File> stdin();
static NonnullRefPtr<File> stdout();
static NonnullRefPtr<File> stderr();
private:
File(Object* parent = nullptr)
: IODevice(parent)