Bug 1652470 [wpt PR 24579] - Update mozrunner to 8.0.0, a=testonly
[gecko.git] / startupcache / StartupCacheChild.h
blob49747b8dc4990ab39a2554f28bf52f2f1a2a3c0e
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2; -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #ifndef StartupCacheChild_h
7 #define StartupCacheChild_h
9 #include "mozilla/scache/StartupCache.h"
10 #include "mozilla/scache/PStartupCacheChild.h"
11 #include "mozilla/scache/PStartupCacheParent.h"
13 namespace mozilla {
14 namespace ipc {
15 class FileDescriptor;
18 namespace scache {
20 using mozilla::ipc::FileDescriptor;
22 class StartupCacheChild final : public PStartupCacheChild {
23 friend class mozilla::scache::StartupCache;
24 friend class mozilla::scache::StartupCacheListener;
26 public:
27 StartupCacheChild() = default;
29 void Init(bool wantCacheData);
31 protected:
32 virtual void ActorDestroy(ActorDestroyReason aWhy) override;
34 void SendEntriesAndFinalize(StartupCache::Table& entries);
36 private:
37 bool mWantCacheData = false;
40 } // namespace scache
41 } // namespace mozilla
43 #endif // StartupCacheChild_h