| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "mojo/shell/switches.h" | 5 #include "mojo/shell/switches.h" |
| 6 | 6 |
| 7 #include "base/basictypes.h" |
| 8 |
| 7 namespace switches { | 9 namespace switches { |
| 8 | 10 |
| 9 // Specify configuration arguments for a Mojo application URL. For example: | 11 // Specify configuration arguments for a Mojo application URL. For example: |
| 10 // --args-for='mojo:wget http://www.google.com' | 12 // --args-for='mojo:wget http://www.google.com' |
| 11 const char kArgsFor[] = "args-for"; | 13 const char kArgsFor[] = "args-for"; |
| 12 | 14 |
| 13 // Used to specify the type of child process (switch values from | 15 // Used to specify the type of child process (switch values from |
| 14 // |ChildProcess::Type|). | 16 // |ChildProcess::Type|). |
| 15 const char kChildProcessType[] = "child-process-type"; | 17 const char kChildProcessType[] = "child-process-type"; |
| 16 | 18 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 42 // Enables the mojo spy, which acts as a man-in-the-middle inspector for | 44 // Enables the mojo spy, which acts as a man-in-the-middle inspector for |
| 43 // message pipes and other activities. This is work in progress. | 45 // message pipes and other activities. This is work in progress. |
| 44 const char kSpy[] = "spy"; | 46 const char kSpy[] = "spy"; |
| 45 | 47 |
| 46 // Specifies a set of mappings to apply when resolving urls. The value is set of | 48 // Specifies a set of mappings to apply when resolving urls. The value is set of |
| 47 // ',' separated mappings, where each mapping consists of a pair of urls giving | 49 // ',' separated mappings, where each mapping consists of a pair of urls giving |
| 48 // the to/from url to map. For example, 'a=b,c=d' contains two mappings, the | 50 // the to/from url to map. For example, 'a=b,c=d' contains two mappings, the |
| 49 // first maps 'a' to 'b' and the second 'c' to 'd'. | 51 // first maps 'a' to 'b' and the second 'c' to 'd'. |
| 50 const char kURLMappings[] = "url-mappings"; | 52 const char kURLMappings[] = "url-mappings"; |
| 51 | 53 |
| 54 const char* kSwitchArray[] = { |
| 55 kArgsFor, |
| 56 kChildProcessType, |
| 57 kContentHandlers, |
| 58 kDisableCache, |
| 59 kEnableExternalApplications, |
| 60 kEnableMultiprocess, |
| 61 kHelp, |
| 62 kOrigin, |
| 63 kSpy, |
| 64 kURLMappings |
| 65 }; |
| 66 |
| 67 const std::set<std::string> GetAllSwitches() { |
| 68 std::set<std::string> switch_set; |
| 69 |
| 70 for (size_t i = 0; i < arraysize(kSwitchArray); ++i) |
| 71 switch_set.insert(kSwitchArray[i]); |
| 72 return switch_set; |
| 73 } |
| 74 |
| 52 } // namespace switches | 75 } // namespace switches |
| OLD | NEW |