Index: content/public/common/referrer.h |
diff --git a/content/public/common/referrer.h b/content/public/common/referrer.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..8d8f71a07333da94dfddcbd10c6ccec8aa1d10f0 |
--- /dev/null |
+++ b/content/public/common/referrer.h |
@@ -0,0 +1,34 @@ |
+// Copyright (c) 2011 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_BROWSER_TAB_CONTENTS_REFERRER_H_ |
jam
2011/11/24 21:17:35
CONTENT_PUBLIC_COMMON_REFERRER_H_, presubmit would
jochen (gone - plz use gerrit)
2011/11/24 23:02:40
actually, it doesn't... strange :-/
|
+#define CONTENT_BROWSER_TAB_CONTENTS_REFERRER_H_ |
+#pragma once |
+ |
+#include "base/basictypes.h" |
+#include "content/common/content_export.h" |
+#include "googleurl/src/gurl.h" |
+#include "third_party/WebKit/Source/WebKit/chromium/public/WebReferrerPolicy.h" |
+ |
+namespace content { |
+ |
+// This class holds a referrer URL, as well as the referrer policy to be |
+// applied to this URL. When passing around referrers that will eventually end |
+// up being used for URL requests, always use this class. |
+class CONTENT_EXPORT Referrer { |
jam
2011/11/24 21:17:35
this seems like it should just be a struct (perhap
jochen (gone - plz use gerrit)
2011/11/24 23:02:40
Done.
|
+ public: |
+ Referrer(const GURL& referrer, WebKit::WebReferrerPolicy referrer_policy); |
+ Referrer(); |
+ |
+ const GURL& url() const { return url_; } |
+ WebKit::WebReferrerPolicy policy() const { return policy_; } |
+ |
+ private: |
+ GURL url_; |
+ WebKit::WebReferrerPolicy policy_; |
+}; |
+ |
+} // namespace content |
+ |
+#endif // CONTENT_BROWSER_TAB_CONTENTS_REFERRER_H_ |