1 module org.eclipse.swt.internal.mozilla.nsIProtocolHandler;
2 
3 import java.lang.all;
4 
5 import org.eclipse.swt.internal.mozilla.Common;
6 import org.eclipse.swt.internal.mozilla.nsISupports;
7 import org.eclipse.swt.internal.mozilla.nsID;
8 import org.eclipse.swt.internal.mozilla.nsIURI; 
9 import org.eclipse.swt.internal.mozilla.nsIChannel;
10 import org.eclipse.swt.internal.mozilla.nsStringAPI;
11 
12 const char[] NS_IPROTOCOLHANDLER_IID_STR = "15fd6940-8ea7-11d3-93ad-00104ba0fd40";
13 
14 const nsIID NS_IPROTOCOLHANDLER_IID= 
15   {0x15fd6940, 0x8ea7, 0x11d3, 
16     [ 0x93, 0xad, 0x00, 0x10, 0x4b, 0xa0, 0xfd, 0x40 ]};
17 
18 interface nsIProtocolHandler : nsISupports {
19 
20   static const char[] IID_STR = NS_IPROTOCOLHANDLER_IID_STR;
21   static const nsIID IID = NS_IPROTOCOLHANDLER_IID;
22 
23 extern(System):
24   nsresult GetScheme(nsACString * aScheme);
25   nsresult GetDefaultPort(PRInt32 *aDefaultPort);
26   nsresult GetProtocolFlags(PRUint32 *aProtocolFlags);
27   nsresult NewURI(nsACString * aSpec, char *aOriginCharset, nsIURI aBaseURI, nsIURI *_retval);
28   nsresult NewChannel(nsIURI aURI, nsIChannel *_retval);
29   nsresult AllowPort(PRInt32 port, char *scheme, PRBool *_retval);
30 
31   enum { URI_STD = 0U };
32   enum { URI_NORELATIVE = 1U };
33   enum { URI_NOAUTH = 2U };
34   enum { ALLOWS_PROXY = 4U };
35   enum { ALLOWS_PROXY_HTTP = 8U };
36 
37 }
38