Xalan-C++ API Reference  1.12.0
Public Types | Public Member Functions | List of all members
xalanc::XalanSourceTreeDocumentAllocator Class Reference

#include <xalanc/XSLT/XalanSourceTreeDocumentAllocator.hpp>

Public Types

enum  {
  eDefaultAttributeAllocatorBlockSize = XalanSourceTreeDocument::eDefaultAttributeAllocatorBlockSize, eDefaultAttributeNSAllocatorBlockSize = XalanSourceTreeDocument::eDefaultAttributeNSAllocatorBlockSize, eDefaultCommentAllocatorBlockSize = XalanSourceTreeDocument::eDefaultCommentAllocatorBlockSize, eDefaultElementAllocatorBlockSize = XalanSourceTreeDocument::eDefaultElementAllocatorBlockSize,
  eDefaultElementNSAllocatorBlockSize = XalanSourceTreeDocument::eDefaultElementNSAllocatorBlockSize, eDefaultPIAllocatorBlockSize = XalanSourceTreeDocument::eDefaultPIAllocatorBlockSize, eDefaultTextAllocatorBlockSize = XalanSourceTreeDocument::eDefaultTextAllocatorBlockSize, eDefaultTextIWSAllocatorBlockSize = XalanSourceTreeDocument::eDefaultTextIWSAllocatorBlockSize,
  eDefaultNamesStringPoolBlockSize = XalanSourceTreeDocument::eDefaultNamesStringPoolBlockSize, eDefaultNamesStringPoolBucketCount = XalanSourceTreeDocument::eDefaultNamesStringPoolBucketCount, eDefaultNamesStringPoolBucketSize = XalanSourceTreeDocument::eDefaultNamesStringPoolBucketSize, eDefaultValuesStringPoolBlockSize = XalanSourceTreeDocument::eDefaultValuesStringPoolBlockSize,
  eDefaultValuesStringPoolBucketCount = XalanSourceTreeDocument::eDefaultValuesStringPoolBucketCount, eDefaultValuesStringPoolBucketSize = XalanSourceTreeDocument::eDefaultValuesStringPoolBucketSize
}
 
typedef XalanSourceTreeDocument data_type
 
typedef ReusableArenaAllocator< data_typeArenaAllocatorType
 
typedef ArenaAllocatorType::size_type size_type
 
typedef XalanSourceTreeDocument::block_size_type block_size_type
 
typedef XalanSourceTreeDocument::bucket_count_type bucket_count_type
 
typedef XalanSourceTreeDocument::bucket_size_type bucket_size_type
 

Public Member Functions

 XalanSourceTreeDocumentAllocator (MemoryManager &theManager, size_type theBlockCount)
 Construct an instance that will allocate blocks of the specified size. More...
 
 ~XalanSourceTreeDocumentAllocator ()
 
data_typecreate (bool fPoolAllText=true, block_size_type theNamesStringPoolBlockSize=eDefaultNamesStringPoolBlockSize, bucket_count_type theNamesStringPoolBucketCount=eDefaultNamesStringPoolBucketCount, bucket_size_type theNamesStringPoolBucketSize=eDefaultNamesStringPoolBucketSize, block_size_type theValuesStringPoolBlockSize=eDefaultValuesStringPoolBlockSize, bucket_count_type theValuesStringPoolBucketCount=eDefaultValuesStringPoolBucketCount, bucket_size_type theValuesStringPoolBucketSize=eDefaultValuesStringPoolBucketSize)
 Create a XalanSourceTreeDocument object. More...
 
data_typecreate (size_type theAttributeBlockSize, size_type theAttributeNSBlockSize, size_type theCommentBlockSize, size_type theElementBlockSize, size_type theElementNSBlockSize, size_type thePIBlockSize, size_type theTextBlockSize, size_type theTextIWSBlockSize, bool fPoolAllText=true)
 Create a XalanSourceTreeDocument object. More...
 
bool destroy (data_type *theObject)
 Delete a XalanSourceTreeDocument object from allocator. More...
 
bool ownsObject (const data_type *theObject)
 Determine if an object is owned by the allocator... More...
 
void reset ()
 Delete all XalanSourceTreeDocument objects from allocator. More...
 
size_type getBlockCount () const
 Get the number of ArenaBlocks currently allocated. More...
 
size_type getBlockSize () const
 Get size of an ArenaBlock, that is, the number of objects in each block. More...
 

Detailed Description

Definition at line 41 of file XalanSourceTreeDocumentAllocator.hpp.

Member Typedef Documentation

◆ ArenaAllocatorType

Definition at line 47 of file XalanSourceTreeDocumentAllocator.hpp.

◆ block_size_type

Definition at line 65 of file XalanSourceTreeDocumentAllocator.hpp.

◆ bucket_count_type

Definition at line 66 of file XalanSourceTreeDocumentAllocator.hpp.

◆ bucket_size_type

Definition at line 67 of file XalanSourceTreeDocumentAllocator.hpp.

◆ data_type

Definition at line 45 of file XalanSourceTreeDocumentAllocator.hpp.

◆ size_type

