|
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ |
|
2 /* This Source Code Form is subject to the terms of the Mozilla Public |
|
3 * License, v. 2.0. If a copy of the MPL was not distributed with this |
|
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
|
5 |
|
6 /** |
|
7 * We support two builds of the directory service provider. |
|
8 * One, linked into the profile component, uses the internal |
|
9 * string API. The other can be used by standalone embedding |
|
10 * clients, and uses embed strings. |
|
11 * To keep the code clean, we are using typedefs to equate |
|
12 * embed/internal string types. We are also defining some |
|
13 * internal macros in terms of the embedding strings API. |
|
14 * |
|
15 * When modifying the profile directory service provider, be |
|
16 * sure to use methods supported by both the internal and |
|
17 * embed strings APIs. |
|
18 */ |
|
19 |
|
20 #ifndef MOZILLA_INTERNAL_API |
|
21 |
|
22 #include "nsEmbedString.h" |
|
23 |
|
24 typedef nsCString nsPromiseFlatCString; |
|
25 typedef nsCString nsAutoCString; |
|
26 |
|
27 #define PromiseFlatCString nsCString |
|
28 |
|
29 #else |
|
30 #include "nsString.h" |
|
31 #include "nsPromiseFlatString.h" |
|
32 #endif |