OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2006 The WebRTC Project Authors. All rights reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 | 11 |
12 // Originally comes from shared/commandlineflags/flags.h | 12 // Originally comes from shared/commandlineflags/flags.h |
13 | 13 |
14 // Flags are defined and declared using DEFINE_xxx and DECLARE_xxx macros, | 14 // Flags are defined and declared using DEFINE_xxx and DECLARE_xxx macros, |
15 // where xxx is the flag type. Flags are referred to via FLAG_yyy, | 15 // where xxx is the flag type. Flags are referred to via FLAG_yyy, |
16 // where yyy is the flag name. For intialization and iteration of flags, | 16 // where yyy is the flag name. For intialization and iteration of flags, |
17 // see the FlagList class. For full programmatic access to any | 17 // see the FlagList class. For full programmatic access to any |
18 // flag, see the Flag class. | 18 // flag, see the Flag class. |
19 // | 19 // |
20 // The implementation only relies and basic C++ functionality | 20 // The implementation only relies and basic C++ functionality |
21 // and needs no special library or STL support. | 21 // and needs no special library or STL support. |
22 | 22 |
23 #ifndef WEBRTC_BASE_FLAGS_H__ | 23 #ifndef WEBRTC_BASE_FLAGS_H__ |
24 #define WEBRTC_BASE_FLAGS_H__ | 24 #define WEBRTC_BASE_FLAGS_H__ |
25 | 25 |
26 #include "webrtc/base/checks.h" | 26 #include "webrtc/base/checks.h" |
27 #include "webrtc/base/common.h" | |
28 #include "webrtc/base/constructormagic.h" | 27 #include "webrtc/base/constructormagic.h" |
29 | 28 |
30 namespace rtc { | 29 namespace rtc { |
31 | 30 |
32 // Internal use only. | 31 // Internal use only. |
33 union FlagValue { | 32 union FlagValue { |
34 // Note: Because in C++ non-bool values are silently converted into | 33 // Note: Because in C++ non-bool values are silently converted into |
35 // bool values ('bool b = "false";' results in b == true!), we pass | 34 // bool values ('bool b = "false";' results in b == true!), we pass |
36 // and int argument to New_BOOL as this appears to be safer - sigh. | 35 // and int argument to New_BOOL as this appears to be safer - sigh. |
37 // In particular, it prevents the (not uncommon!) bug where a bool | 36 // In particular, it prevents the (not uncommon!) bug where a bool |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
260 char **argv_; | 259 char **argv_; |
261 | 260 |
262 private: | 261 private: |
263 RTC_DISALLOW_COPY_AND_ASSIGN(WindowsCommandLineArguments); | 262 RTC_DISALLOW_COPY_AND_ASSIGN(WindowsCommandLineArguments); |
264 }; | 263 }; |
265 #endif // WEBRTC_WIN | 264 #endif // WEBRTC_WIN |
266 | 265 |
267 } // namespace rtc | 266 } // namespace rtc |
268 | 267 |
269 #endif // SHARED_COMMANDLINEFLAGS_FLAGS_H__ | 268 #endif // SHARED_COMMANDLINEFLAGS_FLAGS_H__ |
OLD | NEW |