mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 23:50:19 +00:00
6bdb81ad87
InodeVMObject is a VMObject with an underlying Inode in the filesystem. AnonymousVMObject has no Inode. I'm happy that InodeVMObject::inode() can now return Inode& instead of VMObject::inode() return Inode*. :^)
24 lines
819 B
C++
24 lines
819 B
C++
#pragma once
|
|
|
|
#include <Kernel/VM/PhysicalAddress.h>
|
|
#include <Kernel/VM/VMObject.h>
|
|
|
|
class AnonymousVMObject final : public VMObject {
|
|
public:
|
|
virtual ~AnonymousVMObject() override;
|
|
|
|
static NonnullRefPtr<AnonymousVMObject> create_with_size(size_t);
|
|
static NonnullRefPtr<AnonymousVMObject> create_for_physical_range(PhysicalAddress, size_t);
|
|
virtual NonnullRefPtr<VMObject> clone() override;
|
|
|
|
private:
|
|
explicit AnonymousVMObject(size_t);
|
|
explicit AnonymousVMObject(const AnonymousVMObject&);
|
|
AnonymousVMObject(PhysicalAddress, size_t);
|
|
|
|
AnonymousVMObject& operator=(const AnonymousVMObject&) = delete;
|
|
AnonymousVMObject& operator=(AnonymousVMObject&&) = delete;
|
|
AnonymousVMObject(AnonymousVMObject&&) = delete;
|
|
|
|
virtual bool is_anonymous() const override { return true; }
|
|
};
|