Logo Search packages:      
Sourcecode: xulrunner version File versions  Download package

nsVoidArray Class Reference

#include <nsVoidArray.h>

Inherited by nsAutoVoidArray, nsCStringArray [private], nsSmallVoidArray [private], nsStringArray [private], txStack [private], and txUint32Array.

List of all members.

Detailed Description

A basic zero-based array of void*'s that manages its own memory.

Definition at line 54 of file nsVoidArray.h.

Public Member Functions

PRBool AppendElement (void *aElement)
PRBool AppendElements (nsVoidArray &aElements)
void Clear ()
void Compact ()
PRInt32 Count () const
void * ElementAt (PRInt32 aIndex) const
PRBool EnumerateBackwards (nsVoidArrayEnumFunc aFunc, void *aData)
PRBool EnumerateForwards (nsVoidArrayEnumFunc aFunc, void *aData)
void * FastElementAt (PRInt32 aIndex) const
PRInt32 GetArraySize () const
PRInt32 IndexOf (void *aPossibleElement) const
PRBool InsertElementAt (void *aElement, PRInt32 aIndex)
PRBool InsertElementsAt (const nsVoidArray &other, PRInt32 aIndex)
PRBool MoveElement (PRInt32 aFrom, PRInt32 aTo)
 nsVoidArray (PRInt32 aCount)
nsVoidArrayoperator= (const nsVoidArray &other)
void * operator[] (PRInt32 aIndex) const
PRBool RemoveElement (void *aElement)
PRBool RemoveElementAt (PRInt32 aIndex)
PRBool RemoveElementsAt (PRInt32 aIndex, PRInt32 aCount)
PRBool ReplaceElementAt (void *aElement, PRInt32 aIndex)
void * SafeElementAt (PRInt32 aIndex) const
PRBool SizeTo (PRInt32 aMin)
void Sort (nsVoidArrayComparatorFunc aFunc, void *aData)

Protected Types

enum  { kArrayOwnerMask = 1 << 31, kArrayHasAutoBufferMask = 1 << 30, kArraySizeMask = ~(kArrayOwnerMask | kArrayHasAutoBufferMask) }
enum  { kAutoBufSize = 8 }

Protected Member Functions

PRBool GrowArrayBy (PRInt32 aGrowBy)
PRBool HasAutoBuffer () const
PRBool IsArrayOwner () const
void SetArray (Impl *newImpl, PRInt32 aSize, PRInt32 aCount, PRBool aOwner, PRBool aHasAuto)

Protected Attributes

Impl * mImpl

Private Member Functions

 nsVoidArray (const nsVoidArray &other)
 Copy constructors are not allowed.


struct  Impl

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index