LCOV - app.info - objdir/dist/include/nsIUnicharInputStream.h

LCOV - code coverage report
| Current view: | directory - objdir/dist/include - nsIUnicharInputStream.h (source / functions) |  | Found | Hit | Coverage |
| Test: | app.info | Lines: | 1 | 1 | 100.0 %
| Date: | 2012-04-21 | Functions: | 1 | 1 | 100.0 %

           1                 : /*
           2                 :  * DO NOT EDIT.  THIS FILE IS GENERATED FROM /builds/slave/m-aurora-lnx-codecoverage/build/xpcom/io/nsIUnicharInputStream.idl
           3                 :  */
           4                 :
           5                 : #ifndef __gen_nsIUnicharInputStream_h__
           6                 : #define __gen_nsIUnicharInputStream_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 nsIUnicharInputStream; /* forward declaration */
          18                 :
          19                 : class nsIInputStream; /* forward declaration */
          20                 :
          21                 : /**
          22                 :  * The signature of the writer function passed to ReadSegments. This
          23                 :  * is the "consumer" of data that gets read from the stream's buffer.
          24                 :  *
          25                 :  * @param aInStream stream being read
          26                 :  * @param aClosure opaque parameter passed to ReadSegments
          27                 :  * @param aFromSegment pointer to memory owned by the input stream
          28                 :  * @param aToOffset amount already read (since ReadSegments was called)
          29                 :  * @param aCount length of fromSegment
          30                 :  * @param aWriteCount number of bytes read
          31                 :  *
          32                 :  * Implementers should return the following:
          33                 :  *
          34                 :  * @return NS_OK and (*aWriteCount > 0) if consumed some data
          35                 :  * @return <any-error> if not interested in consuming any data
          36                 :  *
          37                 :  * Errors are never passed to the caller of ReadSegments.
          38                 :  *
          39                 :  * NOTE: returning NS_OK and (*aWriteCount = 0) has undefined behavior.
          40                 :  */
          41                 : typedef NS_CALLBACK(nsWriteUnicharSegmentFun)(nsIUnicharInputStream *aInStream,
          42                 :                                               void *aClosure,
          43                 :                                               const PRUnichar *aFromSegment,
          44                 :                                               PRUint32 aToOffset,
          45                 :                                               PRUint32 aCount,
          46                 :                                               PRUint32 *aWriteCount);
          47                 :
          48                 : /* starting interface:    nsIUnicharInputStream */
          49                 : #define NS_IUNICHARINPUTSTREAM_IID_STR "d5e3bd80-6723-4b92-b0c9-22f6162fd94f"
          50                 :
          51                 : #define NS_IUNICHARINPUTSTREAM_IID \
          52                 :   {0xd5e3bd80, 0x6723, 0x4b92, \
          53                 :     { 0xb0, 0xc9, 0x22, 0xf6, 0x16, 0x2f, 0xd9, 0x4f }}
          54                 :
          55            2738 : class NS_NO_VTABLE NS_SCRIPTABLE nsIUnicharInputStream : public nsISupports {
          56                 :  public:
          57                 :
          58                 :   NS_DECLARE_STATIC_IID_ACCESSOR(NS_IUNICHARINPUTSTREAM_IID)
          59                 :
          60                 :   /* [noscript] unsigned long read ([array, size_is (aCount)] in PRUnichar aBuf, in unsigned long aCount); */
          61                 :   NS_IMETHOD Read(PRUnichar *aBuf, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) = 0;
          62                 :
          63                 :   /* [noscript] unsigned long readSegments (in nsWriteUnicharSegmentFun aWriter, in voidPtr aClosure, in unsigned long aCount); */
          64                 :   NS_IMETHOD ReadSegments(nsWriteUnicharSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) = 0;
          65                 :
          66                 :   /* unsigned long readString (in unsigned long aCount, out AString aString); */
          67                 :   NS_SCRIPTABLE NS_IMETHOD ReadString(PRUint32 aCount, nsAString & aString NS_OUTPARAM, PRUint32 *_retval NS_OUTPARAM) = 0;
          68                 :
          69                 :   /* void close (); */
          70                 :   NS_SCRIPTABLE NS_IMETHOD Close(void) = 0;
          71                 :
          72                 : };
          73                 :
          74                 :   NS_DEFINE_STATIC_IID_ACCESSOR(nsIUnicharInputStream, NS_IUNICHARINPUTSTREAM_IID)
          75                 :
          76                 : /* Use this macro when declaring classes that implement this interface. */
          77                 : #define NS_DECL_NSIUNICHARINPUTSTREAM \
          78                 :   NS_IMETHOD Read(PRUnichar *aBuf, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM); \
          79                 :   NS_IMETHOD ReadSegments(nsWriteUnicharSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM); \
          80                 :   NS_SCRIPTABLE NS_IMETHOD ReadString(PRUint32 aCount, nsAString & aString NS_OUTPARAM, PRUint32 *_retval NS_OUTPARAM); \
          81                 :   NS_SCRIPTABLE NS_IMETHOD Close(void);
          82                 :
          83                 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
          84                 : #define NS_FORWARD_NSIUNICHARINPUTSTREAM(_to) \
          85                 :   NS_IMETHOD Read(PRUnichar *aBuf, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) { return _to Read(aBuf, aCount, _retval); } \
          86                 :   NS_IMETHOD ReadSegments(nsWriteUnicharSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) { return _to ReadSegments(aWriter, aClosure, aCount, _retval); } \
          87                 :   NS_SCRIPTABLE NS_IMETHOD ReadString(PRUint32 aCount, nsAString & aString NS_OUTPARAM, PRUint32 *_retval NS_OUTPARAM) { return _to ReadString(aCount, aString, _retval); } \
          88                 :   NS_SCRIPTABLE NS_IMETHOD Close(void) { return _to Close(); }
          89                 :
          90                 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
          91                 : #define NS_FORWARD_SAFE_NSIUNICHARINPUTSTREAM(_to) \
          92                 :   NS_IMETHOD Read(PRUnichar *aBuf, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Read(aBuf, aCount, _retval); } \
          93                 :   NS_IMETHOD ReadSegments(nsWriteUnicharSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->ReadSegments(aWriter, aClosure, aCount, _retval); } \
          94                 :   NS_SCRIPTABLE NS_IMETHOD ReadString(PRUint32 aCount, nsAString & aString NS_OUTPARAM, PRUint32 *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->ReadString(aCount, aString, _retval); } \
          95                 :   NS_SCRIPTABLE NS_IMETHOD Close(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->Close(); }
          96                 :
          97                 : #if 0
          98                 : /* Use the code below as a template for the implementation class for this interface. */
          99                 :
         100                 : /* Header file */
         101                 : class nsUnicharInputStream : public nsIUnicharInputStream
         102                 : {
         103                 : public:
         104                 :   NS_DECL_ISUPPORTS
         105                 :   NS_DECL_NSIUNICHARINPUTSTREAM
         106                 :
         107                 :   nsUnicharInputStream();
         108                 :
         109                 : private:
         110                 :   ~nsUnicharInputStream();
         111                 :
         112                 : protected:
         113                 :   /* additional members */
         114                 : };
         115                 :
         116                 : /* Implementation file */
         117                 : NS_IMPL_ISUPPORTS1(nsUnicharInputStream, nsIUnicharInputStream)
         118                 :
         119                 : nsUnicharInputStream::nsUnicharInputStream()
         120                 : {
         121                 :   /* member initializers and constructor code */
         122                 : }
         123                 :
         124                 : nsUnicharInputStream::~nsUnicharInputStream()
         125                 : {
         126                 :   /* destructor code */
         127                 : }
         128                 :
         129                 : /* [noscript] unsigned long read ([array, size_is (aCount)] in PRUnichar aBuf, in unsigned long aCount); */
         130                 : NS_IMETHODIMP nsUnicharInputStream::Read(PRUnichar *aBuf, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM)
         131                 : {
         132                 :     return NS_ERROR_NOT_IMPLEMENTED;
         133                 : }
         134                 :
         135                 : /* [noscript] unsigned long readSegments (in nsWriteUnicharSegmentFun aWriter, in voidPtr aClosure, in unsigned long aCount); */
         136                 : NS_IMETHODIMP nsUnicharInputStream::ReadSegments(nsWriteUnicharSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *_retval NS_OUTPARAM)
         137                 : {
         138                 :     return NS_ERROR_NOT_IMPLEMENTED;
         139                 : }
         140                 :
         141                 : /* unsigned long readString (in unsigned long aCount, out AString aString); */
         142                 : NS_IMETHODIMP nsUnicharInputStream::ReadString(PRUint32 aCount, nsAString & aString NS_OUTPARAM, PRUint32 *_retval NS_OUTPARAM)
         143                 : {
         144                 :     return NS_ERROR_NOT_IMPLEMENTED;
         145                 : }
         146                 :
         147                 : /* void close (); */
         148                 : NS_IMETHODIMP nsUnicharInputStream::Close()
         149                 : {
         150                 :     return NS_ERROR_NOT_IMPLEMENTED;
         151                 : }
         152                 :
         153                 : /* End of implementation class template. */
         154                 : #endif
         155                 :
         156                 :
         157                 : #endif /* __gen_nsIUnicharInputStream_h__ */

Generated by: LCOV version 1.7