// Copyright 2019 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_REGISTRY_UPDATE_H_ #define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_REGISTRY_UPDATE_H_ #include <memory> #include <vector> #include "base/functional/callback.h" #include "base/memory/raw_ptr.h" #include "base/types/pass_key.h" #include "components/webapps/common/web_app_id.h" namespace web_app { class WebApp; class WebAppRegistrar; class WebAppSyncBridge; // A raw registry update data. struct RegistryUpdateData { … }; // An explicit writable "view" for the registry. Any write operations must be // batched as a part of WebAppRegistryUpdate object. Effectively // WebAppRegistryUpdate is a part of WebAppSyncBridge class. class WebAppRegistryUpdate { … }; // A convenience utility class to use RAII for `WebAppSyncBridge::BeginUpdate` // and `WebAppSyncBridge::CommitUpdate` calls. class [[nodiscard]] ScopedRegistryUpdate { … }; } // namespace web_app #endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_REGISTRY_UPDATE_H_