Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(590)

Side by Side Diff: content/renderer/manifest/manifest_parser.h

Issue 2063003003: Implement "scope" Web Manifest parsing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge branch 'webapk_manifest_scope00' into webapk_manifest_scope0 Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « content/public/common/manifest.cc ('k') | content/renderer/manifest/manifest_parser.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_ 5 #ifndef CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_
6 #define CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_ 6 #define CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-name-member 83 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-name-member
84 // Returns the parsed string if any, a null string if the parsing failed. 84 // Returns the parsed string if any, a null string if the parsing failed.
85 base::NullableString16 ParseName(const base::DictionaryValue& dictionary); 85 base::NullableString16 ParseName(const base::DictionaryValue& dictionary);
86 86
87 // Parses the 'short_name' field of the manifest, as defined in: 87 // Parses the 'short_name' field of the manifest, as defined in:
88 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-short-name-memb er 88 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-short-name-memb er
89 // Returns the parsed string if any, a null string if the parsing failed. 89 // Returns the parsed string if any, a null string if the parsing failed.
90 base::NullableString16 ParseShortName( 90 base::NullableString16 ParseShortName(
91 const base::DictionaryValue& dictionary); 91 const base::DictionaryValue& dictionary);
92 92
93 // Parses the 'scope' field of the manifest, as defined in:
94 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-scope-member
95 // Returns the parsed GURL if any, an empty GURL if the parsing failed.
96 GURL ParseScope(const base::DictionaryValue& dictionary,
97 const GURL& start_url);
98
93 // Parses the 'start_url' field of the manifest, as defined in: 99 // Parses the 'start_url' field of the manifest, as defined in:
94 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-start_url-membe r 100 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-start_url-membe r
95 // Returns the parsed GURL if any, an empty GURL if the parsing failed. 101 // Returns the parsed GURL if any, an empty GURL if the parsing failed.
96 GURL ParseStartURL(const base::DictionaryValue& dictionary); 102 GURL ParseStartURL(const base::DictionaryValue& dictionary);
97 103
98 // Parses the 'display' field of the manifest, as defined in: 104 // Parses the 'display' field of the manifest, as defined in:
99 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-display-member 105 // http://w3c.github.io/manifest/#dfn-steps-for-processing-the-display-member
100 // Returns the parsed DisplayMode if any, WebDisplayModeUndefined if the 106 // Returns the parsed DisplayMode if any, WebDisplayModeUndefined if the
101 // parsing failed. 107 // parsing failed.
102 blink::WebDisplayMode ParseDisplay(const base::DictionaryValue& dictionary); 108 blink::WebDisplayMode ParseDisplay(const base::DictionaryValue& dictionary);
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 bool failed_; 199 bool failed_;
194 Manifest manifest_; 200 Manifest manifest_;
195 std::vector<ManifestDebugInfo::Error> errors_; 201 std::vector<ManifestDebugInfo::Error> errors_;
196 202
197 DISALLOW_COPY_AND_ASSIGN(ManifestParser); 203 DISALLOW_COPY_AND_ASSIGN(ManifestParser);
198 }; 204 };
199 205
200 } // namespace content 206 } // namespace content
201 207
202 #endif // CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_ 208 #endif // CONTENT_RENDERER_MANIFEST_MANIFEST_PARSER_H_
OLDNEW
« no previous file with comments | « content/public/common/manifest.cc ('k') | content/renderer/manifest/manifest_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698