mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-29 11:00:29 +00:00
8e3d0a23d5
And use these to do the line-by-line reading automagically instead of having that logic in IRCClient. This will definitely come in handy.
21 lines
487 B
C++
21 lines
487 B
C++
#pragma once
|
|
|
|
#include <LibGUI/GIODevice.h>
|
|
#include <AK/AKString.h>
|
|
|
|
class GFile final : public GIODevice {
|
|
public:
|
|
GFile() { }
|
|
explicit GFile(const String&);
|
|
virtual ~GFile() override;
|
|
|
|
String filename() const { return m_filename; }
|
|
void set_filename(const String& filename) { m_filename = filename; }
|
|
|
|
virtual bool open(GIODevice::OpenMode) override;
|
|
|
|
virtual const char* class_name() const override { return "GFile"; }
|
|
|
|
private:
|
|
String m_filename;
|
|
};
|