OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef HttpEquiv_h | 5 #ifndef HttpEquiv_h |
6 #define HttpEquiv_h | 6 #define HttpEquiv_h |
7 | 7 |
8 #include "wtf/Allocator.h" | 8 #include "wtf/Allocator.h" |
9 #include "wtf/text/AtomicString.h" | 9 #include "wtf/text/AtomicString.h" |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 class Document; | 13 class Document; |
14 | 14 |
15 /** | 15 /** |
16 * Handles a HTTP header equivalent set by a meta tag using <meta http-equiv="..
." content="...">. This is called | 16 * Handles a HTTP header equivalent set by a meta tag using <meta http-equiv="..
." content="...">. This is called |
17 * when a meta tag is encountered during document parsing, and also when a scrip
t dynamically changes or adds a meta | 17 * when a meta tag is encountered during document parsing, and also when a scrip
t dynamically changes or adds a meta |
18 * tag. This enables scripts to use meta tags to perform refreshes and set expir
y dates in addition to them being | 18 * tag. This enables scripts to use meta tags to perform refreshes and set expir
y dates in addition to them being |
19 * specified in a HTML file. | 19 * specified in a HTML file. |
20 */ | 20 */ |
21 class HttpEquiv { | 21 class HttpEquiv { |
22 STATIC_ONLY(HttpEquiv); | 22 STATIC_ONLY(HttpEquiv); |
23 public: | 23 public: |
24 static void process(Document&, const AtomicString& equiv, const AtomicString
& content, bool inDocumentHeadElement); | 24 static void process(Document&, const AtomicString& equiv, const AtomicString
& content, bool inDocumentHeadElement); |
25 | 25 |
26 private: | 26 private: |
27 static void processHttpEquivDefaultStyle(Document&, const AtomicString& cont
ent); | 27 static void processHttpEquivDefaultStyle(Document&, const AtomicString& cont
ent); |
28 static void processHttpEquivRefresh(Document&, const AtomicString& content); | 28 static void processHttpEquivRefresh(Document&, const AtomicString& content); |
29 static void processHttpEquivSetCookie(Document&, const AtomicString& content
); | 29 static void processHttpEquivSetCookie(Document&, const AtomicString& content
); |
30 static void processHttpEquivXFrameOptions(Document&, const AtomicString& con
tent); | |
31 static void processHttpEquivContentSecurityPolicy(Document&, const AtomicStr
ing& equiv, const AtomicString& content); | 30 static void processHttpEquivContentSecurityPolicy(Document&, const AtomicStr
ing& equiv, const AtomicString& content); |
32 static void processHttpEquivAcceptCH(Document&, const AtomicString& content)
; | 31 static void processHttpEquivAcceptCH(Document&, const AtomicString& content)
; |
33 }; | 32 }; |
34 | 33 |
35 } // namespace blink | 34 } // namespace blink |
36 | 35 |
37 #endif | 36 #endif |
OLD | NEW |