2001-09-28 20:14:13 +00:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
1999-10-29 21:46:18 +00:00
|
|
|
|
1999-11-02 19:36:43 +00:00
|
|
|
#ifndef nsURILoader_h__
|
|
|
|
#define nsURILoader_h__
|
1999-10-29 21:46:18 +00:00
|
|
|
|
1999-11-02 19:36:43 +00:00
|
|
|
#include "nsCURILoader.h"
|
1999-11-05 06:01:05 +00:00
|
|
|
#include "nsISupportsUtils.h"
|
2002-12-11 00:15:19 +00:00
|
|
|
#include "nsCOMArray.h"
|
1999-10-29 21:46:18 +00:00
|
|
|
#include "nsCOMPtr.h"
|
2000-05-07 02:01:10 +00:00
|
|
|
#include "nsIInterfaceRequestor.h"
|
2001-09-05 21:28:38 +00:00
|
|
|
#include "nsIInterfaceRequestorUtils.h"
|
2000-10-19 10:25:49 +00:00
|
|
|
#include "nsString.h"
|
2002-12-11 00:15:19 +00:00
|
|
|
#include "nsIWeakReference.h"
|
2012-06-13 03:53:09 +00:00
|
|
|
#include "mozilla/Attributes.h"
|
1999-10-29 21:46:18 +00:00
|
|
|
|
2015-05-19 18:15:34 +00:00
|
|
|
#include "mozilla/Logging.h"
|
2003-10-30 02:03:41 +00:00
|
|
|
|
2003-10-09 04:00:01 +00:00
|
|
|
class nsDocumentOpenInfo;
|
|
|
|
|
2015-03-21 16:28:04 +00:00
|
|
|
class nsURILoader final : public nsIURILoader
|
1999-10-29 21:46:18 +00:00
|
|
|
{
|
|
|
|
public:
|
1999-11-02 19:36:43 +00:00
|
|
|
NS_DECL_NSIURILOADER
|
1999-10-29 21:46:18 +00:00
|
|
|
NS_DECL_ISUPPORTS
|
|
|
|
|
1999-11-02 19:36:43 +00:00
|
|
|
nsURILoader();
|
1999-10-29 21:46:18 +00:00
|
|
|
|
|
|
|
protected:
|
2014-06-23 18:49:09 +00:00
|
|
|
~nsURILoader();
|
|
|
|
|
2006-01-28 14:06:31 +00:00
|
|
|
/**
|
|
|
|
* Equivalent to nsIURILoader::openChannel, but allows specifying whether the
|
|
|
|
* channel is opened already.
|
|
|
|
*/
|
2016-08-08 10:16:15 +00:00
|
|
|
MOZ_MUST_USE nsresult OpenChannel(nsIChannel* channel,
|
|
|
|
uint32_t aFlags,
|
|
|
|
nsIInterfaceRequestor* aWindowContext,
|
|
|
|
bool aChannelOpen,
|
|
|
|
nsIStreamListener** aListener);
|
2006-01-28 14:06:31 +00:00
|
|
|
|
2004-04-16 21:06:07 +00:00
|
|
|
/**
|
|
|
|
* we shouldn't need to have an owning ref count on registered
|
|
|
|
* content listeners because they are supposed to unregister themselves
|
|
|
|
* when they go away. This array stores weak references
|
|
|
|
*/
|
2002-12-11 00:15:19 +00:00
|
|
|
nsCOMArray<nsIWeakReference> m_listeners;
|
1999-10-29 21:46:18 +00:00
|
|
|
|
2003-10-30 02:03:41 +00:00
|
|
|
/**
|
2016-01-30 00:30:00 +00:00
|
|
|
* Logging. The module is called "URILoader"
|
2003-10-30 02:03:41 +00:00
|
|
|
*/
|
2016-01-30 00:30:00 +00:00
|
|
|
static mozilla::LazyLogModule mLog;
|
2003-10-30 02:03:41 +00:00
|
|
|
|
2003-10-09 04:00:01 +00:00
|
|
|
friend class nsDocumentOpenInfo;
|
1999-10-29 21:46:18 +00:00
|
|
|
};
|
|
|
|
|
1999-11-02 19:36:43 +00:00
|
|
|
#endif /* nsURILoader_h__ */
|