/work/obj-fuzz/dist/include/nsISHistory.h
Line | Count | Source (jump to first uncovered line) |
1 | | /* |
2 | | * DO NOT EDIT. THIS FILE IS GENERATED FROM /src/mozilla-central/docshell/shistory/nsISHistory.idl |
3 | | */ |
4 | | |
5 | | #ifndef __gen_nsISHistory_h__ |
6 | | #define __gen_nsISHistory_h__ |
7 | | |
8 | | |
9 | | #ifndef __gen_nsISupports_h__ |
10 | | #include "nsISupports.h" |
11 | | #endif |
12 | | |
13 | | #include "mozilla/AlreadyAddRefed.h" |
14 | | #include "mozilla/Assertions.h" |
15 | | #include "mozilla/DebugOnly.h" |
16 | | |
17 | | /* For IDL files that don't want to include root IDL files. */ |
18 | | #ifndef NS_NO_VTABLE |
19 | | #define NS_NO_VTABLE |
20 | | #endif |
21 | | class nsIBFCacheEntry; /* forward declaration */ |
22 | | |
23 | | class nsIDocShell; /* forward declaration */ |
24 | | |
25 | | class nsISHEntry; /* forward declaration */ |
26 | | |
27 | | class nsISHistoryListener; /* forward declaration */ |
28 | | |
29 | | class nsIURI; /* forward declaration */ |
30 | | |
31 | | #include "nsTArrayForwardDeclare.h" |
32 | | |
33 | | /* starting interface: nsISHistory */ |
34 | | #define NS_ISHISTORY_IID_STR "7b807041-e60a-4384-935f-af3061d8b815" |
35 | | |
36 | | #define NS_ISHISTORY_IID \ |
37 | | {0x7b807041, 0xe60a, 0x4384, \ |
38 | | { 0x93, 0x5f, 0xaf, 0x30, 0x61, 0xd8, 0xb8, 0x15 }} |
39 | | |
40 | | class NS_NO_VTABLE nsISHistory : public nsISupports { |
41 | | public: |
42 | | |
43 | | NS_DECLARE_STATIC_IID_ACCESSOR(NS_ISHISTORY_IID) |
44 | | |
45 | | /* [infallible] readonly attribute long count; */ |
46 | | NS_IMETHOD GetCount(int32_t *aCount) = 0; |
47 | | inline int32_t GetCount() |
48 | 0 | { |
49 | 0 | int32_t result; |
50 | 0 | mozilla::DebugOnly<nsresult> rv = GetCount(&result); |
51 | 0 | MOZ_ASSERT(NS_SUCCEEDED(rv)); |
52 | 0 | return result; |
53 | 0 | } |
54 | | |
55 | | /* attribute long index; */ |
56 | | NS_IMETHOD GetIndex(int32_t *aIndex) = 0; |
57 | | NS_IMETHOD SetIndex(int32_t aIndex) = 0; |
58 | | |
59 | | /* [infallible] readonly attribute long requestedIndex; */ |
60 | | NS_IMETHOD GetRequestedIndex(int32_t *aRequestedIndex) = 0; |
61 | | inline int32_t GetRequestedIndex() |
62 | 0 | { |
63 | 0 | int32_t result; |
64 | 0 | mozilla::DebugOnly<nsresult> rv = GetRequestedIndex(&result); |
65 | 0 | MOZ_ASSERT(NS_SUCCEEDED(rv)); |
66 | 0 | return result; |
67 | 0 | } |
68 | | |
69 | | /* nsISHEntry getEntryAtIndex (in long aIndex); */ |
70 | | NS_IMETHOD GetEntryAtIndex(int32_t aIndex, nsISHEntry **_retval) = 0; |
71 | | |
72 | | /* void PurgeHistory (in long aNumEntries); */ |
73 | | NS_IMETHOD PurgeHistory(int32_t aNumEntries) = 0; |
74 | | |
75 | | /* void addSHistoryListener (in nsISHistoryListener aListener); */ |
76 | | NS_IMETHOD AddSHistoryListener(nsISHistoryListener *aListener) = 0; |
77 | | |
78 | | /* void removeSHistoryListener (in nsISHistoryListener aListener); */ |
79 | | NS_IMETHOD RemoveSHistoryListener(nsISHistoryListener *aListener) = 0; |
80 | | |
81 | | /* void reloadCurrentEntry (); */ |
82 | | NS_IMETHOD ReloadCurrentEntry(void) = 0; |
83 | | |
84 | | /* [noscript] void gotoIndex (in long aIndex); */ |
85 | | NS_IMETHOD GotoIndex(int32_t aIndex) = 0; |
86 | | |
87 | | /* [noscript,notxpcom] long getIndexOfEntry (in nsISHEntry aEntry); */ |
88 | | NS_IMETHOD_(int32_t) GetIndexOfEntry(nsISHEntry *aEntry) = 0; |
89 | | |
90 | | /* void addEntry (in nsISHEntry aEntry, in boolean aPersist); */ |
91 | | NS_IMETHOD AddEntry(nsISHEntry *aEntry, bool aPersist) = 0; |
92 | | |
93 | | /* [noscript,notxpcom] void setRootDocShell (in nsIDocShell rootDocShell); */ |
94 | | NS_IMETHOD_(void) SetRootDocShell(nsIDocShell *rootDocShell) = 0; |
95 | | |
96 | | /* void updateIndex (); */ |
97 | | NS_IMETHOD UpdateIndex(void) = 0; |
98 | | |
99 | | /* void replaceEntry (in long aIndex, in nsISHEntry aReplaceEntry); */ |
100 | | NS_IMETHOD ReplaceEntry(int32_t aIndex, nsISHEntry *aReplaceEntry) = 0; |
101 | | |
102 | | /* boolean notifyOnHistoryReload (in nsIURI aReloadURI, in unsigned long aReloadFlags); */ |
103 | | NS_IMETHOD NotifyOnHistoryReload(nsIURI *aReloadURI, uint32_t aReloadFlags, bool *_retval) = 0; |
104 | | |
105 | | /* void evictOutOfRangeContentViewers (in long aIndex); */ |
106 | | NS_IMETHOD EvictOutOfRangeContentViewers(int32_t aIndex) = 0; |
107 | | |
108 | | /* void evictExpiredContentViewerForEntry (in nsIBFCacheEntry aEntry); */ |
109 | | NS_IMETHOD EvictExpiredContentViewerForEntry(nsIBFCacheEntry *aEntry) = 0; |
110 | | |
111 | | /* void evictAllContentViewers (); */ |
112 | | NS_IMETHOD EvictAllContentViewers(void) = 0; |
113 | | |
114 | | /* [noscript,notxpcom] void addToExpirationTracker (in nsIBFCacheEntry aEntry); */ |
115 | | NS_IMETHOD_(void) AddToExpirationTracker(nsIBFCacheEntry *aEntry) = 0; |
116 | | |
117 | | /* [noscript,notxpcom] void removeFromExpirationTracker (in nsIBFCacheEntry aEntry); */ |
118 | | NS_IMETHOD_(void) RemoveFromExpirationTracker(nsIBFCacheEntry *aEntry) = 0; |
119 | | |
120 | | /* [noscript,notxpcom] void RemoveDynEntries (in long aIndex, in nsISHEntry aEntry); */ |
121 | | NS_IMETHOD_(void) RemoveDynEntries(int32_t aIndex, nsISHEntry *aEntry) = 0; |
122 | | |
123 | | /* [noscript,notxpcom] void RemoveDynEntriesForBFCacheEntry (in nsIBFCacheEntry aEntry); */ |
124 | | NS_IMETHOD_(void) RemoveDynEntriesForBFCacheEntry(nsIBFCacheEntry *aEntry) = 0; |
125 | | |
126 | | /* [noscript,notxpcom] void RemoveEntries (in nsDocshellIDArray aIDs, in long aStartIndex); */ |
127 | | NS_IMETHOD_(void) RemoveEntries(nsTArray<nsID> & aIDs, int32_t aStartIndex) = 0; |
128 | | |
129 | | }; |
130 | | |
131 | | NS_DEFINE_STATIC_IID_ACCESSOR(nsISHistory, NS_ISHISTORY_IID) |
132 | | |
133 | | /* Use this macro when declaring classes that implement this interface. */ |
134 | | #define NS_DECL_NSISHISTORY \ |
135 | | using nsISHistory::GetCount; \ |
136 | | NS_IMETHOD GetCount(int32_t *aCount) override; \ |
137 | | NS_IMETHOD GetIndex(int32_t *aIndex) override; \ |
138 | | NS_IMETHOD SetIndex(int32_t aIndex) override; \ |
139 | | using nsISHistory::GetRequestedIndex; \ |
140 | | NS_IMETHOD GetRequestedIndex(int32_t *aRequestedIndex) override; \ |
141 | | NS_IMETHOD GetEntryAtIndex(int32_t aIndex, nsISHEntry **_retval) override; \ |
142 | | NS_IMETHOD PurgeHistory(int32_t aNumEntries) override; \ |
143 | | NS_IMETHOD AddSHistoryListener(nsISHistoryListener *aListener) override; \ |
144 | | NS_IMETHOD RemoveSHistoryListener(nsISHistoryListener *aListener) override; \ |
145 | | NS_IMETHOD ReloadCurrentEntry(void) override; \ |
146 | | NS_IMETHOD GotoIndex(int32_t aIndex) override; \ |
147 | | NS_IMETHOD_(int32_t) GetIndexOfEntry(nsISHEntry *aEntry) override; \ |
148 | | NS_IMETHOD AddEntry(nsISHEntry *aEntry, bool aPersist) override; \ |
149 | | NS_IMETHOD_(void) SetRootDocShell(nsIDocShell *rootDocShell) override; \ |
150 | | NS_IMETHOD UpdateIndex(void) override; \ |
151 | | NS_IMETHOD ReplaceEntry(int32_t aIndex, nsISHEntry *aReplaceEntry) override; \ |
152 | | NS_IMETHOD NotifyOnHistoryReload(nsIURI *aReloadURI, uint32_t aReloadFlags, bool *_retval) override; \ |
153 | | NS_IMETHOD EvictOutOfRangeContentViewers(int32_t aIndex) override; \ |
154 | | NS_IMETHOD EvictExpiredContentViewerForEntry(nsIBFCacheEntry *aEntry) override; \ |
155 | | NS_IMETHOD EvictAllContentViewers(void) override; \ |
156 | | NS_IMETHOD_(void) AddToExpirationTracker(nsIBFCacheEntry *aEntry) override; \ |
157 | | NS_IMETHOD_(void) RemoveFromExpirationTracker(nsIBFCacheEntry *aEntry) override; \ |
158 | | NS_IMETHOD_(void) RemoveDynEntries(int32_t aIndex, nsISHEntry *aEntry) override; \ |
159 | | NS_IMETHOD_(void) RemoveDynEntriesForBFCacheEntry(nsIBFCacheEntry *aEntry) override; \ |
160 | | NS_IMETHOD_(void) RemoveEntries(nsTArray<nsID> & aIDs, int32_t aStartIndex) override; |
161 | | |
162 | | /* Use this macro when declaring the members of this interface when the |
163 | | class doesn't implement the interface. This is useful for forwarding. */ |
164 | | #define NS_DECL_NON_VIRTUAL_NSISHISTORY \ |
165 | | using nsISHistory::GetCount; \ |
166 | | nsresult GetCount(int32_t *aCount); \ |
167 | | nsresult GetIndex(int32_t *aIndex); \ |
168 | | nsresult SetIndex(int32_t aIndex); \ |
169 | | using nsISHistory::GetRequestedIndex; \ |
170 | | nsresult GetRequestedIndex(int32_t *aRequestedIndex); \ |
171 | | nsresult GetEntryAtIndex(int32_t aIndex, nsISHEntry **_retval); \ |
172 | | nsresult PurgeHistory(int32_t aNumEntries); \ |
173 | | nsresult AddSHistoryListener(nsISHistoryListener *aListener); \ |
174 | | nsresult RemoveSHistoryListener(nsISHistoryListener *aListener); \ |
175 | | nsresult ReloadCurrentEntry(void); \ |
176 | | nsresult GotoIndex(int32_t aIndex); \ |
177 | | nsresult_(int32_t) GetIndexOfEntry(nsISHEntry *aEntry); \ |
178 | | nsresult AddEntry(nsISHEntry *aEntry, bool aPersist); \ |
179 | | nsresult_(void) SetRootDocShell(nsIDocShell *rootDocShell); \ |
180 | | nsresult UpdateIndex(void); \ |
181 | | nsresult ReplaceEntry(int32_t aIndex, nsISHEntry *aReplaceEntry); \ |
182 | | nsresult NotifyOnHistoryReload(nsIURI *aReloadURI, uint32_t aReloadFlags, bool *_retval); \ |
183 | | nsresult EvictOutOfRangeContentViewers(int32_t aIndex); \ |
184 | | nsresult EvictExpiredContentViewerForEntry(nsIBFCacheEntry *aEntry); \ |
185 | | nsresult EvictAllContentViewers(void); \ |
186 | | nsresult_(void) AddToExpirationTracker(nsIBFCacheEntry *aEntry); \ |
187 | | nsresult_(void) RemoveFromExpirationTracker(nsIBFCacheEntry *aEntry); \ |
188 | | nsresult_(void) RemoveDynEntries(int32_t aIndex, nsISHEntry *aEntry); \ |
189 | | nsresult_(void) RemoveDynEntriesForBFCacheEntry(nsIBFCacheEntry *aEntry); \ |
190 | | nsresult_(void) RemoveEntries(nsTArray<nsID> & aIDs, int32_t aStartIndex); |
191 | | |
192 | | /* Use this macro to declare functions that forward the behavior of this interface to another object. */ |
193 | | #define NS_FORWARD_NSISHISTORY(_to) \ |
194 | | using nsISHistory::GetCount; \ |
195 | | NS_IMETHOD GetCount(int32_t *aCount) override { return _to GetCount(aCount); } \ |
196 | | NS_IMETHOD GetIndex(int32_t *aIndex) override { return _to GetIndex(aIndex); } \ |
197 | | NS_IMETHOD SetIndex(int32_t aIndex) override { return _to SetIndex(aIndex); } \ |
198 | | using nsISHistory::GetRequestedIndex; \ |
199 | | NS_IMETHOD GetRequestedIndex(int32_t *aRequestedIndex) override { return _to GetRequestedIndex(aRequestedIndex); } \ |
200 | | NS_IMETHOD GetEntryAtIndex(int32_t aIndex, nsISHEntry **_retval) override { return _to GetEntryAtIndex(aIndex, _retval); } \ |
201 | | NS_IMETHOD PurgeHistory(int32_t aNumEntries) override { return _to PurgeHistory(aNumEntries); } \ |
202 | | NS_IMETHOD AddSHistoryListener(nsISHistoryListener *aListener) override { return _to AddSHistoryListener(aListener); } \ |
203 | | NS_IMETHOD RemoveSHistoryListener(nsISHistoryListener *aListener) override { return _to RemoveSHistoryListener(aListener); } \ |
204 | | NS_IMETHOD ReloadCurrentEntry(void) override { return _to ReloadCurrentEntry(); } \ |
205 | | NS_IMETHOD GotoIndex(int32_t aIndex) override { return _to GotoIndex(aIndex); } \ |
206 | | NS_IMETHOD_(int32_t) GetIndexOfEntry(nsISHEntry *aEntry) override { return _to GetIndexOfEntry(aEntry); } \ |
207 | | NS_IMETHOD AddEntry(nsISHEntry *aEntry, bool aPersist) override { return _to AddEntry(aEntry, aPersist); } \ |
208 | | NS_IMETHOD_(void) SetRootDocShell(nsIDocShell *rootDocShell) override { return _to SetRootDocShell(rootDocShell); } \ |
209 | | NS_IMETHOD UpdateIndex(void) override { return _to UpdateIndex(); } \ |
210 | | NS_IMETHOD ReplaceEntry(int32_t aIndex, nsISHEntry *aReplaceEntry) override { return _to ReplaceEntry(aIndex, aReplaceEntry); } \ |
211 | | NS_IMETHOD NotifyOnHistoryReload(nsIURI *aReloadURI, uint32_t aReloadFlags, bool *_retval) override { return _to NotifyOnHistoryReload(aReloadURI, aReloadFlags, _retval); } \ |
212 | | NS_IMETHOD EvictOutOfRangeContentViewers(int32_t aIndex) override { return _to EvictOutOfRangeContentViewers(aIndex); } \ |
213 | | NS_IMETHOD EvictExpiredContentViewerForEntry(nsIBFCacheEntry *aEntry) override { return _to EvictExpiredContentViewerForEntry(aEntry); } \ |
214 | | NS_IMETHOD EvictAllContentViewers(void) override { return _to EvictAllContentViewers(); } \ |
215 | | NS_IMETHOD_(void) AddToExpirationTracker(nsIBFCacheEntry *aEntry) override { return _to AddToExpirationTracker(aEntry); } \ |
216 | | NS_IMETHOD_(void) RemoveFromExpirationTracker(nsIBFCacheEntry *aEntry) override { return _to RemoveFromExpirationTracker(aEntry); } \ |
217 | | NS_IMETHOD_(void) RemoveDynEntries(int32_t aIndex, nsISHEntry *aEntry) override { return _to RemoveDynEntries(aIndex, aEntry); } \ |
218 | | NS_IMETHOD_(void) RemoveDynEntriesForBFCacheEntry(nsIBFCacheEntry *aEntry) override { return _to RemoveDynEntriesForBFCacheEntry(aEntry); } \ |
219 | | NS_IMETHOD_(void) RemoveEntries(nsTArray<nsID> & aIDs, int32_t aStartIndex) override { return _to RemoveEntries(aIDs, aStartIndex); } |
220 | | |
221 | | /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */ |
222 | | #define NS_FORWARD_SAFE_NSISHISTORY(_to) \ |
223 | | NS_IMETHOD GetCount(int32_t *aCount) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCount(aCount); } \ |
224 | | NS_IMETHOD GetIndex(int32_t *aIndex) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIndex(aIndex); } \ |
225 | | NS_IMETHOD SetIndex(int32_t aIndex) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetIndex(aIndex); } \ |
226 | | NS_IMETHOD GetRequestedIndex(int32_t *aRequestedIndex) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetRequestedIndex(aRequestedIndex); } \ |
227 | | NS_IMETHOD GetEntryAtIndex(int32_t aIndex, nsISHEntry **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEntryAtIndex(aIndex, _retval); } \ |
228 | | NS_IMETHOD PurgeHistory(int32_t aNumEntries) override { return !_to ? NS_ERROR_NULL_POINTER : _to->PurgeHistory(aNumEntries); } \ |
229 | | NS_IMETHOD AddSHistoryListener(nsISHistoryListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->AddSHistoryListener(aListener); } \ |
230 | | NS_IMETHOD RemoveSHistoryListener(nsISHistoryListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveSHistoryListener(aListener); } \ |
231 | | NS_IMETHOD ReloadCurrentEntry(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ReloadCurrentEntry(); } \ |
232 | | NS_IMETHOD GotoIndex(int32_t aIndex) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GotoIndex(aIndex); } \ |
233 | | NS_IMETHOD_(int32_t) GetIndexOfEntry(nsISHEntry *aEntry) override; \ |
234 | | NS_IMETHOD AddEntry(nsISHEntry *aEntry, bool aPersist) override { return !_to ? NS_ERROR_NULL_POINTER : _to->AddEntry(aEntry, aPersist); } \ |
235 | | NS_IMETHOD_(void) SetRootDocShell(nsIDocShell *rootDocShell) override; \ |
236 | | NS_IMETHOD UpdateIndex(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->UpdateIndex(); } \ |
237 | | NS_IMETHOD ReplaceEntry(int32_t aIndex, nsISHEntry *aReplaceEntry) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ReplaceEntry(aIndex, aReplaceEntry); } \ |
238 | | NS_IMETHOD NotifyOnHistoryReload(nsIURI *aReloadURI, uint32_t aReloadFlags, bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->NotifyOnHistoryReload(aReloadURI, aReloadFlags, _retval); } \ |
239 | | NS_IMETHOD EvictOutOfRangeContentViewers(int32_t aIndex) override { return !_to ? NS_ERROR_NULL_POINTER : _to->EvictOutOfRangeContentViewers(aIndex); } \ |
240 | | NS_IMETHOD EvictExpiredContentViewerForEntry(nsIBFCacheEntry *aEntry) override { return !_to ? NS_ERROR_NULL_POINTER : _to->EvictExpiredContentViewerForEntry(aEntry); } \ |
241 | | NS_IMETHOD EvictAllContentViewers(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->EvictAllContentViewers(); } \ |
242 | | NS_IMETHOD_(void) AddToExpirationTracker(nsIBFCacheEntry *aEntry) override; \ |
243 | | NS_IMETHOD_(void) RemoveFromExpirationTracker(nsIBFCacheEntry *aEntry) override; \ |
244 | | NS_IMETHOD_(void) RemoveDynEntries(int32_t aIndex, nsISHEntry *aEntry) override; \ |
245 | | NS_IMETHOD_(void) RemoveDynEntriesForBFCacheEntry(nsIBFCacheEntry *aEntry) override; \ |
246 | | NS_IMETHOD_(void) RemoveEntries(nsTArray<nsID> & aIDs, int32_t aStartIndex) override; |
247 | | |
248 | | |
249 | | #endif /* __gen_nsISHistory_h__ */ |