mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 03:17:35 +00:00
Kernel/SysFS: Mark SysFSDirectory traverse and lookup methods as final
This enforces us to remove duplicated code across the SysFS code. This results in great simplification of how the SysFS works now, because we enforce one way to treat SysFSDirectory objects.
This commit is contained in:
parent
6733f19b3c
commit
70afa0b171
18 changed files with 114 additions and 178 deletions
|
@ -17,9 +17,9 @@ class SysFSRootDirectory final : public SysFSDirectory {
|
|||
public:
|
||||
virtual StringView name() const override { return "."sv; }
|
||||
static NonnullRefPtr<SysFSRootDirectory> create();
|
||||
virtual ErrorOr<void> traverse_as_directory(FileSystemID, Function<ErrorOr<void>(FileSystem::DirectoryEntryView const&)>) const override;
|
||||
|
||||
private:
|
||||
virtual bool is_root_directory() const override final { return true; }
|
||||
SysFSRootDirectory();
|
||||
RefPtr<SysFSBusDirectory> m_buses_directory;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue