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

Side by Side Diff: shell/command_line_util.h

Issue 816473002: Update mojo shell so that --args-for can be used on android (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Refactor and add unit tests Created 6 years 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef SHELL_COMMAND_LINE_UTIL_H_
6 #define SHELL_COMMAND_LINE_UTIL_H_
7
8 #include "shell/context.h"
9
10 namespace mojo {
11 namespace shell {
12
13 // Parce the given arg, looking for an --args-for switch. If this is not the
sky 2014/12/18 17:01:15 parce->parse
qsr 2014/12/18 17:17:56 Done.
14 // // case, returns |false|. Otherwise, returns |true| and set |*value| to the
sky 2014/12/18 17:01:15 you've got double the comments here: // //
qsr 2014/12/18 17:17:56 Done.
15 // // value of the switch.
16 bool ParseArgsFor(const std::string& arg, std::string* value);
17
18 // The value of app_url_and_args is "<mojo_app_url> [<args>...]", where args
19 // is a list of "configuration" arguments separated by spaces. If one or more
20 // arguments are specified they will be available when the Mojo application
21 // is initialized. This returns the mojo_app_url, and set args to the list of
22 // arguments.
23 GURL GetAppURLAndArgs(const std::string& app_url_and_args,
24 std::vector<std::string>* args);
25
26 // Apply arguments for an application from a line with the following format:
27 // '--args-for=application_url arg1 arg2 arg3'
28 // This does nothing if the line has not the right format.
29 void ApplyApplicationArgs(Context* context, const std::string& args);
30
31 // Run all application defined on the command line, using the given context.
32 void RunCommandLineApps(Context* context);
33
34 } // namespace shell
35 } // namespace mojo
36
37 #endif // SHELL_COMMAND_LINE_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698