/* * Copyright (c) 2024, Liav A. * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include #include #include #include namespace Kernel { class CustodyBase { public: CustodyBase(int dirfd, StringView path) : m_path(path) , m_dirfd(dirfd) { } CustodyBase(NonnullRefPtr base) : m_base(base) { } CustodyBase(Custody& base) : m_base(base) { } CustodyBase(Custody const& base) : m_base(base) { } ErrorOr> resolve() const; private: RefPtr const m_base; StringView m_path; int m_dirfd { -1 }; }; }