Chromium Code Reviews| Index: content/public/common/content_url_request_user_data.h |
| diff --git a/content/public/common/content_url_request_user_data.h b/content/public/common/content_url_request_user_data.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..0fa31e0da9b77271e5991b19f766186553f7f13d |
| --- /dev/null |
| +++ b/content/public/common/content_url_request_user_data.h |
| @@ -0,0 +1,38 @@ |
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CONTENT_PUBLIC_COMMON_CONTENT_URL_REQUEST_USER_DATA_H_ |
| +#define CONTENT_PUBLIC_COMMON_CONTENT_URL_REQUEST_USER_DATA_H_ |
| +#pragma once |
| + |
| +#include "base/supports_user_data.h" |
| +#include "content/common/content_export.h" |
| + |
| +namespace content { |
| + |
| +// The content library will annotate all URLRequests with the following user |
| +// data if the request can be associated with a given render view. |
| +class CONTENT_EXPORT ContentURLRequestUserData |
|
jam
2012/03/01 19:30:42
nit: we dont normally add a "Content" prefix to a
|
| + : public base::SupportsUserData::Data { |
| + public: |
| + ContentURLRequestUserData(int process_id, int routing_id); |
| + // Use this, if no render view can be associated with this request. |
| + ContentURLRequestUserData(); |
| + virtual ~ContentURLRequestUserData(); |
| + |
| + int process_id() const { return process_id_; } |
|
willchan no longer on Chromium
2012/03/01 20:30:10
Somewhere there should be documentation about thes
|
| + int routing_id() const { return routing_id_; } |
| + |
| + static const void* kUserDataKey; |
|
willchan no longer on Chromium
2012/03/01 20:30:10
static const void* const
willchan no longer on Chromium
2012/03/06 02:59:01
?
|
| + |
| + private: |
| + int process_id_; |
| + int routing_id_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(ContentURLRequestUserData); |
| +}; |
| + |
| +} // namespace content |
| + |
| +#endif // CONTENT_PUBLIC_COMMON_CONTENT_URL_REQUEST_USER_DATA_H_ |