1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* ***** BEGIN LICENSE BLOCK *****
3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 * http://www.mozilla.org/MPL/
10 * Software distributed under the License is distributed on an "AS IS" basis,
11 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 * for the specific language governing rights and limitations under the
15 * The Original Code is mozilla.org code.
17 * The Initial Developer of the Original Code is
18 * Netscape Communications Corporation.
19 * Portions created by the Initial Developer are Copyright (C) 1998
20 * the Initial Developer. All Rights Reserved.
24 * Alternatively, the contents of this file may be used under the terms of
25 * either of the GNU General Public License Version 2 or later (the "GPL"),
26 * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 * in which case the provisions of the GPL or the LGPL are applicable instead
28 * of those above. If you wish to allow use of your version of this file only
29 * under the terms of either the GPL or the LGPL, and not to allow others to
30 * use your version of this file under the terms of the MPL, indicate your
31 * decision by deleting the provisions above and replace them with the notice
32 * and other provisions required by the GPL or the LGPL. If you do not delete
33 * the provisions above, a recipient may use your version of this file under
34 * the terms of any one of the MPL, the GPL or the LGPL.
36 * ***** END LICENSE BLOCK ***** */
38 // Force references to all of the symbols that we want exported from
39 // the dll that are located in the .lib files we link with
44 #include "nsXPCOMGlue.h"
45 #include "nsVoidArray.h"
48 #include "nsFixedSizeAllocator.h"
49 #include "nsRecyclingAllocator.h"
51 #include "nsTraceRefcnt.h"
52 #include "nsTraceRefcntImpl.h"
53 #include "nsXPIDLString.h"
54 #include "nsIEnumerator.h"
55 #include "nsEnumeratorUtils.h"
56 #include "nsQuickSort.h"
58 #include "nsPrintfCString.h"
59 #include "nsSupportsArray.h"
60 #include "nsArrayEnumerator.h"
61 #include "nsProxyRelease.h"
64 #include "nsILocalFile.h"
65 #include "nsIGenericFactory.h"
67 #include "nsStreamUtils.h"
68 #include "nsWeakReference.h"
69 #include "nsTextFormatter.h"
70 #include "nsIStorageStream.h"
71 #include "nsStringStream.h"
72 #include "nsLinebreakConverter.h"
73 #include "nsIBinaryInputStream.h"
74 #include "nsIInterfaceRequestor.h"
75 #include "nsIInterfaceRequestorUtils.h"
76 #include "nsReadableUtils.h"
77 #include "nsStaticNameTable.h"
78 #include "nsProcess.h"
79 #include "nsStringEnumerator.h"
80 #include "nsIInputStreamTee.h"
81 #include "nsCheapSets.h"
82 #if defined(DEBUG) && !defined(XP_OS2)
85 #include "nsHashKeys.h"
86 #include "nsTHashtable.h"
88 #include "nsVariant.h"
90 #include "nsStreamUtils.h"
91 #include "nsNativeCharsetUtils.h"
92 #include "nsInterfaceRequestorAgg.h"
93 #include "nsHashPropertyBag.h"
94 #include "nsXPCOMStrings.h"
95 #include "nsStringBuffer.h"
96 #include "nsCategoryCache.h"
97 #include "nsCycleCollectionParticipant.h"
98 #include "nsCycleCollector.h"
99 #include "nsThreadUtils.h"
100 #include "nsTObserverArray.h"
103 #include "nsWindowsRegKey.h"
106 class nsCStringContainer
: private nsStringContainer_base
{ };
107 class nsStringContainer
: private nsStringContainer_base
{ };
109 void XXXNeverCalled()
111 GRE_GetGREPathWithProperties(nsnull
, 0, nsnull
, 0, nsnull
, 0);
112 nsTextFormatter::snprintf(nsnull
,0,nsnull
);
113 nsTextFormatter::smprintf(nsnull
, nsnull
);
114 nsTextFormatter::smprintf_free(nsnull
);
118 nsTArray
<PRBool
> array1(1), array2(1);
120 a
= b
= c
= PR_FALSE
;
121 array1
.AppendElement(a
);
122 array2
.InsertElementAt(b
, 0);
123 array2
.InsertElementAt(c
, 0);
124 array1
.AppendElements(array2
);
127 nsTObserverArray
<PRBool
> dummyObserverArray
;
129 dummyObserverArray
.AppendElement(a
);
130 dummyObserverArray
.RemoveElement(a
);
131 dummyObserverArray
.Clear();
140 NS_GetNumberOfAtoms();
141 NS_NewPipe(nsnull
, nsnull
, 0, 0, PR_FALSE
, PR_FALSE
, nsnull
);
142 NS_NewPipe2(nsnull
, nsnull
, PR_FALSE
, PR_FALSE
, 0, 0, nsnull
);
143 NS_NewInputStreamReadyEvent(nsnull
, nsnull
, nsnull
);
144 NS_NewOutputStreamReadyEvent(nsnull
, nsnull
, nsnull
);
145 NS_AsyncCopy(nsnull
, nsnull
, nsnull
, NS_ASYNCCOPY_VIA_READSEGMENTS
, 0, nsnull
, nsnull
);
148 NS_ConsumeStream(nsnull
, 0, temp
);
150 NS_InputStreamIsBuffered(nsnull
);
151 NS_OutputStreamIsBuffered(nsnull
);
152 NS_CopySegmentToStream(nsnull
, nsnull
, nsnull
, 0, 0, nsnull
);
153 NS_CopySegmentToBuffer(nsnull
, nsnull
, nsnull
, 0, 0, nsnull
);
154 NS_DiscardSegment(nsnull
, nsnull
, nsnull
, 0, 0, nsnull
);
155 NS_WriteSegmentThunk(nsnull
, nsnull
, nsnull
, 0, 0, 0);
156 NS_NewByteInputStream(nsnull
, nsnull
, 0, NS_ASSIGNMENT_COPY
);
157 NS_NewCStringInputStream(nsnull
, nsCString());
158 NS_NewStringInputStream(nsnull
, nsString());
159 PL_DHashStubEnumRemove(nsnull
, nsnull
, nsnull
, nsnull
);
160 nsIDHashKey::HashKey(nsnull
);
161 nsFixedSizeAllocator a
;
162 nsRecyclingAllocator
recyclingAllocator(2);
163 a
.Init(0, 0, 0, 0, 0);
167 nsDequeIterator
di(d
);
168 nsTraceRefcnt::LogAddCOMPtr(nsnull
, nsnull
);
169 nsTraceRefcntImpl::DumpStatistics();
170 NS_NewEmptyEnumerator(nsnull
);
171 NS_QuickSort(nsnull
, 0, 0, nsnull
, nsnull
);
173 NS_ProxyRelease(nsnull
, nsnull
, PR_FALSE
);
174 XPT_DoString(nsnull
, nsnull
, nsnull
);
175 XPT_DoHeader(nsnull
, nsnull
, nsnull
);
176 #if defined (DEBUG) && !defined (WINCE) && !defined(XP_OS2)
179 NS_InvokeByIndex(nsnull
, 0, 0, nsnull
);
180 NS_NewGenericFactory(nsnull
, nsnull
);
181 NS_NewGenericModule2(nsnull
, nsnull
);
182 NS_GetWeakReference(nsnull
);
183 nsCOMPtr
<nsISupports
> dummyFoo(do_GetInterface(nsnull
));
184 NS_NewStorageStream(0,0, nsnull
);
186 nsPrintfCString
bar("");
187 nsLinebreakConverter::ConvertStringLineBreaks(foo
,
188 nsLinebreakConverter::eLinebreakAny
, nsLinebreakConverter::eLinebreakContent
);
189 NS_NewLocalFile(EmptyString(), PR_FALSE
, nsnull
);
190 NS_NewNativeLocalFile(EmptyCString(), PR_FALSE
, nsnull
);
192 nsStaticCaseInsensitiveNameTable();
194 str1
.AssignWithConversion(nsnull
, 0);
200 PL_DHashTableFinish(nsnull
);
201 NS_NewInputStreamTee(nsnull
, nsnull
, nsnull
);
202 nsCOMArray
<nsISupports
> dummyArray
;
203 NS_NewArrayEnumerator(nsnull
, dummyArray
);
206 nsEscape(nsnull
, url_XAlphas
);
208 NS_NewStringEnumerator(nsnull
, &array
);
209 NS_NewAdoptingStringEnumerator(nsnull
, &array
);
210 nsCStringArray carray
;
211 NS_NewUTF8StringEnumerator(nsnull
, &carray
);
212 NS_NewAdoptingUTF8StringEnumerator(nsnull
, &carray
);
213 nsVoidableString str3
;
215 nsAdoptingCString foo
, bar
;
219 nsAdoptingString foo
, bar
;
222 NS_CopyNativeToUnicode(str2
, str1
);
223 NS_CopyUnicodeToNative(str1
, str2
);
226 CallCreateInstance(id
, nsnull
, id
, nsnull
);
227 CallCreateInstance("", nsnull
, id
, nsnull
);
228 CallGetClassObject(id
, id
, nsnull
);
229 CallGetClassObject("", id
, nsnull
);
231 nsServiceManager::GetGlobalServiceManager(nsnull
);
233 NS_NewInterfaceRequestorAggregation(nsnull
, nsnull
, nsnull
);
234 NS_NewHashPropertyBag(nsnull
);
235 nsDependentString depstring
;
236 depstring
.Rebind(nsnull
, PRUint32(0));
237 nsDependentCString depcstring
;
238 depcstring
.Rebind(nsnull
, PRUint32(0));
240 nsCStringContainer sc1
;
241 NS_CStringContainerInit(sc1
);
242 NS_CStringContainerInit2(sc1
, nsnull
, 0, 0);
243 NS_CStringContainerFinish(sc1
);
244 NS_CStringGetData(str2
, nsnull
, nsnull
);
245 NS_CStringGetMutableData(str2
, 0, nsnull
);
246 NS_CStringSetData(str2
, nsnull
, 0);
247 NS_CStringSetDataRange(str2
, 0, 0, nsnull
, 0);
248 NS_CStringCopy(str2
, str2
);
249 NS_CStringCloneData(str2
);
250 nsStringContainer sc2
;
251 NS_StringContainerInit(sc2
);
252 NS_StringContainerInit2(sc2
, nsnull
, 0, 0);
253 NS_StringContainerFinish(sc2
);
254 NS_StringGetData(str1
, nsnull
, nsnull
);
255 NS_StringGetMutableData(str1
, 0, nsnull
);
256 NS_StringSetData(str1
, nsnull
, 0);
257 NS_StringSetDataRange(str1
, 0, 0, nsnull
, 0);
258 NS_StringCopy(str1
, str1
);
259 NS_StringCloneData(str1
);
260 NS_UTF16ToCString(str1
, NS_CSTRING_ENCODING_ASCII
, str2
);
261 NS_CStringToUTF16(str2
, NS_CSTRING_ENCODING_ASCII
, str1
);
263 nsCategoryObserver
catobs(nsnull
, nsnull
);
264 nsCategoryCache
<nsILocalFile
> catcache(nsnull
);
273 nsStringBuffer::Alloc(0);
274 nsStringBuffer::Realloc(nsnull
, 0);
275 nsStringBuffer::FromString(x
);
276 nsStringBuffer::FromString(y
);
281 nsXPCOMCycleCollectionParticipant();
282 nsCycleCollector_collect();
285 NS_NewWindowsRegKey(nsnull
);
288 NS_NewThread(nsnull
, nsnull
);
289 NS_GetCurrentThread(nsnull
);
290 NS_GetCurrentThread();
291 NS_GetMainThread(nsnull
);
292 NS_DispatchToCurrentThread(nsnull
);
293 NS_DispatchToMainThread(nsnull
, 0);
294 NS_ProcessPendingEvents(nsnull
, 0);
295 NS_HasPendingEvents(nsnull
);
296 NS_ProcessNextEvent(nsnull
, PR_FALSE
);