Line data Source code
1 : /*
2 : * DO NOT EDIT. THIS FILE IS GENERATED FROM ../../../dist/idl/nsICookie.idl
3 : */
4 :
5 : #ifndef __gen_nsICookie_h__
6 : #define __gen_nsICookie_h__
7 :
8 :
9 : #ifndef __gen_nsISupports_h__
10 : #include "nsISupports.h"
11 : #endif
12 :
13 : #include "js/Value.h"
14 :
15 : /* For IDL files that don't want to include root IDL files. */
16 : #ifndef NS_NO_VTABLE
17 : #define NS_NO_VTABLE
18 : #endif
19 : typedef int32_t nsCookieStatus;
20 :
21 : typedef int32_t nsCookiePolicy;
22 :
23 :
24 : /* starting interface: nsICookie */
25 : #define NS_ICOOKIE_IID_STR "adf0db5e-211e-45a3-be14-4486ac430a58"
26 :
27 : #define NS_ICOOKIE_IID \
28 : {0xadf0db5e, 0x211e, 0x45a3, \
29 : { 0xbe, 0x14, 0x44, 0x86, 0xac, 0x43, 0x0a, 0x58 }}
30 :
31 0 : class NS_NO_VTABLE nsICookie : public nsISupports {
32 : public:
33 :
34 : NS_DECLARE_STATIC_IID_ACCESSOR(NS_ICOOKIE_IID)
35 :
36 : /* readonly attribute ACString name; */
37 : NS_IMETHOD GetName(nsACString & aName) = 0;
38 :
39 : /* readonly attribute AUTF8String value; */
40 : NS_IMETHOD GetValue(nsACString & aValue) = 0;
41 :
42 : /* readonly attribute boolean isDomain; */
43 : NS_IMETHOD GetIsDomain(bool *aIsDomain) = 0;
44 :
45 : /* readonly attribute AUTF8String host; */
46 : NS_IMETHOD GetHost(nsACString & aHost) = 0;
47 :
48 : /* readonly attribute AUTF8String path; */
49 : NS_IMETHOD GetPath(nsACString & aPath) = 0;
50 :
51 : /* readonly attribute boolean isSecure; */
52 : NS_IMETHOD GetIsSecure(bool *aIsSecure) = 0;
53 :
54 : /* readonly attribute uint64_t expires; */
55 : NS_IMETHOD GetExpires(uint64_t *aExpires) = 0;
56 :
57 : enum {
58 : STATUS_UNKNOWN = 0,
59 : STATUS_ACCEPTED = 1,
60 : STATUS_DOWNGRADED = 2,
61 : STATUS_FLAGGED = 3,
62 : STATUS_REJECTED = 4
63 : };
64 :
65 : /* readonly attribute nsCookieStatus status; */
66 : NS_IMETHOD GetStatus(nsCookieStatus *aStatus) = 0;
67 :
68 : enum {
69 : POLICY_UNKNOWN = 0,
70 : POLICY_NONE = 1,
71 : POLICY_NO_CONSENT = 2,
72 : POLICY_IMPLICIT_CONSENT = 3,
73 : POLICY_EXPLICIT_CONSENT = 4,
74 : POLICY_NO_II = 5
75 : };
76 :
77 : /* readonly attribute nsCookiePolicy policy; */
78 : NS_IMETHOD GetPolicy(nsCookiePolicy *aPolicy) = 0;
79 :
80 : /* [implicit_jscontext] readonly attribute jsval originAttributes; */
81 : NS_IMETHOD GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes) = 0;
82 :
83 : };
84 :
85 : NS_DEFINE_STATIC_IID_ACCESSOR(nsICookie, NS_ICOOKIE_IID)
86 :
87 : /* Use this macro when declaring classes that implement this interface. */
88 : #define NS_DECL_NSICOOKIE \
89 : NS_IMETHOD GetName(nsACString & aName) override; \
90 : NS_IMETHOD GetValue(nsACString & aValue) override; \
91 : NS_IMETHOD GetIsDomain(bool *aIsDomain) override; \
92 : NS_IMETHOD GetHost(nsACString & aHost) override; \
93 : NS_IMETHOD GetPath(nsACString & aPath) override; \
94 : NS_IMETHOD GetIsSecure(bool *aIsSecure) override; \
95 : NS_IMETHOD GetExpires(uint64_t *aExpires) override; \
96 : NS_IMETHOD GetStatus(nsCookieStatus *aStatus) override; \
97 : NS_IMETHOD GetPolicy(nsCookiePolicy *aPolicy) override; \
98 : NS_IMETHOD GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes) override;
99 :
100 : /* Use this macro when declaring the members of this interface when the
101 : class doesn't implement the interface. This is useful for forwarding. */
102 : #define NS_DECL_NON_VIRTUAL_NSICOOKIE \
103 : nsresult GetName(nsACString & aName); \
104 : nsresult GetValue(nsACString & aValue); \
105 : nsresult GetIsDomain(bool *aIsDomain); \
106 : nsresult GetHost(nsACString & aHost); \
107 : nsresult GetPath(nsACString & aPath); \
108 : nsresult GetIsSecure(bool *aIsSecure); \
109 : nsresult GetExpires(uint64_t *aExpires); \
110 : nsresult GetStatus(nsCookieStatus *aStatus); \
111 : nsresult GetPolicy(nsCookiePolicy *aPolicy); \
112 : nsresult GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes);
113 :
114 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
115 : #define NS_FORWARD_NSICOOKIE(_to) \
116 : NS_IMETHOD GetName(nsACString & aName) override { return _to GetName(aName); } \
117 : NS_IMETHOD GetValue(nsACString & aValue) override { return _to GetValue(aValue); } \
118 : NS_IMETHOD GetIsDomain(bool *aIsDomain) override { return _to GetIsDomain(aIsDomain); } \
119 : NS_IMETHOD GetHost(nsACString & aHost) override { return _to GetHost(aHost); } \
120 : NS_IMETHOD GetPath(nsACString & aPath) override { return _to GetPath(aPath); } \
121 : NS_IMETHOD GetIsSecure(bool *aIsSecure) override { return _to GetIsSecure(aIsSecure); } \
122 : NS_IMETHOD GetExpires(uint64_t *aExpires) override { return _to GetExpires(aExpires); } \
123 : NS_IMETHOD GetStatus(nsCookieStatus *aStatus) override { return _to GetStatus(aStatus); } \
124 : NS_IMETHOD GetPolicy(nsCookiePolicy *aPolicy) override { return _to GetPolicy(aPolicy); } \
125 : NS_IMETHOD GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes) override { return _to GetOriginAttributes(cx, aOriginAttributes); }
126 :
127 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
128 : #define NS_FORWARD_SAFE_NSICOOKIE(_to) \
129 : NS_IMETHOD GetName(nsACString & aName) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetName(aName); } \
130 : NS_IMETHOD GetValue(nsACString & aValue) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetValue(aValue); } \
131 : NS_IMETHOD GetIsDomain(bool *aIsDomain) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIsDomain(aIsDomain); } \
132 : NS_IMETHOD GetHost(nsACString & aHost) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetHost(aHost); } \
133 : NS_IMETHOD GetPath(nsACString & aPath) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPath(aPath); } \
134 : NS_IMETHOD GetIsSecure(bool *aIsSecure) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIsSecure(aIsSecure); } \
135 : NS_IMETHOD GetExpires(uint64_t *aExpires) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetExpires(aExpires); } \
136 : NS_IMETHOD GetStatus(nsCookieStatus *aStatus) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetStatus(aStatus); } \
137 : NS_IMETHOD GetPolicy(nsCookiePolicy *aPolicy) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPolicy(aPolicy); } \
138 : NS_IMETHOD GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOriginAttributes(cx, aOriginAttributes); }
139 :
140 : #if 0
141 : /* Use the code below as a template for the implementation class for this interface. */
142 :
143 : /* Header file */
144 : class nsCookie : public nsICookie
145 : {
146 : public:
147 : NS_DECL_ISUPPORTS
148 : NS_DECL_NSICOOKIE
149 :
150 : nsCookie();
151 :
152 : private:
153 : ~nsCookie();
154 :
155 : protected:
156 : /* additional members */
157 : };
158 :
159 : /* Implementation file */
160 : NS_IMPL_ISUPPORTS(nsCookie, nsICookie)
161 :
162 : nsCookie::nsCookie()
163 : {
164 : /* member initializers and constructor code */
165 : }
166 :
167 : nsCookie::~nsCookie()
168 : {
169 : /* destructor code */
170 : }
171 :
172 : /* readonly attribute ACString name; */
173 : NS_IMETHODIMP nsCookie::GetName(nsACString & aName)
174 : {
175 : return NS_ERROR_NOT_IMPLEMENTED;
176 : }
177 :
178 : /* readonly attribute AUTF8String value; */
179 : NS_IMETHODIMP nsCookie::GetValue(nsACString & aValue)
180 : {
181 : return NS_ERROR_NOT_IMPLEMENTED;
182 : }
183 :
184 : /* readonly attribute boolean isDomain; */
185 : NS_IMETHODIMP nsCookie::GetIsDomain(bool *aIsDomain)
186 : {
187 : return NS_ERROR_NOT_IMPLEMENTED;
188 : }
189 :
190 : /* readonly attribute AUTF8String host; */
191 : NS_IMETHODIMP nsCookie::GetHost(nsACString & aHost)
192 : {
193 : return NS_ERROR_NOT_IMPLEMENTED;
194 : }
195 :
196 : /* readonly attribute AUTF8String path; */
197 : NS_IMETHODIMP nsCookie::GetPath(nsACString & aPath)
198 : {
199 : return NS_ERROR_NOT_IMPLEMENTED;
200 : }
201 :
202 : /* readonly attribute boolean isSecure; */
203 : NS_IMETHODIMP nsCookie::GetIsSecure(bool *aIsSecure)
204 : {
205 : return NS_ERROR_NOT_IMPLEMENTED;
206 : }
207 :
208 : /* readonly attribute uint64_t expires; */
209 : NS_IMETHODIMP nsCookie::GetExpires(uint64_t *aExpires)
210 : {
211 : return NS_ERROR_NOT_IMPLEMENTED;
212 : }
213 :
214 : /* readonly attribute nsCookieStatus status; */
215 : NS_IMETHODIMP nsCookie::GetStatus(nsCookieStatus *aStatus)
216 : {
217 : return NS_ERROR_NOT_IMPLEMENTED;
218 : }
219 :
220 : /* readonly attribute nsCookiePolicy policy; */
221 : NS_IMETHODIMP nsCookie::GetPolicy(nsCookiePolicy *aPolicy)
222 : {
223 : return NS_ERROR_NOT_IMPLEMENTED;
224 : }
225 :
226 : /* [implicit_jscontext] readonly attribute jsval originAttributes; */
227 : NS_IMETHODIMP nsCookie::GetOriginAttributes(JSContext* cx, JS::MutableHandleValue aOriginAttributes)
228 : {
229 : return NS_ERROR_NOT_IMPLEMENTED;
230 : }
231 :
232 : /* End of implementation class template. */
233 : #endif
234 :
235 :
236 : #endif /* __gen_nsICookie_h__ */
|