DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Untracked file

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359
/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /home/jenkins/src/releases/comm-beta/mozilla/netwerk/cache2/nsICacheEntry.idl
 */

#ifndef __gen_nsICacheEntry_h__
#define __gen_nsICacheEntry_h__


#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif

#ifndef __gen_nsICache_h__
#include "nsICache.h"
#endif

#include "js/GCAnnotations.h"

/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIInputStream; /* forward declaration */

class nsIOutputStream; /* forward declaration */

class nsICacheEntryDoomCallback; /* forward declaration */

class nsICacheListener; /* forward declaration */

class nsIFile; /* forward declaration */

class nsICacheEntryMetaDataVisitor; /* forward declaration */

class nsILoadContextInfo; /* forward declaration */


/* starting interface:    nsICacheEntry */
#define NS_ICACHEENTRY_IID_STR "607c2a2c-0a48-40b9-a956-8cf2bb9857cf"

#define NS_ICACHEENTRY_IID \
  {0x607c2a2c, 0x0a48, 0x40b9, \
    { 0xa9, 0x56, 0x8c, 0xf2, 0xbb, 0x98, 0x57, 0xcf }}

class NS_NO_VTABLE nsICacheEntry : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_ICACHEENTRY_IID)

  enum {
    NO_EXPIRATION_TIME = 4294967295U
  };

  /* readonly attribute ACString key; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetKey(nsACString& aKey) = 0;

  /* readonly attribute uint64_t cacheEntryId; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetCacheEntryId(uint64_t *aCacheEntryId) = 0;

  /* readonly attribute boolean persistent; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetPersistent(bool *aPersistent) = 0;

  /* readonly attribute long fetchCount; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetFetchCount(int32_t *aFetchCount) = 0;

  /* readonly attribute uint32_t lastFetched; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetLastFetched(uint32_t *aLastFetched) = 0;

  /* readonly attribute uint32_t lastModified; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetLastModified(uint32_t *aLastModified) = 0;

  /* readonly attribute uint32_t expirationTime; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetExpirationTime(uint32_t *aExpirationTime) = 0;

  /* void setExpirationTime (in uint32_t expirationTime); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetExpirationTime(uint32_t expirationTime) = 0;

  /* readonly attribute uint64_t onStartTime; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetOnStartTime(uint64_t *aOnStartTime) = 0;

  /* readonly attribute uint64_t onStopTime; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetOnStopTime(uint64_t *aOnStopTime) = 0;

  /* void setNetworkTimes (in uint64_t onStartTime, in uint64_t onStopTime); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetNetworkTimes(uint64_t onStartTime, uint64_t onStopTime) = 0;

  /* void forceValidFor (in unsigned long aSecondsToTheFuture); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ForceValidFor(uint32_t aSecondsToTheFuture) = 0;

  /* readonly attribute boolean isForcedValid; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetIsForcedValid(bool *aIsForcedValid) = 0;

  /* nsIInputStream openInputStream (in long long offset); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OpenInputStream(int64_t offset, nsIInputStream **_retval) = 0;

  /* nsIOutputStream openOutputStream (in long long offset, in long long predictedSize); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OpenOutputStream(int64_t offset, int64_t predictedSize, nsIOutputStream **_retval) = 0;

  /* attribute nsISupports securityInfo; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetSecurityInfo(nsISupports **aSecurityInfo) = 0;
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetSecurityInfo(nsISupports *aSecurityInfo) = 0;

  /* readonly attribute unsigned long storageDataSize; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetStorageDataSize(uint32_t *aStorageDataSize) = 0;

  /* void asyncDoom (in nsICacheEntryDoomCallback listener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD AsyncDoom(nsICacheEntryDoomCallback *listener) = 0;

  /* string getMetaDataElement (in string key); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetMetaDataElement(const char * key, char * *_retval) = 0;

  /* void setMetaDataElement (in string key, in string value); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetMetaDataElement(const char * key, const char * value) = 0;

  /* void visitMetaData (in nsICacheEntryMetaDataVisitor visitor); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD VisitMetaData(nsICacheEntryMetaDataVisitor *visitor) = 0;

  /* void metaDataReady (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MetaDataReady(void) = 0;

  /* void setValid (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetValid(void) = 0;

  /* void dismiss (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Dismiss(void) = 0;

  /* readonly attribute uint32_t diskStorageSizeInKB; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetDiskStorageSizeInKB(uint32_t *aDiskStorageSizeInKB) = 0;

  /* nsICacheEntry recreate ([optional] in boolean aMemoryOnly); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Recreate(bool aMemoryOnly, nsICacheEntry **_retval) = 0;

  /* readonly attribute long long dataSize; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetDataSize(int64_t *aDataSize) = 0;

  /* readonly attribute long long altDataSize; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetAltDataSize(int64_t *aAltDataSize) = 0;

  /* nsIOutputStream openAlternativeOutputStream (in ACString type, in long long predictedSize); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OpenAlternativeOutputStream(const nsACString& type, int64_t predictedSize, nsIOutputStream **_retval) = 0;

  /* nsIInputStream openAlternativeInputStream (in ACString type); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OpenAlternativeInputStream(const nsACString& type, nsIInputStream **_retval) = 0;

  /* readonly attribute nsILoadContextInfo loadContextInfo; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetLoadContextInfo(nsILoadContextInfo **aLoadContextInfo) = 0;

  /* void close (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Close(void) = 0;

  /* void markValid (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MarkValid(void) = 0;

  /* void maybeMarkValid (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MaybeMarkValid(void) = 0;

  /* boolean hasWriteAccess (in boolean aWriteAllowed); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD HasWriteAccess(bool aWriteAllowed, bool *_retval) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsICacheEntry, NS_ICACHEENTRY_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSICACHEENTRY \
  NS_IMETHOD GetKey(nsACString& aKey) override; \
  NS_IMETHOD GetCacheEntryId(uint64_t *aCacheEntryId) override; \
  NS_IMETHOD GetPersistent(bool *aPersistent) override; \
  NS_IMETHOD GetFetchCount(int32_t *aFetchCount) override; \
  NS_IMETHOD GetLastFetched(uint32_t *aLastFetched) override; \
  NS_IMETHOD GetLastModified(uint32_t *aLastModified) override; \
  NS_IMETHOD GetExpirationTime(uint32_t *aExpirationTime) override; \
  NS_IMETHOD SetExpirationTime(uint32_t expirationTime) override; \
  NS_IMETHOD GetOnStartTime(uint64_t *aOnStartTime) override; \
  NS_IMETHOD GetOnStopTime(uint64_t *aOnStopTime) override; \
  NS_IMETHOD SetNetworkTimes(uint64_t onStartTime, uint64_t onStopTime) override; \
  NS_IMETHOD ForceValidFor(uint32_t aSecondsToTheFuture) override; \
  NS_IMETHOD GetIsForcedValid(bool *aIsForcedValid) override; \
  NS_IMETHOD OpenInputStream(int64_t offset, nsIInputStream **_retval) override; \
  NS_IMETHOD OpenOutputStream(int64_t offset, int64_t predictedSize, nsIOutputStream **_retval) override; \
  NS_IMETHOD GetSecurityInfo(nsISupports **aSecurityInfo) override; \
  NS_IMETHOD SetSecurityInfo(nsISupports *aSecurityInfo) override; \
  NS_IMETHOD GetStorageDataSize(uint32_t *aStorageDataSize) override; \
  NS_IMETHOD AsyncDoom(nsICacheEntryDoomCallback *listener) override; \
  NS_IMETHOD GetMetaDataElement(const char * key, char * *_retval) override; \
  NS_IMETHOD SetMetaDataElement(const char * key, const char * value) override; \
  NS_IMETHOD VisitMetaData(nsICacheEntryMetaDataVisitor *visitor) override; \
  NS_IMETHOD MetaDataReady(void) override; \
  NS_IMETHOD SetValid(void) override; \
  NS_IMETHOD Dismiss(void) override; \
  NS_IMETHOD GetDiskStorageSizeInKB(uint32_t *aDiskStorageSizeInKB) override; \
  NS_IMETHOD Recreate(bool aMemoryOnly, nsICacheEntry **_retval) override; \
  NS_IMETHOD GetDataSize(int64_t *aDataSize) override; \
  NS_IMETHOD GetAltDataSize(int64_t *aAltDataSize) override; \
  NS_IMETHOD OpenAlternativeOutputStream(const nsACString& type, int64_t predictedSize, nsIOutputStream **_retval) override; \
  NS_IMETHOD OpenAlternativeInputStream(const nsACString& type, nsIInputStream **_retval) override; \
  NS_IMETHOD GetLoadContextInfo(nsILoadContextInfo **aLoadContextInfo) override; \
  NS_IMETHOD Close(void) override; \
  NS_IMETHOD MarkValid(void) override; \
  NS_IMETHOD MaybeMarkValid(void) override; \
  NS_IMETHOD HasWriteAccess(bool aWriteAllowed, bool *_retval) override; 

/* Use this macro when declaring the members of this interface when the
   class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSICACHEENTRY \
  nsresult GetKey(nsACString& aKey); \
  nsresult GetCacheEntryId(uint64_t *aCacheEntryId); \
  nsresult GetPersistent(bool *aPersistent); \
  nsresult GetFetchCount(int32_t *aFetchCount); \
  nsresult GetLastFetched(uint32_t *aLastFetched); \
  nsresult GetLastModified(uint32_t *aLastModified); \
  nsresult GetExpirationTime(uint32_t *aExpirationTime); \
  nsresult SetExpirationTime(uint32_t expirationTime); \
  nsresult GetOnStartTime(uint64_t *aOnStartTime); \
  nsresult GetOnStopTime(uint64_t *aOnStopTime); \
  nsresult SetNetworkTimes(uint64_t onStartTime, uint64_t onStopTime); \
  nsresult ForceValidFor(uint32_t aSecondsToTheFuture); \
  nsresult GetIsForcedValid(bool *aIsForcedValid); \
  nsresult OpenInputStream(int64_t offset, nsIInputStream **_retval); \
  nsresult OpenOutputStream(int64_t offset, int64_t predictedSize, nsIOutputStream **_retval); \
  nsresult GetSecurityInfo(nsISupports **aSecurityInfo); \
  nsresult SetSecurityInfo(nsISupports *aSecurityInfo); \
  nsresult GetStorageDataSize(uint32_t *aStorageDataSize); \
  nsresult AsyncDoom(nsICacheEntryDoomCallback *listener); \
  nsresult GetMetaDataElement(const char * key, char * *_retval); \
  nsresult SetMetaDataElement(const char * key, const char * value); \
  nsresult VisitMetaData(nsICacheEntryMetaDataVisitor *visitor); \
  nsresult MetaDataReady(void); \
  nsresult SetValid(void); \
  nsresult Dismiss(void); \
  nsresult GetDiskStorageSizeInKB(uint32_t *aDiskStorageSizeInKB); \
  nsresult Recreate(bool aMemoryOnly, nsICacheEntry **_retval); \
  nsresult GetDataSize(int64_t *aDataSize); \
  nsresult GetAltDataSize(int64_t *aAltDataSize); \
  nsresult OpenAlternativeOutputStream(const nsACString& type, int64_t predictedSize, nsIOutputStream **_retval); \
  nsresult OpenAlternativeInputStream(const nsACString& type, nsIInputStream **_retval); \
  nsresult GetLoadContextInfo(nsILoadContextInfo **aLoadContextInfo); \
  nsresult Close(void); \
  nsresult MarkValid(void); \
  nsresult MaybeMarkValid(void); \
  nsresult HasWriteAccess(bool aWriteAllowed, bool *_retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSICACHEENTRY(_to) \
  NS_IMETHOD GetKey(nsACString& aKey) override { return _to GetKey(aKey); } \
  NS_IMETHOD GetCacheEntryId(uint64_t *aCacheEntryId) override { return _to GetCacheEntryId(aCacheEntryId); } \
  NS_IMETHOD GetPersistent(bool *aPersistent) override { return _to GetPersistent(aPersistent); } \
  NS_IMETHOD GetFetchCount(int32_t *aFetchCount) override { return _to GetFetchCount(aFetchCount); } \
  NS_IMETHOD GetLastFetched(uint32_t *aLastFetched) override { return _to GetLastFetched(aLastFetched); } \
  NS_IMETHOD GetLastModified(uint32_t *aLastModified) override { return _to GetLastModified(aLastModified); } \
  NS_IMETHOD GetExpirationTime(uint32_t *aExpirationTime) override { return _to GetExpirationTime(aExpirationTime); } \
  NS_IMETHOD SetExpirationTime(uint32_t expirationTime) override { return _to SetExpirationTime(expirationTime); } \
  NS_IMETHOD GetOnStartTime(uint64_t *aOnStartTime) override { return _to GetOnStartTime(aOnStartTime); } \
  NS_IMETHOD GetOnStopTime(uint64_t *aOnStopTime) override { return _to GetOnStopTime(aOnStopTime); } \
  NS_IMETHOD SetNetworkTimes(uint64_t onStartTime, uint64_t onStopTime) override { return _to SetNetworkTimes(onStartTime, onStopTime); } \
  NS_IMETHOD ForceValidFor(uint32_t aSecondsToTheFuture) override { return _to ForceValidFor(aSecondsToTheFuture); } \
  NS_IMETHOD GetIsForcedValid(bool *aIsForcedValid) override { return _to GetIsForcedValid(aIsForcedValid); } \
  NS_IMETHOD OpenInputStream(int64_t offset, nsIInputStream **_retval) override { return _to OpenInputStream(offset, _retval); } \
  NS_IMETHOD OpenOutputStream(int64_t offset, int64_t predictedSize, nsIOutputStream **_retval) override { return _to OpenOutputStream(offset, predictedSize, _retval); } \
  NS_IMETHOD GetSecurityInfo(nsISupports **aSecurityInfo) override { return _to GetSecurityInfo(aSecurityInfo); } \
  NS_IMETHOD SetSecurityInfo(nsISupports *aSecurityInfo) override { return _to SetSecurityInfo(aSecurityInfo); } \
  NS_IMETHOD GetStorageDataSize(uint32_t *aStorageDataSize) override { return _to GetStorageDataSize(aStorageDataSize); } \
  NS_IMETHOD AsyncDoom(nsICacheEntryDoomCallback *listener) override { return _to AsyncDoom(listener); } \
  NS_IMETHOD GetMetaDataElement(const char * key, char * *_retval) override { return _to GetMetaDataElement(key, _retval); } \
  NS_IMETHOD SetMetaDataElement(const char * key, const char * value) override { return _to SetMetaDataElement(key, value); } \
  NS_IMETHOD VisitMetaData(nsICacheEntryMetaDataVisitor *visitor) override { return _to VisitMetaData(visitor); } \
  NS_IMETHOD MetaDataReady(void) override { return _to MetaDataReady(); } \
  NS_IMETHOD SetValid(void) override { return _to SetValid(); } \
  NS_IMETHOD Dismiss(void) override { return _to Dismiss(); } \
  NS_IMETHOD GetDiskStorageSizeInKB(uint32_t *aDiskStorageSizeInKB) override { return _to GetDiskStorageSizeInKB(aDiskStorageSizeInKB); } \
  NS_IMETHOD Recreate(bool aMemoryOnly, nsICacheEntry **_retval) override { return _to Recreate(aMemoryOnly, _retval); } \
  NS_IMETHOD GetDataSize(int64_t *aDataSize) override { return _to GetDataSize(aDataSize); } \
  NS_IMETHOD GetAltDataSize(int64_t *aAltDataSize) override { return _to GetAltDataSize(aAltDataSize); } \
  NS_IMETHOD OpenAlternativeOutputStream(const nsACString& type, int64_t predictedSize, nsIOutputStream **_retval) override { return _to OpenAlternativeOutputStream(type, predictedSize, _retval); } \
  NS_IMETHOD OpenAlternativeInputStream(const nsACString& type, nsIInputStream **_retval) override { return _to OpenAlternativeInputStream(type, _retval); } \
  NS_IMETHOD GetLoadContextInfo(nsILoadContextInfo **aLoadContextInfo) override { return _to GetLoadContextInfo(aLoadContextInfo); } \
  NS_IMETHOD Close(void) override { return _to Close(); } \
  NS_IMETHOD MarkValid(void) override { return _to MarkValid(); } \
  NS_IMETHOD MaybeMarkValid(void) override { return _to MaybeMarkValid(); } \
  NS_IMETHOD HasWriteAccess(bool aWriteAllowed, bool *_retval) override { return _to HasWriteAccess(aWriteAllowed, _retval); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSICACHEENTRY(_to) \
  NS_IMETHOD GetKey(nsACString& aKey) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetKey(aKey); } \
  NS_IMETHOD GetCacheEntryId(uint64_t *aCacheEntryId) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCacheEntryId(aCacheEntryId); } \
  NS_IMETHOD GetPersistent(bool *aPersistent) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPersistent(aPersistent); } \
  NS_IMETHOD GetFetchCount(int32_t *aFetchCount) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFetchCount(aFetchCount); } \
  NS_IMETHOD GetLastFetched(uint32_t *aLastFetched) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastFetched(aLastFetched); } \
  NS_IMETHOD GetLastModified(uint32_t *aLastModified) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastModified(aLastModified); } \
  NS_IMETHOD GetExpirationTime(uint32_t *aExpirationTime) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetExpirationTime(aExpirationTime); } \
  NS_IMETHOD SetExpirationTime(uint32_t expirationTime) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetExpirationTime(expirationTime); } \
  NS_IMETHOD GetOnStartTime(uint64_t *aOnStartTime) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOnStartTime(aOnStartTime); } \
  NS_IMETHOD GetOnStopTime(uint64_t *aOnStopTime) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOnStopTime(aOnStopTime); } \
  NS_IMETHOD SetNetworkTimes(uint64_t onStartTime, uint64_t onStopTime) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetNetworkTimes(onStartTime, onStopTime); } \
  NS_IMETHOD ForceValidFor(uint32_t aSecondsToTheFuture) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ForceValidFor(aSecondsToTheFuture); } \
  NS_IMETHOD GetIsForcedValid(bool *aIsForcedValid) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIsForcedValid(aIsForcedValid); } \
  NS_IMETHOD OpenInputStream(int64_t offset, nsIInputStream **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenInputStream(offset, _retval); } \
  NS_IMETHOD OpenOutputStream(int64_t offset, int64_t predictedSize, nsIOutputStream **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenOutputStream(offset, predictedSize, _retval); } \
  NS_IMETHOD GetSecurityInfo(nsISupports **aSecurityInfo) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetSecurityInfo(aSecurityInfo); } \
  NS_IMETHOD SetSecurityInfo(nsISupports *aSecurityInfo) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetSecurityInfo(aSecurityInfo); } \
  NS_IMETHOD GetStorageDataSize(uint32_t *aStorageDataSize) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetStorageDataSize(aStorageDataSize); } \
  NS_IMETHOD AsyncDoom(nsICacheEntryDoomCallback *listener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->AsyncDoom(listener); } \
  NS_IMETHOD GetMetaDataElement(const char * key, char * *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetMetaDataElement(key, _retval); } \
  NS_IMETHOD SetMetaDataElement(const char * key, const char * value) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetMetaDataElement(key, value); } \
  NS_IMETHOD VisitMetaData(nsICacheEntryMetaDataVisitor *visitor) override { return !_to ? NS_ERROR_NULL_POINTER : _to->VisitMetaData(visitor); } \
  NS_IMETHOD MetaDataReady(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MetaDataReady(); } \
  NS_IMETHOD SetValid(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetValid(); } \
  NS_IMETHOD Dismiss(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Dismiss(); } \
  NS_IMETHOD GetDiskStorageSizeInKB(uint32_t *aDiskStorageSizeInKB) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDiskStorageSizeInKB(aDiskStorageSizeInKB); } \
  NS_IMETHOD Recreate(bool aMemoryOnly, nsICacheEntry **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Recreate(aMemoryOnly, _retval); } \
  NS_IMETHOD GetDataSize(int64_t *aDataSize) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDataSize(aDataSize); } \
  NS_IMETHOD GetAltDataSize(int64_t *aAltDataSize) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetAltDataSize(aAltDataSize); } \
  NS_IMETHOD OpenAlternativeOutputStream(const nsACString& type, int64_t predictedSize, nsIOutputStream **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenAlternativeOutputStream(type, predictedSize, _retval); } \
  NS_IMETHOD OpenAlternativeInputStream(const nsACString& type, nsIInputStream **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenAlternativeInputStream(type, _retval); } \
  NS_IMETHOD GetLoadContextInfo(nsILoadContextInfo **aLoadContextInfo) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLoadContextInfo(aLoadContextInfo); } \
  NS_IMETHOD Close(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Close(); } \
  NS_IMETHOD MarkValid(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MarkValid(); } \
  NS_IMETHOD MaybeMarkValid(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MaybeMarkValid(); } \
  NS_IMETHOD HasWriteAccess(bool aWriteAllowed, bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->HasWriteAccess(aWriteAllowed, _retval); } 


/* starting interface:    nsICacheEntryMetaDataVisitor */
#define NS_ICACHEENTRYMETADATAVISITOR_IID_STR "fea3e276-6ba5-4ceb-a581-807d1f43f6d0"

