Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: gecko-sdk/include/nsIRequestObserver.h

Issue 20346: Version 1.8 of gecko-sdk. Downloaded from here:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/
Patch Set: Created 11 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « gecko-sdk/include/nsIRequest.h ('k') | gecko-sdk/include/nsISHistory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
1 /*
2 * DO NOT EDIT. THIS FILE IS GENERATED FROM c:/builds/tinderbox/XR-Mozilla1.8.0 -Release/WINNT_5.2_Depend/mozilla/netwerk/base/public/nsIRequestObserver.idl
3 */
4
5 #ifndef __gen_nsIRequestObserver_h__
6 #define __gen_nsIRequestObserver_h__
7
8
9 #ifndef __gen_nsISupports_h__
10 #include "nsISupports.h"
11 #endif
12
13 /* For IDL files that don't want to include root IDL files. */
14 #ifndef NS_NO_VTABLE
15 #define NS_NO_VTABLE
16 #endif
17 class nsIRequest; /* forward declaration */
18
19
20 /* starting interface: nsIRequestObserver */
21 #define NS_IREQUESTOBSERVER_IID_STR "fd91e2e0-1481-11d3-9333-00104ba0fd40"
22
23 #define NS_IREQUESTOBSERVER_IID \
24 {0xfd91e2e0, 0x1481, 0x11d3, \
25 { 0x93, 0x33, 0x00, 0x10, 0x4b, 0xa0, 0xfd, 0x40 }}
26
27 /**
28 * nsIRequestObserver
29 *
30 * @status FROZEN
31 */
32 class NS_NO_VTABLE nsIRequestObserver : public nsISupports {
33 public:
34
35 NS_DEFINE_STATIC_IID_ACCESSOR(NS_IREQUESTOBSERVER_IID)
36
37 /**
38 * Called to signify the beginning of an asynchronous request.
39 *
40 * @param aRequest request being observed
41 * @param aContext user defined context
42 *
43 * An exception thrown from onStartRequest has the side-effect of
44 * causing the request to be canceled.
45 */
46 /* void onStartRequest (in nsIRequest aRequest, in nsISupports aContext); */
47 NS_IMETHOD OnStartRequest(nsIRequest *aRequest, nsISupports *aContext) = 0;
48
49 /**
50 * Called to signify the end of an asynchronous request. This
51 * call is always preceded by a call to onStartRequest.
52 *
53 * @param aRequest request being observed
54 * @param aContext user defined context
55 * @param aStatusCode reason for stopping (NS_OK if completed successfully)
56 *
57 * An exception thrown from onStopRequest is generally ignored.
58 */
59 /* void onStopRequest (in nsIRequest aRequest, in nsISupports aContext, in nsr esult aStatusCode); */
60 NS_IMETHOD OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode) = 0;
61
62 };
63
64 /* Use this macro when declaring classes that implement this interface. */
65 #define NS_DECL_NSIREQUESTOBSERVER \
66 NS_IMETHOD OnStartRequest(nsIRequest *aRequest, nsISupports *aContext); \
67 NS_IMETHOD OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode);
68
69 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object. */
70 #define NS_FORWARD_NSIREQUESTOBSERVER(_to) \
71 NS_IMETHOD OnStartRequest(nsIRequest *aRequest, nsISupports *aContext) { retur n _to OnStartRequest(aRequest, aContext); } \
72 NS_IMETHOD OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode) { return _to OnStopRequest(aRequest, aContext, aStatusCode); }
73
74 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object in a safe way. */
75 #define NS_FORWARD_SAFE_NSIREQUESTOBSERVER(_to) \
76 NS_IMETHOD OnStartRequest(nsIRequest *aRequest, nsISupports *aContext) { retur n !_to ? NS_ERROR_NULL_POINTER : _to->OnStartRequest(aRequest, aContext); } \
77 NS_IMETHOD OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode) { return !_to ? NS_ERROR_NULL_POINTER : _to->OnStopRequest(aReques t, aContext, aStatusCode); }
78
79 #if 0
80 /* Use the code below as a template for the implementation class for this interf ace. */
81
82 /* Header file */
83 class nsRequestObserver : public nsIRequestObserver
84 {
85 public:
86 NS_DECL_ISUPPORTS
87 NS_DECL_NSIREQUESTOBSERVER
88
89 nsRequestObserver();
90
91 private:
92 ~nsRequestObserver();
93
94 protected:
95 /* additional members */
96 };
97
98 /* Implementation file */
99 NS_IMPL_ISUPPORTS1(nsRequestObserver, nsIRequestObserver)
100
101 nsRequestObserver::nsRequestObserver()
102 {
103 /* member initializers and constructor code */
104 }
105
106 nsRequestObserver::~nsRequestObserver()
107 {
108 /* destructor code */
109 }
110
111 /* void onStartRequest (in nsIRequest aRequest, in nsISupports aContext); */
112 NS_IMETHODIMP nsRequestObserver::OnStartRequest(nsIRequest *aRequest, nsISupport s *aContext)
113 {
114 return NS_ERROR_NOT_IMPLEMENTED;
115 }
116
117 /* void onStopRequest (in nsIRequest aRequest, in nsISupports aContext, in nsres ult aStatusCode); */
118 NS_IMETHODIMP nsRequestObserver::OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode)
119 {
120 return NS_ERROR_NOT_IMPLEMENTED;
121 }
122
123 /* End of implementation class template. */
124 #endif
125
126
127 #endif /* __gen_nsIRequestObserver_h__ */
OLDNEW
« no previous file with comments | « gecko-sdk/include/nsIRequest.h ('k') | gecko-sdk/include/nsISHistory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698