LCOV - code coverage report
Current view: directory - objdir/dist/include - nsIWebSocketChannel.h (source / functions) Found Hit Coverage
Test: app.info Lines: 1 0 0.0 %
Date: 2012-06-02 Functions: 1 0 0.0 %

       1                 : /*
       2                 :  * DO NOT EDIT.  THIS FILE IS GENERATED FROM /builds/slave/m-beta-lnx-codecoverage/build/netwerk/protocol/websocket/nsIWebSocketChannel.idl
       3                 :  */
       4                 : 
       5                 : #ifndef __gen_nsIWebSocketChannel_h__
       6                 : #define __gen_nsIWebSocketChannel_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 nsIURI; /* forward declaration */
      18                 : 
      19                 : class nsIInterfaceRequestor; /* forward declaration */
      20                 : 
      21                 : class nsILoadGroup; /* forward declaration */
      22                 : 
      23                 : class nsIWebSocketListener; /* forward declaration */
      24                 : 
      25                 : class nsIInputStream; /* forward declaration */
      26                 : 
      27                 : 
      28                 : /* starting interface:    nsIWebSocketChannel */
      29                 : #define NS_IWEBSOCKETCHANNEL_IID_STR "ace34548-6dde-4570-b0b4-451aa6a877e0"
      30                 : 
      31                 : #define NS_IWEBSOCKETCHANNEL_IID \
      32                 :   {0xace34548, 0x6dde, 0x4570, \
      33                 :     { 0xb0, 0xb4, 0x45, 0x1a, 0xa6, 0xa8, 0x77, 0xe0 }}
      34                 : 
      35               0 : class NS_NO_VTABLE nsIWebSocketChannel : public nsISupports {
      36                 :  public: 
      37                 : 
      38                 :   NS_DECLARE_STATIC_IID_ACCESSOR(NS_IWEBSOCKETCHANNEL_IID)
      39                 : 
      40                 :   /* readonly attribute nsIURI originalURI; */
      41                 :   NS_IMETHOD GetOriginalURI(nsIURI * *aOriginalURI) = 0;
      42                 : 
      43                 :   /* readonly attribute nsIURI URI; */
      44                 :   NS_IMETHOD GetURI(nsIURI * *aURI) = 0;
      45                 : 
      46                 :   /* attribute nsIInterfaceRequestor notificationCallbacks; */
      47                 :   NS_IMETHOD GetNotificationCallbacks(nsIInterfaceRequestor * *aNotificationCallbacks) = 0;
      48                 :   NS_IMETHOD SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks) = 0;
      49                 : 
      50                 :   /* readonly attribute nsISupports securityInfo; */
      51                 :   NS_IMETHOD GetSecurityInfo(nsISupports * *aSecurityInfo) = 0;
      52                 : 
      53                 :   /* attribute nsILoadGroup loadGroup; */
      54                 :   NS_IMETHOD GetLoadGroup(nsILoadGroup * *aLoadGroup) = 0;
      55                 :   NS_IMETHOD SetLoadGroup(nsILoadGroup *aLoadGroup) = 0;
      56                 : 
      57                 :   /* attribute ACString protocol; */
      58                 :   NS_IMETHOD GetProtocol(nsACString & aProtocol) = 0;
      59                 :   NS_IMETHOD SetProtocol(const nsACString & aProtocol) = 0;
      60                 : 
      61                 :   /* readonly attribute ACString extensions; */
      62                 :   NS_IMETHOD GetExtensions(nsACString & aExtensions) = 0;
      63                 : 
      64                 :   /* void asyncOpen (in nsIURI aURI, in ACString aOrigin, in nsIWebSocketListener aListener, in nsISupports aContext); */
      65                 :   NS_IMETHOD AsyncOpen(nsIURI *aURI, const nsACString & aOrigin, nsIWebSocketListener *aListener, nsISupports *aContext) = 0;
      66                 : 
      67                 :   /* void close (in unsigned short aCode, in AUTF8String aReason); */
      68                 :   NS_IMETHOD Close(PRUint16 aCode, const nsACString & aReason) = 0;
      69                 : 
      70                 :   enum {
      71                 :     CLOSE_NORMAL = 1000U,
      72                 :     CLOSE_GOING_AWAY = 1001U,
      73                 :     CLOSE_PROTOCOL_ERROR = 1002U,
      74                 :     CLOSE_UNSUPPORTED_DATATYPE = 1003U,
      75                 :     CLOSE_NO_STATUS = 1005U,
      76                 :     CLOSE_ABNORMAL = 1006U,
      77                 :     CLOSE_INVALID_PAYLOAD = 1007U,
      78                 :     CLOSE_POLICY_VIOLATION = 1008U,
      79                 :     CLOSE_TOO_LARGE = 1009U,
      80                 :     CLOSE_EXTENSION_MISSING = 1010U,
      81                 :     CLOSE_INTERNAL_ERROR = 1001U
      82                 :   };
      83                 : 
      84                 :   /* void sendMsg (in AUTF8String aMsg); */
      85                 :   NS_IMETHOD SendMsg(const nsACString & aMsg) = 0;
      86                 : 
      87                 :   /* void sendBinaryMsg (in ACString aMsg); */
      88                 :   NS_IMETHOD SendBinaryMsg(const nsACString & aMsg) = 0;
      89                 : 
      90                 :   /* void sendBinaryStream (in nsIInputStream aStream, in unsigned long length); */
      91                 :   NS_IMETHOD SendBinaryStream(nsIInputStream *aStream, PRUint32 length) = 0;
      92                 : 
      93                 : };
      94                 : 
      95                 :   NS_DEFINE_STATIC_IID_ACCESSOR(nsIWebSocketChannel, NS_IWEBSOCKETCHANNEL_IID)
      96                 : 
      97                 : /* Use this macro when declaring classes that implement this interface. */
      98                 : #define NS_DECL_NSIWEBSOCKETCHANNEL \
      99                 :   NS_IMETHOD GetOriginalURI(nsIURI * *aOriginalURI); \
     100                 :   NS_IMETHOD GetURI(nsIURI * *aURI); \
     101                 :   NS_IMETHOD GetNotificationCallbacks(nsIInterfaceRequestor * *aNotificationCallbacks); \
     102                 :   NS_IMETHOD SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks); \
     103                 :   NS_IMETHOD GetSecurityInfo(nsISupports * *aSecurityInfo); \
     104                 :   NS_IMETHOD GetLoadGroup(nsILoadGroup * *aLoadGroup); \
     105                 :   NS_IMETHOD SetLoadGroup(nsILoadGroup *aLoadGroup); \
     106                 :   NS_IMETHOD GetProtocol(nsACString & aProtocol); \
     107                 :   NS_IMETHOD SetProtocol(const nsACString & aProtocol); \
     108                 :   NS_IMETHOD GetExtensions(nsACString & aExtensions); \
     109                 :   NS_IMETHOD AsyncOpen(nsIURI *aURI, const nsACString & aOrigin, nsIWebSocketListener *aListener, nsISupports *aContext); \
     110                 :   NS_IMETHOD Close(PRUint16 aCode, const nsACString & aReason); \
     111                 :   NS_IMETHOD SendMsg(const nsACString & aMsg); \
     112                 :   NS_IMETHOD SendBinaryMsg(const nsACString & aMsg); \
     113                 :   NS_IMETHOD SendBinaryStream(nsIInputStream *aStream, PRUint32 length); 
     114                 : 
     115                 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
     116                 : #define NS_FORWARD_NSIWEBSOCKETCHANNEL(_to) \
     117                 :   NS_IMETHOD GetOriginalURI(nsIURI * *aOriginalURI) { return _to GetOriginalURI(aOriginalURI); } \
     118                 :   NS_IMETHOD GetURI(nsIURI * *aURI) { return _to GetURI(aURI); } \
     119                 :   NS_IMETHOD GetNotificationCallbacks(nsIInterfaceRequestor * *aNotificationCallbacks) { return _to GetNotificationCallbacks(aNotificationCallbacks); } \
     120                 :   NS_IMETHOD SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks) { return _to SetNotificationCallbacks(aNotificationCallbacks); } \
     121                 :   NS_IMETHOD GetSecurityInfo(nsISupports * *aSecurityInfo) { return _to GetSecurityInfo(aSecurityInfo); } \
     122                 :   NS_IMETHOD GetLoadGroup(nsILoadGroup * *aLoadGroup) { return _to GetLoadGroup(aLoadGroup); } \
     123                 :   NS_IMETHOD SetLoadGroup(nsILoadGroup *aLoadGroup) { return _to SetLoadGroup(aLoadGroup); } \
     124                 :   NS_IMETHOD GetProtocol(nsACString & aProtocol) { return _to GetProtocol(aProtocol); } \
     125                 :   NS_IMETHOD SetProtocol(const nsACString & aProtocol) { return _to SetProtocol(aProtocol); } \
     126                 :   NS_IMETHOD GetExtensions(nsACString & aExtensions) { return _to GetExtensions(aExtensions); } \
     127                 :   NS_IMETHOD AsyncOpen(nsIURI *aURI, const nsACString & aOrigin, nsIWebSocketListener *aListener, nsISupports *aContext) { return _to AsyncOpen(aURI, aOrigin, aListener, aContext); } \
     128                 :   NS_IMETHOD Close(PRUint16 aCode, const nsACString & aReason) { return _to Close(aCode, aReason); } \
     129                 :   NS_IMETHOD SendMsg(const nsACString & aMsg) { return _to SendMsg(aMsg); } \
     130                 :   NS_IMETHOD SendBinaryMsg(const nsACString & aMsg) { return _to SendBinaryMsg(aMsg); } \
     131                 :   NS_IMETHOD SendBinaryStream(nsIInputStream *aStream, PRUint32 length) { return _to SendBinaryStream(aStream, length); } 
     132                 : 
     133                 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
     134                 : #define NS_FORWARD_SAFE_NSIWEBSOCKETCHANNEL(_to) \
     135                 :   NS_IMETHOD GetOriginalURI(nsIURI * *aOriginalURI) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOriginalURI(aOriginalURI); } \
     136                 :   NS_IMETHOD GetURI(nsIURI * *aURI) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetURI(aURI); } \
     137                 :   NS_IMETHOD GetNotificationCallbacks(nsIInterfaceRequestor * *aNotificationCallbacks) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNotificationCallbacks(aNotificationCallbacks); } \
     138                 :   NS_IMETHOD SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetNotificationCallbacks(aNotificationCallbacks); } \
     139                 :   NS_IMETHOD GetSecurityInfo(nsISupports * *aSecurityInfo) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetSecurityInfo(aSecurityInfo); } \
     140                 :   NS_IMETHOD GetLoadGroup(nsILoadGroup * *aLoadGroup) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLoadGroup(aLoadGroup); } \
     141                 :   NS_IMETHOD SetLoadGroup(nsILoadGroup *aLoadGroup) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLoadGroup(aLoadGroup); } \
     142                 :   NS_IMETHOD GetProtocol(nsACString & aProtocol) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetProtocol(aProtocol); } \
     143                 :   NS_IMETHOD SetProtocol(const nsACString & aProtocol) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetProtocol(aProtocol); } \
     144                 :   NS_IMETHOD GetExtensions(nsACString & aExtensions) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetExtensions(aExtensions); } \
     145                 :   NS_IMETHOD AsyncOpen(nsIURI *aURI, const nsACString & aOrigin, nsIWebSocketListener *aListener, nsISupports *aContext) { return !_to ? NS_ERROR_NULL_POINTER : _to->AsyncOpen(aURI, aOrigin, aListener, aContext); } \
     146                 :   NS_IMETHOD Close(PRUint16 aCode, const nsACString & aReason) { return !_to ? NS_ERROR_NULL_POINTER : _to->Close(aCode, aReason); } \
     147                 :   NS_IMETHOD SendMsg(const nsACString & aMsg) { return !_to ? NS_ERROR_NULL_POINTER : _to->SendMsg(aMsg); } \
     148                 :   NS_IMETHOD SendBinaryMsg(const nsACString & aMsg) { return !_to ? NS_ERROR_NULL_POINTER : _to->SendBinaryMsg(aMsg); } \
     149                 :   NS_IMETHOD SendBinaryStream(nsIInputStream *aStream, PRUint32 length) { return !_to ? NS_ERROR_NULL_POINTER : _to->SendBinaryStream(aStream, length); } 
     150                 : 
     151                 : #if 0
     152                 : /* Use the code below as a template for the implementation class for this interface. */
     153                 : 
     154                 : /* Header file */
     155                 : class nsWebSocketChannel : public nsIWebSocketChannel
     156                 : {
     157                 : public:
     158                 :   NS_DECL_ISUPPORTS
     159                 :   NS_DECL_NSIWEBSOCKETCHANNEL
     160                 : 
     161                 :   nsWebSocketChannel();
     162                 : 
     163                 : private:
     164                 :   ~nsWebSocketChannel();
     165                 : 
     166                 : protected:
     167                 :   /* additional members */
     168                 : };
     169                 : 
     170                 : /* Implementation file */
     171                 : NS_IMPL_ISUPPORTS1(nsWebSocketChannel, nsIWebSocketChannel)
     172                 : 
     173                 : nsWebSocketChannel::nsWebSocketChannel()
     174                 : {
     175                 :   /* member initializers and constructor code */
     176                 : }
     177                 : 
     178                 : nsWebSocketChannel::~nsWebSocketChannel()
     179                 : {
     180                 :   /* destructor code */
     181                 : }
     182                 : 
     183                 : /* readonly attribute nsIURI originalURI; */
     184                 : NS_IMETHODIMP nsWebSocketChannel::GetOriginalURI(nsIURI * *aOriginalURI)
     185                 : {
     186                 :     return NS_ERROR_NOT_IMPLEMENTED;
     187                 : }
     188                 : 
     189                 : /* readonly attribute nsIURI URI; */
     190                 : NS_IMETHODIMP nsWebSocketChannel::GetURI(nsIURI * *aURI)
     191                 : {
     192                 :     return NS_ERROR_NOT_IMPLEMENTED;
     193                 : }
     194                 : 
     195                 : /* attribute nsIInterfaceRequestor notificationCallbacks; */
     196                 : NS_IMETHODIMP nsWebSocketChannel::GetNotificationCallbacks(nsIInterfaceRequestor * *aNotificationCallbacks)
     197                 : {
     198                 :     return NS_ERROR_NOT_IMPLEMENTED;
     199                 : }
     200                 : NS_IMETHODIMP nsWebSocketChannel::SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks)
     201                 : {
     202                 :     return NS_ERROR_NOT_IMPLEMENTED;
     203                 : }
     204                 : 
     205                 : /* readonly attribute nsISupports securityInfo; */
     206                 : NS_IMETHODIMP nsWebSocketChannel::GetSecurityInfo(nsISupports * *aSecurityInfo)
     207                 : {
     208                 :     return NS_ERROR_NOT_IMPLEMENTED;
     209                 : }
     210                 : 
     211                 : /* attribute nsILoadGroup loadGroup; */
     212                 : NS_IMETHODIMP nsWebSocketChannel::GetLoadGroup(nsILoadGroup * *aLoadGroup)
     213                 : {
     214                 :     return NS_ERROR_NOT_IMPLEMENTED;
     215                 : }
     216                 : NS_IMETHODIMP nsWebSocketChannel::SetLoadGroup(nsILoadGroup *aLoadGroup)
     217                 : {
     218                 :     return NS_ERROR_NOT_IMPLEMENTED;
     219                 : }
     220                 : 
     221                 : /* attribute ACString protocol; */
     222                 : NS_IMETHODIMP nsWebSocketChannel::GetProtocol(nsACString & aProtocol)
     223                 : {
     224                 :     return NS_ERROR_NOT_IMPLEMENTED;
     225                 : }
     226                 : NS_IMETHODIMP nsWebSocketChannel::SetProtocol(const nsACString & aProtocol)
     227                 : {
     228                 :     return NS_ERROR_NOT_IMPLEMENTED;
     229                 : }
     230                 : 
     231                 : /* readonly attribute ACString extensions; */
     232                 : NS_IMETHODIMP nsWebSocketChannel::GetExtensions(nsACString & aExtensions)
     233                 : {
     234                 :     return NS_ERROR_NOT_IMPLEMENTED;
     235                 : }
     236                 : 
     237                 : /* void asyncOpen (in nsIURI aURI, in ACString aOrigin, in nsIWebSocketListener aListener, in nsISupports aContext); */
     238                 : NS_IMETHODIMP nsWebSocketChannel::AsyncOpen(nsIURI *aURI, const nsACString & aOrigin, nsIWebSocketListener *aListener, nsISupports *aContext)
     239                 : {
     240                 :     return NS_ERROR_NOT_IMPLEMENTED;
     241                 : }
     242                 : 
     243                 : /* void close (in unsigned short aCode, in AUTF8String aReason); */
     244                 : NS_IMETHODIMP nsWebSocketChannel::Close(PRUint16 aCode, const nsACString & aReason)
     245                 : {
     246                 :     return NS_ERROR_NOT_IMPLEMENTED;
     247                 : }
     248                 : 
     249                 : /* void sendMsg (in AUTF8String aMsg); */
     250                 : NS_IMETHODIMP nsWebSocketChannel::SendMsg(const nsACString & aMsg)
     251                 : {
     252                 :     return NS_ERROR_NOT_IMPLEMENTED;
     253                 : }
     254                 : 
     255                 : /* void sendBinaryMsg (in ACString aMsg); */
     256                 : NS_IMETHODIMP nsWebSocketChannel::SendBinaryMsg(const nsACString & aMsg)
     257                 : {
     258                 :     return NS_ERROR_NOT_IMPLEMENTED;
     259                 : }
     260                 : 
     261                 : /* void sendBinaryStream (in nsIInputStream aStream, in unsigned long length); */
     262                 : NS_IMETHODIMP nsWebSocketChannel::SendBinaryStream(nsIInputStream *aStream, PRUint32 length)
     263                 : {
     264                 :     return NS_ERROR_NOT_IMPLEMENTED;
     265                 : }
     266                 : 
     267                 : /* End of implementation class template. */
     268                 : #endif
     269                 : 
     270                 : 
     271                 : #endif /* __gen_nsIWebSocketChannel_h__ */

Generated by: LCOV version 1.7