1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CONTENT_BROWSER_STREAMS_STREAM_HANDLE_IMPL_H_
6 #define CONTENT_BROWSER_STREAMS_STREAM_HANDLE_IMPL_H_
8 #include "base/memory/weak_ptr.h"
9 #include "base/message_loop/message_loop_proxy.h"
10 #include "base/synchronization/lock.h"
11 #include "content/public/browser/stream_handle.h"
17 class StreamHandleImpl : public StreamHandle {
19 StreamHandleImpl(const base::WeakPtr<Stream>& stream,
20 const GURL& original_url,
21 const std::string& mime_type);
22 virtual ~StreamHandleImpl();
25 // StreamHandle overrides
26 virtual const GURL& GetURL() OVERRIDE;
27 virtual const GURL& GetOriginalURL() OVERRIDE;
28 virtual const std::string& GetMimeType() OVERRIDE;
30 base::WeakPtr<Stream> stream_;
33 std::string mime_type_;
34 base::MessageLoopProxy* stream_message_loop_;
37 } // namespace content
39 #endif // CONTENT_BROWSER_STREAMS_STREAM_HANDLE_IMPL_H_