/usr/include/firefox/nsIPipe.h is in firefox-dev 11.0+build1-0ubuntu4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 | /*
* DO NOT EDIT. THIS FILE IS GENERATED FROM /build/buildd/firefox-11.0+build1/build-tree/mozilla/xpcom/io/nsIPipe.idl
*/
#ifndef __gen_nsIPipe_h__
#define __gen_nsIPipe_h__
#ifndef __gen_nsIAsyncInputStream_h__
#include "nsIAsyncInputStream.h"
#endif
#ifndef __gen_nsIAsyncOutputStream_h__
#include "nsIAsyncOutputStream.h"
#endif
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIMemory; /* forward declaration */
/* starting interface: nsIPipe */
#define NS_IPIPE_IID_STR "f4211abc-61b3-11d4-9877-00c04fa0cf4a"
#define NS_IPIPE_IID \
{0xf4211abc, 0x61b3, 0x11d4, \
{ 0x98, 0x77, 0x00, 0xc0, 0x4f, 0xa0, 0xcf, 0x4a }}
class NS_NO_VTABLE NS_SCRIPTABLE nsIPipe : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IPIPE_IID)
/* void init (in boolean nonBlockingInput, in boolean nonBlockingOutput, in unsigned long segmentSize, in unsigned long segmentCount, in nsIMemory segmentAllocator); */
NS_SCRIPTABLE NS_IMETHOD Init(bool nonBlockingInput, bool nonBlockingOutput, PRUint32 segmentSize, PRUint32 segmentCount, nsIMemory *segmentAllocator) = 0;
/* readonly attribute nsIAsyncInputStream inputStream; */
NS_SCRIPTABLE NS_IMETHOD GetInputStream(nsIAsyncInputStream * *aInputStream) = 0;
/* readonly attribute nsIAsyncOutputStream outputStream; */
NS_SCRIPTABLE NS_IMETHOD GetOutputStream(nsIAsyncOutputStream * *aOutputStream) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIPipe, NS_IPIPE_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIPIPE \
NS_SCRIPTABLE NS_IMETHOD Init(bool nonBlockingInput, bool nonBlockingOutput, PRUint32 segmentSize, PRUint32 segmentCount, nsIMemory *segmentAllocator); \
NS_SCRIPTABLE NS_IMETHOD GetInputStream(nsIAsyncInputStream * *aInputStream); \
NS_SCRIPTABLE NS_IMETHOD GetOutputStream(nsIAsyncOutputStream * *aOutputStream);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIPIPE(_to) \
NS_SCRIPTABLE NS_IMETHOD Init(bool nonBlockingInput, bool nonBlockingOutput, PRUint32 segmentSize, PRUint32 segmentCount, nsIMemory *segmentAllocator) { return _to Init(nonBlockingInput, nonBlockingOutput, segmentSize, segmentCount, segmentAllocator); } \
NS_SCRIPTABLE NS_IMETHOD GetInputStream(nsIAsyncInputStream * *aInputStream) { return _to GetInputStream(aInputStream); } \
NS_SCRIPTABLE NS_IMETHOD GetOutputStream(nsIAsyncOutputStream * *aOutputStream) { return _to GetOutputStream(aOutputStream); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIPIPE(_to) \
NS_SCRIPTABLE NS_IMETHOD Init(bool nonBlockingInput, bool nonBlockingOutput, PRUint32 segmentSize, PRUint32 segmentCount, nsIMemory *segmentAllocator) { return !_to ? NS_ERROR_NULL_POINTER : _to->Init(nonBlockingInput, nonBlockingOutput, segmentSize, segmentCount, segmentAllocator); } \
NS_SCRIPTABLE NS_IMETHOD GetInputStream(nsIAsyncInputStream * *aInputStream) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetInputStream(aInputStream); } \
NS_SCRIPTABLE NS_IMETHOD GetOutputStream(nsIAsyncOutputStream * *aOutputStream) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOutputStream(aOutputStream); }
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsPipe : public nsIPipe
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSIPIPE
nsPipe();
private:
~nsPipe();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS1(nsPipe, nsIPipe)
nsPipe::nsPipe()
{
/* member initializers and constructor code */
}
nsPipe::~nsPipe()
{
/* destructor code */
}
/* void init (in boolean nonBlockingInput, in boolean nonBlockingOutput, in unsigned long segmentSize, in unsigned long segmentCount, in nsIMemory segmentAllocator); */
NS_IMETHODIMP nsPipe::Init(bool nonBlockingInput, bool nonBlockingOutput, PRUint32 segmentSize, PRUint32 segmentCount, nsIMemory *segmentAllocator)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* readonly attribute nsIAsyncInputStream inputStream; */
NS_IMETHODIMP nsPipe::GetInputStream(nsIAsyncInputStream * *aInputStream)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* readonly attribute nsIAsyncOutputStream outputStream; */
NS_IMETHODIMP nsPipe::GetOutputStream(nsIAsyncOutputStream * *aOutputStream)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
/* starting interface: nsISearchableInputStream */
#define NS_ISEARCHABLEINPUTSTREAM_IID_STR "8c39ef62-f7c9-11d4-98f5-001083010e9b"
#define NS_ISEARCHABLEINPUTSTREAM_IID \
{0x8c39ef62, 0xf7c9, 0x11d4, \
{ 0x98, 0xf5, 0x00, 0x10, 0x83, 0x01, 0x0e, 0x9b }}
class NS_NO_VTABLE NS_SCRIPTABLE nsISearchableInputStream : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_ISEARCHABLEINPUTSTREAM_IID)
/* void search (in string forString, in boolean ignoreCase, out boolean found, out unsigned long offsetSearchedTo); */
NS_SCRIPTABLE NS_IMETHOD Search(const char * forString, bool ignoreCase, bool *found NS_OUTPARAM, PRUint32 *offsetSearchedTo NS_OUTPARAM) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsISearchableInputStream, NS_ISEARCHABLEINPUTSTREAM_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSISEARCHABLEINPUTSTREAM \
NS_SCRIPTABLE NS_IMETHOD Search(const char * forString, bool ignoreCase, bool *found NS_OUTPARAM, PRUint32 *offsetSearchedTo NS_OUTPARAM);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSISEARCHABLEINPUTSTREAM(_to) \
NS_SCRIPTABLE NS_IMETHOD Search(const char * forString, bool ignoreCase, bool *found NS_OUTPARAM, PRUint32 *offsetSearchedTo NS_OUTPARAM) { return _to Search(forString, ignoreCase, found, offsetSearchedTo); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSISEARCHABLEINPUTSTREAM(_to) \
NS_SCRIPTABLE NS_IMETHOD Search(const char * forString, bool ignoreCase, bool *found NS_OUTPARAM, PRUint32 *offsetSearchedTo NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Search(forString, ignoreCase, found, offsetSearchedTo); }
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsSearchableInputStream : public nsISearchableInputStream
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSISEARCHABLEINPUTSTREAM
nsSearchableInputStream();
private:
~nsSearchableInputStream();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS1(nsSearchableInputStream, nsISearchableInputStream)
nsSearchableInputStream::nsSearchableInputStream()
{
/* member initializers and constructor code */
}
nsSearchableInputStream::~nsSearchableInputStream()
{
/* destructor code */
}
/* void search (in string forString, in boolean ignoreCase, out boolean found, out unsigned long offsetSearchedTo); */
NS_IMETHODIMP nsSearchableInputStream::Search(const char * forString, bool ignoreCase, bool *found NS_OUTPARAM, PRUint32 *offsetSearchedTo NS_OUTPARAM)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
/**
* NS_NewPipe2
*
* This function supersedes NS_NewPipe. It differs from NS_NewPipe in two
* major ways:
* (1) returns nsIAsyncInputStream and nsIAsyncOutputStream, so it is
* not necessary to QI in order to access these interfaces.
* (2) the size of the pipe is determined by the number of segments
* times the size of each segment.
*
* @param pipeIn
* resulting input end of the pipe
* @param pipeOut
* resulting output end of the pipe
* @param nonBlockingInput
* true specifies non-blocking input stream behavior
* @param nonBlockingOutput
* true specifies non-blocking output stream behavior
* @param segmentSize
* specifies the segment size in bytes (pass 0 to use default value)
* @param segmentCount
* specifies the max number of segments (pass 0 to use default value)
* passing PR_UINT32_MAX here causes the pipe to have "infinite" space.
* this mode can be useful in some cases, but should always be used with
* caution. the default value for this parameter is a finite value.
* @param segmentAlloc
* pass reference to nsIMemory to have all pipe allocations use this
* allocator (pass null to use the default allocator)
*/
extern nsresult
NS_NewPipe2(nsIAsyncInputStream **pipeIn,
nsIAsyncOutputStream **pipeOut,
bool nonBlockingInput = PR_FALSE,
bool nonBlockingOutput = PR_FALSE,
PRUint32 segmentSize = 0,
PRUint32 segmentCount = 0,
nsIMemory *segmentAlloc = nsnull);
/**
* NS_NewPipe
*
* Preserved for backwards compatibility. Plus, this interface is more
* amiable in certain contexts (e.g., when you don't need the pipe's async
* capabilities).
*
* @param pipeIn
* resulting input end of the pipe
* @param pipeOut
* resulting output end of the pipe
* @param segmentSize
* specifies the segment size in bytes (pass 0 to use default value)
* @param maxSize
* specifies the max size of the pipe (pass 0 to use default value)
* number of segments is maxSize / segmentSize, and maxSize must be a
* multiple of segmentSize. passing PR_UINT32_MAX here causes the
* pipe to have "infinite" space. this mode can be useful in some
* cases, but should always be used with caution. the default value
* for this parameter is a finite value.
* @param nonBlockingInput
* true specifies non-blocking input stream behavior
* @param nonBlockingOutput
* true specifies non-blocking output stream behavior
* @param segmentAlloc
* pass reference to nsIMemory to have all pipe allocations use this
* allocator (pass null to use the default allocator)
*/
extern nsresult
NS_NewPipe(nsIInputStream **pipeIn,
nsIOutputStream **pipeOut,
PRUint32 segmentSize = 0,
PRUint32 maxSize = 0,
bool nonBlockingInput = PR_FALSE,
bool nonBlockingOutput = PR_FALSE,
nsIMemory *segmentAlloc = nsnull);
#endif /* __gen_nsIPipe_h__ */
|