chromium/extensions/browser/guest_view/mime_handler_view/mime_handler_stream_manager.h

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

#ifndef EXTENSIONS_BROWSER_GUEST_VIEW_MIME_HANDLER_VIEW_MIME_HANDLER_STREAM_MANAGER_H_
#define EXTENSIONS_BROWSER_GUEST_VIEW_MIME_HANDLER_VIEW_MIME_HANDLER_STREAM_MANAGER_H_

#include <map>
#include <set>
#include <string>

#include "base/gtest_prod_util.h"
#include "components/keyed_service/core/keyed_service.h"
#include "extensions/browser/extension_registry.h"
#include "extensions/browser/extension_registry_observer.h"

namespace content {
class BrowserContext;
}

FORWARD_DECLARE_TEST(ChromeMimeHandlerViewTest, Basic);

namespace extensions {
class Extension;
class StreamContainer;

// A container for streams that have not yet been claimed by a
// MimeHandlerViewGuest. If the embedding RenderFrameHost is closed or navigates
// away from the resource being streamed, the stream is aborted. This is
// BrowserContext-keyed because mime handlers are extensions, which are
// per-BrowserContext.
class MimeHandlerStreamManager : public KeyedService,
                                 public ExtensionRegistryObserver {};

}  // namespace extensions

#endif  // EXTENSIONS_BROWSER_GUEST_VIEW_MIME_HANDLER_VIEW_MIME_HANDLER_STREAM_MANAGER_H_