chromium/storage/browser/quota/storage_policy_observer.h

// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef STORAGE_BROWSER_QUOTA_STORAGE_POLICY_OBSERVER_H_
#define STORAGE_BROWSER_QUOTA_STORAGE_POLICY_OBSERVER_H_

#include <map>
#include <vector>

#include "base/component_export.h"
#include "base/functional/callback.h"
#include "base/memory/scoped_refptr.h"
#include "base/memory/weak_ptr.h"
#include "base/sequence_checker.h"
#include "base/task/sequenced_task_runner.h"
#include "base/threading/sequence_bound.h"
#include "components/services/storage/public/mojom/storage_policy_update.mojom.h"
#include "storage/browser/quota/special_storage_policy.h"
#include "url/gurl.h"

namespace url {
class Origin;
}

namespace storage {

class StoragePolicyObserverIOThread;

// A helper class that aggregates storage::mojom::StoragePolicyUpdate
// changes for tracked origins. `StartTrackingOrigin()` adds an origin
// to start tracking.  When these origins have policy updates,
// the provided `callback` will be called with the policy update deltas.
class COMPONENT_EXPORT(STORAGE_BROWSER) StoragePolicyObserver {};

}  // namespace storage

#endif  // STORAGE_BROWSER_QUOTA_STORAGE_POLICY_OBSERVER_H_