#define NS_ICACHEENTRYMETADATAVISITOR_IID \
  {0xfea3e276, 0x6ba5, 0x4ceb, \
    { 0xa5, 0x81, 0x80, 0x7d, 0x1f, 0x43, 0xf6, 0xd0 }}

class NS_NO_VTABLE nsICacheEntryMetaDataVisitor : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_ICACHEENTRYMETADATAVISITOR_IID)

  /* void onMetaDataElement (in string key, in string value); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OnMetaDataElement(const char * key, const char * value) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsICacheEntryMetaDataVisitor, NS_ICACHEENTRYMETADATAVISITOR_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSICACHEENTRYMETADATAVISITOR \
  NS_IMETHOD OnMetaDataElement(const char * key, const char * value) override; 

/* Use this macro when declaring the members of this interface when the
   class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSICACHEENTRYMETADATAVISITOR \
  nsresult OnMetaDataElement(const char * key, const char * value); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSICACHEENTRYMETADATAVISITOR(_to) \
  NS_IMETHOD OnMetaDataElement(const char * key, const char * value) override { return _to OnMetaDataElement(key, value); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSICACHEENTRYMETADATAVISITOR(_to) \
  NS_IMETHOD OnMetaDataElement(const char * key, const char * value) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OnMetaDataElement(key, value); } 


#endif /* __gen_nsICacheEntry_h__ */