FileWatcherUnimplemented.cpp 779 B

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * Copyright (c) 2020, Itamar S. <itamar8910@gmail.com>
  3. * Copyright (c) 2021, the SerenityOS developers.
  4. *
  5. * SPDX-License-Identifier: BSD-2-Clause
  6. */
  7. #include "FileWatcher.h"
  8. #include <LibCore/Notifier.h>
  9. #include <errno.h>
  10. namespace Core {
  11. ErrorOr<NonnullRefPtr<FileWatcher>> FileWatcher::create(FileWatcherFlags)
  12. {
  13. return Error::from_errno(ENOTSUP);
  14. }
  15. FileWatcher::FileWatcher(int watcher_fd, NonnullRefPtr<Notifier> notifier)
  16. : FileWatcherBase(watcher_fd)
  17. , m_notifier(move(notifier))
  18. {
  19. }
  20. FileWatcher::~FileWatcher() = default;
  21. ErrorOr<bool> FileWatcherBase::add_watch(ByteString, FileWatcherEvent::Type)
  22. {
  23. return Error::from_errno(ENOTSUP);
  24. }
  25. ErrorOr<bool> FileWatcherBase::remove_watch(ByteString)
  26. {
  27. return Error::from_errno(ENOTSUP);
  28. }
  29. }