Name Description Size
Base64.cpp state->charsOnStack == 2 23018
Base64.h Converts |aBinary| to an unpadded, Base64 URL-encoded string per RFC 4648. Aims to encode the data in constant time. The caller retains ownership of |aBinary|. 3868
CocoaFileUtils.h 1829
CocoaFileUtils.mm 10408
components.conf 1701
crc32c.c Based on file found here: https://svnweb.freebsd.org/base/stable/10/sys/libkern/crc32.c?revision=256281 7268
crc32c.h 672
FileDescriptorFile.cpp 12193
FileDescriptorFile.h A limited implementation of nsIFile that wraps a FileDescriptor object allowing the file to be read from. Added to allow a child process to use an nsIFile object for a file it does not have access to on the filesystem but has been provided a FileDescriptor for from the parent. Many nsIFile methods are not implemented and this is not intended to be a general purpose file implementation. 1485
FilePreferences.cpp 10175
FilePreferences.h 1093
FileUtilsWin.cpp 3815
FileUtilsWin.h 5301
FixedBufferOutputStream.cpp 3932
FixedBufferOutputStream.h 2839
InputStreamLengthHelper.cpp static 7164
InputStreamLengthHelper.h 1671
InputStreamLengthWrapper.cpp static 10620
InputStreamLengthWrapper.h 3092
moz.build 4276
NonBlockingAsyncInputStream.cpp static 11650
NonBlockingAsyncInputStream.h 3044
nsAnonymousTemporaryFile.cpp 9289
nsAnonymousTemporaryFile.h OpenAnonymousTemporaryFile Creates and opens a temporary file which has a random name. Callers have no control over the file name, and the file is opened in a temporary location which is appropriate for the platform. Upon success, aOutFileDesc contains an opened handle to the temporary file. The caller is responsible for closing the file when they're finished with it. The file will be deleted when the file handle is closed. On non-Windows platforms the file will be unlinked before this function returns. On Windows the OS supplied delete-on-close mechanism is unreliable if the application crashes or the computer power cycles unexpectedly, so unopened temporary files are purged at some time after application startup. 1551
nsAppDirectoryServiceDefs.h 4462
nsAppFileLocationProvider.cpp 10573
nsAppFileLocationProvider.h // class nsAppFileLocationProvider //***************************************************************************** class nsAppFileLocationProvider final : public nsIDirectoryServiceProvider { public: nsAppFileLocationProvider(); NS_DECL_THREADSAFE_ISUPPORTS NS_DECL_NSIDIRECTORYSERVICEPROVIDER private: ~nsAppFileLocationProvider() = default; protected: nsresult CloneMozBinDirectory(nsIFile** aLocalFile); /** Get the product directory. This is a user-specific directory for storing application settings (e.g. the Application Data directory on windows systems). @param aLocal If true, should try to get a directory that is only stored locally (ie not transferred with roaming profiles) 1541
nsBinaryStream.cpp This file contains implementations of the nsIBinaryInputStream and nsIBinaryOutputStream interfaces. Together, these interfaces allows reading and writing of primitive data types (integers, floating-point values, booleans, etc.) to a stream in a binary, untagged, fixed-endianness format. This might be used, for example, to implement network protocols or to produce architecture-neutral binary disk files, i.e. ones that can be read and written by both big-endian and little-endian platforms. Output is written in big-endian order (high-order byte first), as this is traditional network order. @See nsIBinaryInputStream @See nsIBinaryOutputStream 27543
nsBinaryStream.h 86c37b9a-74e7-4672-844e-6e7dd83ba484 3037
nsDirectoryService.cpp 14891
nsDirectoryService.h 1781
nsDirectoryServiceDefs.h Defines the property names for directories available from nsIDirectoryService. These dirs are always available even if no nsIDirectoryServiceProviders have been registered with the service. Application level keys are defined in nsAppDirectoryServiceDefs.h. Keys whose definition ends in "DIR" or "FILE" return a single nsIFile (or subclass). Keys whose definition ends in "LIST" return an nsISimpleEnumerator which enumerates a list of file objects. Defines listed in this file are FROZEN. This list may grow. Each unique string in this file should have a corresponding atom defined in StaticAtoms.py (search for "DirectoryService"), regardless of whether it is defined here due to conditional compilation. 3526
nsDirectoryServiceUtils.h 932
nsEscape.cpp Bit 0 xalpha -- the alphas * Bit 1 xpalpha -- as xalpha but * converts spaces to plus and plus to %2B * Bit 3 ... path -- as xalphas but doesn't escape '/' * Bit 4 ... NSURL-ref -- extra encoding for Apple NSURL compatibility. * This encoding set is used on encoded URL ref * components before converting a URL to an NSURL * so we don't include '%' to avoid double encoding. 21353
nsEscape.h First checked in on 98/12/03 by John R. McMullen, derived from net.h/mkparse.c. 8671
nsIAsyncInputStream.idl If an input stream is non-blocking, it may return NS_BASE_STREAM_WOULD_BLOCK when read. The caller must then wait for the stream to have some data to read. If the stream implements nsIAsyncInputStream, then the caller can use this interface to request an asynchronous notification when the stream becomes readable or closed (via the AsyncWait method). While this interface is almost exclusively used with non-blocking streams, it is not necessary that nsIInputStream::isNonBlocking return true. Nor is it necessary that a non-blocking nsIInputStream implementation also implement nsIAsyncInputStream. 4981
nsIAsyncOutputStream.idl If an output stream is non-blocking, it may return NS_BASE_STREAM_WOULD_BLOCK when written to. The caller must then wait for the stream to become writable. If the stream implements nsIAsyncOutputStream, then the caller can use this interface to request an asynchronous notification when the stream becomes writable or closed (via the AsyncWait method). While this interface is almost exclusively used with non-blocking streams, it is not necessary that nsIOutputStream::isNonBlocking return true. Nor is it necessary that a non-blocking nsIOutputStream implementation also implement nsIAsyncOutputStream. 4923
nsIBinaryInputStream.idl This interface allows consumption of primitive data types from a "binary stream" containing untagged, big-endian binary data, i.e. as produced by an implementation of nsIBinaryOutputStream. This might be used, for example, to implement network protocols or to read from architecture-neutral disk files, i.e. ones that can be read and written by both big-endian and little-endian platforms. @See nsIBinaryOutputStream 3447
nsIBinaryOutputStream.idl This interface allows writing of primitive data types (integers, floating-point values, booleans, etc.) to a stream in a binary, untagged, fixed-endianness format. This might be used, for example, to implement network protocols or to produce architecture-neutral binary disk files, i.e. ones that can be read and written by both big-endian and little-endian platforms. Output is written in big-endian order (high-order byte first), as this is traditional network order. @See nsIBinaryInputStream 3138
nsICloneableInputStream.idl 1459
nsIConverterInputStream.idl A unichar input stream that wraps an input stream. This allows reading unicode strings from a stream, automatically converting the bytes from a selected character encoding. 1752
nsIConverterOutputStream.idl This interface allows writing strings to a stream, doing automatic character encoding conversion. 1134
nsIDirectoryEnumerator.idl This interface provides a means for enumerating the contents of a directory. It is similar to nsISimpleEnumerator except the retrieved entries are QI'ed to nsIFile, and there is a mechanism for closing the directory when the enumeration is complete. 1274
nsIDirectoryService.idl nsIDirectoryServiceProvider Used by Directory Service to get file locations. 2826
nsIFile.idl An nsIFile is an abstract representation of a filename. It manages filename encoding issues, pathname component separators ('/' vs. '\\' vs. ':') and weird stuff like differing volumes with identical names, as on pre-Darwin Macintoshes. This file has long introduced itself to new hackers with this opening paragraph: This is the only correct cross-platform way to specify a file. Strings are not such a way. If you grew up on windows or unix, you may think they are. Welcome to reality. While taking the pose struck here to heart would be uncalled for, one may safely conclude that writing cross-platform code is an embittering experience. All methods with string parameters have two forms. The preferred form operates on UCS-2 encoded characters strings. An alternate form operates on characters strings encoded in the "native" charset. A string containing characters encoded in the native charset cannot be safely passed to javascript via xpconnect. Therefore, the "native methods" are not scriptable. 21660
nsIInputStream.idl The signature of the writer function passed to ReadSegments. This is the "consumer" of data that gets read from the stream's buffer. @param aInStream stream being read @param aClosure opaque parameter passed to ReadSegments @param aFromSegment pointer to memory owned by the input stream. This is where the writer function should start consuming data. @param aToOffset amount of data already consumed by this writer during this ReadSegments call. This is also the sum of the aWriteCount returns from this writer over the previous invocations of the writer by this ReadSegments call. @param aCount Number of bytes available to be read starting at aFromSegment @param [out] aWriteCount number of bytes read by this writer function call Implementers should return the following: @return NS_OK and (*aWriteCount > 0) if consumed some data @return <any-error> if not interested in consuming any data Errors are never passed to the caller of ReadSegments. NOTE: returning NS_OK and (*aWriteCount = 0) has undefined behavior. 7739
nsIInputStreamLength.idl Note: Instead of using these interfaces directly, consider to use InputStreamLengthHelper class. 3241
nsIInputStreamPriority.idl An input stream implementing this interface will dispatch runnable events with this priority. See nsIRunnablePriority. 637
nsIInputStreamTee.idl A nsIInputStreamTee is a wrapper for an input stream, that when read reads the specified amount of data from its |source| and copies that data to its |sink|. |sink| must be a blocking output stream. 1509
nsIIOUtil.idl nsIIOUtil provdes various xpcom/io-related utility methods. 1212
nsILineInputStream.idl Read a single line from the stream, where a line is a possibly zero length sequence of 8bit chars terminated by a CR, LF, CRLF, LFCR, or eof. The line terminator is not returned. @retval false End of file. This line is the last line of the file (aLine is valid). @retval true The file contains further lines. @note Do not mix readLine with other read functions. Doing so can cause various problems and is not supported. 976
nsILocalFileMac.idl initWithCFURL Init this object with a CFURLRef NOTE: Supported only for XP_MACOSX NOTE: If the path of the CFURL is /a/b/c, at least a/b must exist beforehand. @param aCFURL the CoreFoundation URL 5958
nsILocalFileWin.idl initWithCommandLine Initialize this object based on the main app path of a commandline handler. @param aCommandLine the commandline to parse an app path out of. 3442
nsIMultiplexInputStream.idl The multiplex stream concatenates a list of input streams into a single stream. 1219
nsInputStreamTee.cpp 9549
nsIObjectInputStream.idl @see nsIObjectOutputStream @see nsIBinaryInputStream 1801
nsIObjectOutputStream.idl @See nsIObjectInputStream @See nsIBinaryOutputStream 3708
nsIOUtil.cpp 920
nsIOUtil.h nsIOUtil_h__ 864
nsIOutputStream.idl The signature for the reader function passed to WriteSegments. This is the "provider" of data that gets written into the stream's buffer. @param aOutStream stream being written to @param aClosure opaque parameter passed to WriteSegments @param aToSegment pointer to memory owned by the output stream @param aFromOffset amount already written (since WriteSegments was called) @param aCount length of toSegment @param aReadCount number of bytes written Implementers should return the following: @throws <any-error> if not interested in providing any data Errors are never passed to the caller of WriteSegments. 6965
nsIPipe.idl nsIPipe represents an in-process buffer that can be read using nsIInputStream and written using nsIOutputStream. The reader and writer of a pipe do not have to be on the same thread. As a result, the pipe is an ideal mechanism to bridge data exchange between two threads. For example, a worker thread might write data to a pipe from which the main thread will read. Each end of the pipe can be either blocking or non-blocking. Recall that a non-blocking stream will return NS_BASE_STREAM_WOULD_BLOCK if it cannot be read or written to without blocking the calling thread. For example, if you try to read from an empty pipe that has not yet been closed, then if that pipe's input end is non-blocking, then the read call will fail immediately with NS_BASE_STREAM_WOULD_BLOCK as the error condition. However, if that pipe's input end is blocking, then the read call will not return until the pipe has data or until the pipe is closed. This example presumes that the pipe is being filled asynchronously on some background thread. The pipe supports nsIAsyncInputStream and nsIAsyncOutputStream, which give the user of a non-blocking pipe the ability to wait for the pipe to become ready again. For example, in the case of an empty non-blocking pipe, the user can call AsyncWait on the input end of the pipe to be notified when the pipe has data to read (or when the pipe becomes closed). NS_NewPipe2 and NS_NewPipe provide convenient pipe constructors. In most cases nsIPipe is not actually used. It is usually enough to just get references to the pipe's input and output end. In which case, the pipe is automatically closed when the respective pipe ends are released. 7258
nsIRandomAccessStream.idl nsIRandomAccessStream An interface which supports both reading and writing to a storage starting at the current offset. Both the input stream and the output stream share the offset in the stream. Read operations invoked on the input stream start at the offset and advance it past the bytes read. Write operations invoked on the output stream start the offset and advance it past the bytes written. The offset can be set to an arbitrary value prior reading or writting. Each call to getInputStream or getOutputStream always returns the same object, rather than creating a new stream. It's recommended for objects implementing this interface to also implement nsIInputStream and nsIOutputStream, so they can be easilly used with e.g. NS_AsyncCopy. 2201
nsISafeOutputStream.idl This interface provides a mechanism to control an output stream that takes care not to overwrite an existing target until it is known that all writes to the destination succeeded. An object that supports this interface is intended to also support nsIOutputStream. For example, a file output stream that supports this interface writes to a temporary file, and moves it over the original file when |finish| is called only if the stream can be successfully closed and all writes succeeded. If |finish| is called but something went wrong during writing, it will delete the temporary file and not touch the original. If the stream is closed by calling |close| directly, or the stream goes away, the original file will not be overwritten, and the temporary file will be deleted. Currently, this interface is implemented only for file output streams. 1824
nsIScriptableBase64Encoder.idl nsIScriptableBase64Encoder efficiently encodes the contents of a nsIInputStream to a Base64 string. This avoids the need to read the entire stream into a buffer, and only then do the Base64 encoding. If you already have a buffer full of data, you should use btoa instead! 1279
nsIScriptableInputStream.idl nsIScriptableInputStream provides scriptable access to an nsIInputStream instance. 2153
nsISeekableStream.idl nsISeekableStream Note that a stream might not implement all methods (e.g., a readonly stream won't implement setEOF) 1974
nsIStorageStream.idl The nsIStorageStream interface maintains an internal data buffer that can be filled using a single output stream. One or more independent input streams can be created to read the data from the buffer non-destructively. 2543
nsIStreamBufferAccess.idl An interface for access to a buffering stream implementation's underlying memory buffer. Stream implementations that QueryInterface to nsIStreamBufferAccess must ensure that all buffers are aligned on the most restrictive type size for the current architecture (e.g., sizeof(double) for RISCy CPUs). malloc(3) satisfies this requirement. 3621
nsIStringStream.idl nsIStringInputStream Provides scriptable and specialized C++-only methods for initializing a nsIInputStream implementation with a simple character array. 3243
nsITellableStream.idl nsITellableStream This class is separate from nsISeekableStream in order to let streams to implement ::Tell() without implementing the whole nsISeekableStream interface. Callers can QI the stream to know what is implemented. This is mainly done for nsPipeInputStream. Implementing this interface, streams are able to expose the current offset via ::tell(). 1044
nsIUnicharInputStream.idl The signature of the writer function passed to ReadSegments. This is the "consumer" of data that gets read from the stream's buffer. @param aInStream stream being read @param aClosure opaque parameter passed to ReadSegments @param aFromSegment pointer to memory owned by the input stream @param aToOffset number of UTF-16 code units already read (since ReadSegments was called) @param aCount length of fromSegment @param aWriteCount number of UTF-16 code units read Implementers should return the following: @throws <any-error> if not interested in consuming any data Errors are never passed to the caller of ReadSegments. NOTE: returning NS_OK and (*aWriteCount = 0) has undefined behavior. 3876
nsIUnicharLineInputStream.idl Read a single line from the stream, where a line is a possibly zero length sequence of characters terminated by a CR, LF, CRLF, LFCR, or eof. The line terminator is not returned. @retval false End of file. This line is the last line of the file (aLine is valid). @retval true The file contains further lines. @note Do not mix readLine with other read functions. Doing so can cause various problems and is not supported. 982
nsIUnicharOutputStream.idl An interface that allows writing unicode data. 1403
nsLinebreakConverter.cpp ---------------------------------------------------------------------------- GetLinebreakString Could make this inline ---------------------------------------------------------------------------- 13411
nsLinebreakConverter.h ConvertLineBreaks Convert line breaks in the supplied string, allocating and returning a new buffer. Returns nullptr on failure. @param aSrc: the source string. if aSrcLen == kIgnoreLen this string is assumed to be null terminated, otherwise it must be at least aSrcLen long. @param aSrcBreaks: the line breaks in the source. If unknown, pass eLinebreakAny. If known, pass the known value, as this may be more efficient. @param aDestBreaks: the line breaks you want in the output. @param aSrcLen: length of the source. If -1, the source is assumed to be a null-terminated string. @param aOutLen: used to return character length of returned buffer, if not null. 6929
nsLocalFile.h Quota exceeded 4163
nsLocalFileCommon.cpp static 11752
nsLocalFileCommon.h 524
nsLocalFileUnix.cpp Implementation of nsIFile for "unixy" systems. 76128
nsLocalFileUnix.h Implementation of nsIFile for ``Unixy'' systems. 3043
nsLocalFileWin.cpp 106696
nsLocalFileWin.h 3697
nsMultiplexInputStream.cpp The multiplex stream concatenates a list of input streams into a single stream. 46131
nsMultiplexInputStream.h The multiplex stream concatenates a list of input streams into a single stream. 1035
nsNativeCharsetUtils.cpp 2808
nsNativeCharsetUtils.h \ * **** NOTICE **** * * *** THESE ARE NOT GENERAL PURPOSE CONVERTERS *** * * NS_CopyNativeToUnicode / NS_CopyUnicodeToNative should only be used * for converting *FILENAMES* between bytes and UTF-16. They are not * designed or tested for general encoding converter use. * * On Windows, these functions convert to and from the system's legacy * code page, which cannot represent all of Unicode. Elsewhere, these * convert to and from UTF-8. * * \**************************************************************************** 2490
nsPipe.h e4a0ee4e-0775-457b-9118-b3ae97a7c758 837
nsPipe3.cpp 61726
nsScriptableBase64Encoder.cpp 1036
nsScriptableBase64Encoder.h 1053
nsScriptableInputStream.cpp 2927
nsScriptableInputStream.h 1418
nsSegmentedBuffer.cpp 5498
nsSegmentedBuffer.h 3802
nsStorageStream.cpp The storage stream provides an internal buffer that can be filled by a client using a single output stream. One or more independent input streams can be created to read the data out non-destructively. The implementation uses a segmented buffer internally to avoid realloc'ing of large buffers, with the attendant performance loss and heap fragmentation. 19502
nsStorageStream.h The storage stream provides an internal buffer that can be filled by a client using a single output stream. One or more independent input streams can be created to read the data out non-destructively. The implementation uses a segmented buffer internally to avoid realloc'ing of large buffers, with the attendant performance loss and heap fragmentation. 2995
nsStreamUtils.cpp 30979
nsStreamUtils.h A "one-shot" proxy of the OnInputStreamReady callback. The resulting proxy object's OnInputStreamReady function may only be called once! The proxy object ensures that the real notify object will be free'd on the thread corresponding to the given event target regardless of what thread the proxy object is destroyed on. This function is designed to be used to implement AsyncWait when the aTarget parameter is non-null. The optional aPriority parameter allows the input stream runnable events to be dispatched with a different priority than normal. 14815
nsStringStream.cpp Based on original code from nsIStringStream.cpp 15835
nsStringStream.h Implements: nsIStringInputStream nsIInputStream nsISeekableStream nsITellableStream nsISupportsCString 3489
nsUnicharInputStream.cpp 3444
nsUnicharInputStream.h 600
nsWildCard.cpp nsWildCard.cpp: shell-like wildcard match routines See nsIZipReader.findEntries documentation in nsIZipReader.idl for a description of the syntax supported by the routines in this file. Rob McCool 12523
nsWildCard.h nsWildCard.h: Defines and prototypes for shell exp. match routines See nsIZipReader.findEntries docs in nsIZipReader.idl for a description of the supported expression syntax. Note that the syntax documentation explicitly says the results of certain expressions are undefined. This is intentional to require less robustness in the code. Regular expression parsing is hard; the smaller the set of features and interactions this code must support, the easier it is to ensure it works. 1871
SlicedInputStream.cpp 18596
SlicedInputStream.h 3771
SnappyCompressOutputStream.cpp 6962
SnappyCompressOutputStream.h 2325
SnappyFrameUtils.cpp 7713
SnappyFrameUtils.h 2807
SnappyUncompressInputStream.cpp 11887
SnappyUncompressInputStream.h 3363
SpecialSystemDirectory.cpp Return the default save-to location for the Windows Library passed in through aFolderId. 19347
SpecialSystemDirectory.h 1786
StreamBufferSink.h 782
StreamBufferSinkImpl.h 1377
StreamBufferSource.h 1728
StreamBufferSourceImpl.h 2252