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

       1                 : /*
       2                 :  * DO NOT EDIT.  THIS FILE IS GENERATED FROM /builds/slave/m-beta-lnx-codecoverage/build/netwerk/base/public/nsITransport.idl
       3                 :  */
       4                 : 
       5                 : #ifndef __gen_nsITransport_h__
       6                 : #define __gen_nsITransport_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 nsIInputStream; /* forward declaration */
      18                 : 
      19                 : class nsIOutputStream; /* forward declaration */
      20                 : 
      21                 : class nsITransportEventSink; /* forward declaration */
      22                 : 
      23                 : class nsIEventTarget; /* forward declaration */
      24                 : 
      25                 : 
      26                 : /* starting interface:    nsITransport */
      27                 : #define NS_ITRANSPORT_IID_STR "d8786c64-eb49-4a0b-b42c-0936a745fbe8"
      28                 : 
      29                 : #define NS_ITRANSPORT_IID \
      30                 :   {0xd8786c64, 0xeb49, 0x4a0b, \
      31                 :     { 0xb4, 0x2c, 0x09, 0x36, 0xa7, 0x45, 0xfb, 0xe8 }}
      32                 : 
      33            6164 : class NS_NO_VTABLE NS_SCRIPTABLE nsITransport : public nsISupports {
      34                 :  public: 
      35                 : 
      36                 :   NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITRANSPORT_IID)
      37                 : 
      38                 :   enum {
      39                 :     OPEN_BLOCKING = 1U,
      40                 :     OPEN_UNBUFFERED = 2U
      41                 :   };
      42                 : 
      43                 :   /* nsIInputStream openInputStream (in unsigned long aFlags, in unsigned long aSegmentSize, in unsigned long aSegmentCount); */
      44                 :   NS_SCRIPTABLE NS_IMETHOD OpenInputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIInputStream * *_retval NS_OUTPARAM) = 0;
      45                 : 
      46                 :   /* nsIOutputStream openOutputStream (in unsigned long aFlags, in unsigned long aSegmentSize, in unsigned long aSegmentCount); */
      47                 :   NS_SCRIPTABLE NS_IMETHOD OpenOutputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIOutputStream * *_retval NS_OUTPARAM) = 0;
      48                 : 
      49                 :   /* void close (in nsresult aReason); */
      50                 :   NS_SCRIPTABLE NS_IMETHOD Close(nsresult aReason) = 0;
      51                 : 
      52                 :   /* void setEventSink (in nsITransportEventSink aSink, in nsIEventTarget aEventTarget); */
      53                 :   NS_SCRIPTABLE NS_IMETHOD SetEventSink(nsITransportEventSink *aSink, nsIEventTarget *aEventTarget) = 0;
      54                 : 
      55                 :   enum {
      56                 :     STATUS_READING = 2152398856U,
      57                 :     STATUS_WRITING = 2152398857U
      58                 :   };
      59                 : 
      60                 : };
      61                 : 
      62                 :   NS_DEFINE_STATIC_IID_ACCESSOR(nsITransport, NS_ITRANSPORT_IID)
      63                 : 
      64                 : /* Use this macro when declaring classes that implement this interface. */
      65                 : #define NS_DECL_NSITRANSPORT \
      66                 :   NS_SCRIPTABLE NS_IMETHOD OpenInputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIInputStream * *_retval NS_OUTPARAM); \
      67                 :   NS_SCRIPTABLE NS_IMETHOD OpenOutputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIOutputStream * *_retval NS_OUTPARAM); \
      68                 :   NS_SCRIPTABLE NS_IMETHOD Close(nsresult aReason); \
      69                 :   NS_SCRIPTABLE NS_IMETHOD SetEventSink(nsITransportEventSink *aSink, nsIEventTarget *aEventTarget); \
      70                 : 
      71                 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
      72                 : #define NS_FORWARD_NSITRANSPORT(_to) \
      73                 :   NS_SCRIPTABLE NS_IMETHOD OpenInputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIInputStream * *_retval NS_OUTPARAM) { return _to OpenInputStream(aFlags, aSegmentSize, aSegmentCount, _retval); } \
      74                 :   NS_SCRIPTABLE NS_IMETHOD OpenOutputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIOutputStream * *_retval NS_OUTPARAM) { return _to OpenOutputStream(aFlags, aSegmentSize, aSegmentCount, _retval); } \
      75                 :   NS_SCRIPTABLE NS_IMETHOD Close(nsresult aReason) { return _to Close(aReason); } \
      76                 :   NS_SCRIPTABLE NS_IMETHOD SetEventSink(nsITransportEventSink *aSink, nsIEventTarget *aEventTarget) { return _to SetEventSink(aSink, aEventTarget); } \
      77                 : 
      78                 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
      79                 : #define NS_FORWARD_SAFE_NSITRANSPORT(_to) \
      80                 :   NS_SCRIPTABLE NS_IMETHOD OpenInputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIInputStream * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenInputStream(aFlags, aSegmentSize, aSegmentCount, _retval); } \
      81                 :   NS_SCRIPTABLE NS_IMETHOD OpenOutputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIOutputStream * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->OpenOutputStream(aFlags, aSegmentSize, aSegmentCount, _retval); } \
      82                 :   NS_SCRIPTABLE NS_IMETHOD Close(nsresult aReason) { return !_to ? NS_ERROR_NULL_POINTER : _to->Close(aReason); } \
      83                 :   NS_SCRIPTABLE NS_IMETHOD SetEventSink(nsITransportEventSink *aSink, nsIEventTarget *aEventTarget) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetEventSink(aSink, aEventTarget); } \
      84                 : 
      85                 : #if 0
      86                 : /* Use the code below as a template for the implementation class for this interface. */
      87                 : 
      88                 : /* Header file */
      89                 : class nsTransport : public nsITransport
      90                 : {
      91                 : public:
      92                 :   NS_DECL_ISUPPORTS
      93                 :   NS_DECL_NSITRANSPORT
      94                 : 
      95                 :   nsTransport();
      96                 : 
      97                 : private:
      98                 :   ~nsTransport();
      99                 : 
     100                 : protected:
     101                 :   /* additional members */
     102                 : };
     103                 : 
     104                 : /* Implementation file */
     105                 : NS_IMPL_ISUPPORTS1(nsTransport, nsITransport)
     106                 : 
     107                 : nsTransport::nsTransport()
     108                 : {
     109                 :   /* member initializers and constructor code */
     110                 : }
     111                 : 
     112                 : nsTransport::~nsTransport()
     113                 : {
     114                 :   /* destructor code */
     115                 : }
     116                 : 
     117                 : /* nsIInputStream openInputStream (in unsigned long aFlags, in unsigned long aSegmentSize, in unsigned long aSegmentCount); */
     118                 : NS_IMETHODIMP nsTransport::OpenInputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIInputStream * *_retval NS_OUTPARAM)
     119                 : {
     120                 :     return NS_ERROR_NOT_IMPLEMENTED;
     121                 : }
     122                 : 
     123                 : /* nsIOutputStream openOutputStream (in unsigned long aFlags, in unsigned long aSegmentSize, in unsigned long aSegmentCount); */
     124                 : NS_IMETHODIMP nsTransport::OpenOutputStream(PRUint32 aFlags, PRUint32 aSegmentSize, PRUint32 aSegmentCount, nsIOutputStream * *_retval NS_OUTPARAM)
     125                 : {
     126                 :     return NS_ERROR_NOT_IMPLEMENTED;
     127                 : }
     128                 : 
     129                 : /* void close (in nsresult aReason); */
     130                 : NS_IMETHODIMP nsTransport::Close(nsresult aReason)
     131                 : {
     132                 :     return NS_ERROR_NOT_IMPLEMENTED;
     133                 : }
     134                 : 
     135                 : /* void setEventSink (in nsITransportEventSink aSink, in nsIEventTarget aEventTarget); */
     136                 : NS_IMETHODIMP nsTransport::SetEventSink(nsITransportEventSink *aSink, nsIEventTarget *aEventTarget)
     137                 : {
     138                 :     return NS_ERROR_NOT_IMPLEMENTED;
     139                 : }
     140                 : 
     141                 : /* End of implementation class template. */
     142                 : #endif
     143                 : 
     144                 : 
     145                 : /* starting interface:    nsITransportEventSink */
     146                 : #define NS_ITRANSPORTEVENTSINK_IID_STR "eda4f520-67f7-484b-a691-8c3226a5b0a6"
     147                 : 
     148                 : #define NS_ITRANSPORTEVENTSINK_IID \
     149                 :   {0xeda4f520, 0x67f7, 0x484b, \
     150                 :     { 0xa6, 0x91, 0x8c, 0x32, 0x26, 0xa5, 0xb0, 0xa6 }}
     151                 : 
     152           65924 : class NS_NO_VTABLE NS_SCRIPTABLE nsITransportEventSink : public nsISupports {
     153                 :  public: 
     154                 : 
     155                 :   NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITRANSPORTEVENTSINK_IID)
     156                 : 
     157                 :   /* void onTransportStatus (in nsITransport aTransport, in nsresult aStatus, in unsigned long long aProgress, in unsigned long long aProgressMax); */
     158                 :   NS_SCRIPTABLE NS_IMETHOD OnTransportStatus(nsITransport *aTransport, nsresult aStatus, PRUint64 aProgress, PRUint64 aProgressMax) = 0;
     159                 : 
     160                 : };
     161                 : 
     162                 :   NS_DEFINE_STATIC_IID_ACCESSOR(nsITransportEventSink, NS_ITRANSPORTEVENTSINK_IID)
     163                 : 
     164                 : /* Use this macro when declaring classes that implement this interface. */
     165                 : #define NS_DECL_NSITRANSPORTEVENTSINK \
     166                 :   NS_SCRIPTABLE NS_IMETHOD OnTransportStatus(nsITransport *aTransport, nsresult aStatus, PRUint64 aProgress, PRUint64 aProgressMax); 
     167                 : 
     168                 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
     169                 : #define NS_FORWARD_NSITRANSPORTEVENTSINK(_to) \
     170                 :   NS_SCRIPTABLE NS_IMETHOD OnTransportStatus(nsITransport *aTransport, nsresult aStatus, PRUint64 aProgress, PRUint64 aProgressMax) { return _to OnTransportStatus(aTransport, aStatus, aProgress, aProgressMax); } 
     171                 : 
     172                 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
     173                 : #define NS_FORWARD_SAFE_NSITRANSPORTEVENTSINK(_to) \
     174                 :   NS_SCRIPTABLE NS_IMETHOD OnTransportStatus(nsITransport *aTransport, nsresult aStatus, PRUint64 aProgress, PRUint64 aProgressMax) { return !_to ? NS_ERROR_NULL_POINTER : _to->OnTransportStatus(aTransport, aStatus, aProgress, aProgressMax); } 
     175                 : 
     176                 : #if 0
     177                 : /* Use the code below as a template for the implementation class for this interface. */
     178                 : 
     179                 : /* Header file */
     180                 : class nsTransportEventSink : public nsITransportEventSink
     181                 : {
     182                 : public:
     183                 :   NS_DECL_ISUPPORTS
     184                 :   NS_DECL_NSITRANSPORTEVENTSINK
     185                 : 
     186                 :   nsTransportEventSink();
     187                 : 
     188                 : private:
     189                 :   ~nsTransportEventSink();
     190                 : 
     191                 : protected:
     192                 :   /* additional members */
     193                 : };
     194                 : 
     195                 : /* Implementation file */
     196                 : NS_IMPL_ISUPPORTS1(nsTransportEventSink, nsITransportEventSink)
     197                 : 
     198                 : nsTransportEventSink::nsTransportEventSink()
     199                 : {
     200                 :   /* member initializers and constructor code */
     201                 : }
     202                 : 
     203                 : nsTransportEventSink::~nsTransportEventSink()
     204                 : {
     205                 :   /* destructor code */
     206                 : }
     207                 : 
     208                 : /* void onTransportStatus (in nsITransport aTransport, in nsresult aStatus, in unsigned long long aProgress, in unsigned long long aProgressMax); */
     209                 : NS_IMETHODIMP nsTransportEventSink::OnTransportStatus(nsITransport *aTransport, nsresult aStatus, PRUint64 aProgress, PRUint64 aProgressMax)
     210                 : {
     211                 :     return NS_ERROR_NOT_IMPLEMENTED;
     212                 : }
     213                 : 
     214                 : /* End of implementation class template. */
     215                 : #endif
     216                 : 
     217                 : 
     218                 : #endif /* __gen_nsITransport_h__ */

Generated by: LCOV version 1.7