Definition at line 48 of file XalanSourceTreeDocumentAllocator.hpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
eDefaultAttributeAllocatorBlockSize 
eDefaultAttributeNSAllocatorBlockSize 
eDefaultCommentAllocatorBlockSize 
eDefaultElementAllocatorBlockSize 
eDefaultElementNSAllocatorBlockSize 
eDefaultPIAllocatorBlockSize 
eDefaultTextAllocatorBlockSize 
eDefaultTextIWSAllocatorBlockSize 
eDefaultNamesStringPoolBlockSize 
eDefaultNamesStringPoolBucketCount 
eDefaultNamesStringPoolBucketSize 
eDefaultValuesStringPoolBlockSize 
eDefaultValuesStringPoolBucketCount 
eDefaultValuesStringPoolBucketSize 

Definition at line 50 of file XalanSourceTreeDocumentAllocator.hpp.

Constructor & Destructor Documentation

◆ XalanSourceTreeDocumentAllocator()

xalanc::XalanSourceTreeDocumentAllocator::XalanSourceTreeDocumentAllocator ( MemoryManager &  theManager,
size_type  theBlockCount 
)

Construct an instance that will allocate blocks of the specified size.

Parameters
theBlockSizeThe block size.

◆ ~XalanSourceTreeDocumentAllocator()

xalanc::XalanSourceTreeDocumentAllocator::~XalanSourceTreeDocumentAllocator ( )

Member Function Documentation

◆ create() [1/2]

data_type* xalanc::XalanSourceTreeDocumentAllocator::create ( bool  fPoolAllText = true,
block_size_type  theNamesStringPoolBlockSize = eDefaultNamesStringPoolBlockSize,
bucket_count_type  theNamesStringPoolBucketCount = eDefaultNamesStringPoolBucketCount,
bucket_size_type  theNamesStringPoolBucketSize = eDefaultNamesStringPoolBucketSize,
block_size_type  theValuesStringPoolBlockSize = eDefaultValuesStringPoolBlockSize,
bucket_count_type  theValuesStringPoolBucketCount = eDefaultValuesStringPoolBucketCount,
bucket_size_type  theValuesStringPoolBucketSize = eDefaultValuesStringPoolBucketSize 
)

Create a XalanSourceTreeDocument object.

Parameters
fPoolAllTextIf false, text node data that is not whitespace will not be pooled.
theNamesStringPoolBlockSizeThe block size for allocating strings in the name pool
theNamesStringPoolBucketCountThe number of buckets for allocating strings in the name pool
theNamesStringPoolBucketSizeThe bucket size for allocating strings in the name pool
theValuesStringPoolBlockSizeThe block size for allocating strings in the values pool
theValuesStringPoolBucketCountThe number of buckets for allocating strings in the values pool
theValuesStringPoolBucketSizeThe bucket size for allocating strings in the values pool
Returns
pointer to a node

◆ create() [2/2]

data_type* xalanc::XalanSourceTreeDocumentAllocator::create ( size_type  theAttributeBlockSize,
size_type  theAttributeNSBlockSize,
size_type  theCommentBlockSize,
size_type  theElementBlockSize,
size_type  theElementNSBlockSize,
size_type  thePIBlockSize,
size_type  theTextBlockSize,
size_type  theTextIWSBlockSize,
bool  fPoolAllText = true 
)

Create a XalanSourceTreeDocument object.

Parameters
fPoolAllTextIf false, text node data that is not whitespace will not be pooled.
theAttributeBlockSizeThe block size for allocating attribute nodes
theAttributeNSBlockSizeThe block size for allocating attribute NS nodes
theCommentBlockSizeThe block size for allocating comment nodes
theElementBlockSizeThe block size for allocating element nodes
theElementNSBlockSizeThe block size for allocating element nodes
theTextBlockSizeThe block size for allocating text nodes,
theTextIWSBlockSizeThe block size for allocating text IWS nodes,
Returns
pointer to a node

◆ destroy()

bool xalanc::XalanSourceTreeDocumentAllocator::destroy ( data_type theObject)

Delete a XalanSourceTreeDocument object from allocator.


◆ getBlockCount()

size_type xalanc::XalanSourceTreeDocumentAllocator::getBlockCount ( ) const
inline

Get the number of ArenaBlocks currently allocated.

Returns
The number of blocks.

Definition at line 154 of file XalanSourceTreeDocumentAllocator.hpp.

◆ getBlockSize()

size_type xalanc::XalanSourceTreeDocumentAllocator::getBlockSize ( ) const
inline

Get size of an ArenaBlock, that is, the number of objects in each block.

Returns
The size of the block

Definition at line 166 of file XalanSourceTreeDocumentAllocator.hpp.

◆ ownsObject()

bool xalanc::XalanSourceTreeDocumentAllocator::ownsObject ( const data_type theObject)
inline

Determine if an object is owned by the allocator...

Definition at line 137 of file XalanSourceTreeDocumentAllocator.hpp.

◆ reset()

void xalanc::XalanSourceTreeDocumentAllocator::reset ( )

Delete all XalanSourceTreeDocument objects from allocator.



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