ajindex


Data type AjPBtNode

Btree node

Attributes

NameTypeDescription
BlockOffsetajulongOffset within main index
NkeysajuintNumber of keys filled
TotLenajuintTotal length of keys
LeftajulongLeft Sibling
RightajulongRight Sibling
OverflowajulongOffset to overflow block
PrevNodeajulongPrevious node
NodeTypeajuintRoot, Internal or Leaf
Paddingchar[4]Padding to alignment boundary


Data type AjPBtMem

Dynamic list for btree memory arrays

Attributes

NameTypeDescription
nextstruct AjSBtMem*next node
prevstruct AjSBtMem*previous node
karrayAjPStr*key array (primary trees)
parrayajulong*pointer arrays (primary and secondary trees)
overflowsajulong*overflows (primary) and keys (secondary)
usedAjBoolnode in use
Paddingchar[4]Padding to alignment boundary


Data type AjPBtId

Btree ID

Attributes

NameTypeDescription
idAjPStrUnique ID
dbnoajuintDatabase file number
dupsajuintDuplicates
offsetajulongOffset within database file (ftello)
refoffsetajulongOffset within reference database file (ftello)


Data type AjPBtWild

Btree wildcard

Attributes

NameTypeDescription
idAjPStrWildcard ID
pageposajulongPage number of leaf
listAjPListlist of AjPBtIds
firstAjBooltrue for first search
Paddingchar[4]Padding to alignment boundary


Data type AjPBucket

Bucket structure on disc

Key, file number, ftell ID, subkey page (char*, ajuint, ajulong, ajulong)

Attributes

NameTypeDescription
NodeTypeajuintNode type
MaxentriesajuintNumber of entries available
NentriesajuintNumber of entries
OverflowajulongOffset to overflow block
keylenajuint*key lengths
IdsAjPBtId*Ids


Data type AjPBtNumId

Btree ID

Attributes

NameTypeDescription
offsetajulongOffset within database file (ftello)
refoffsetajulongOffset within reference database file (ftello)
dbnoajuintDatabase file number
Paddingchar[4]Padding to alignment boundary


Data type AjPNumBucket

Offset bucket structure on disc

Key, file number, ftell ID, subkey page (char*, ajuint, ajulong, ajulong)

Attributes

NameTypeDescription
NodeTypeajuintNode type
MaxentriesajuintNumber of entries available
NentriesajuintNumber of entries
OverflowajulongOffset to overflow block
NumIdAjPBtNumId*secondary tree IDs


Data type AjPBtpage

Btree page

Attributes

NameTypeDescription
pageposajulongPage number
nextstruct AjSBtpage*Next page
prevstruct AjSBtpage*Previous page
bufunsigned char*Buffer
dirtyajuintBT_DIRTY if page needs to be written to disc
lockforajuintReason for last setting of dirty as BT_LOCK


Data type AjPBtcache

B+ tree cache

Attributes

NameTypeDescription
fpFILE*Tree index file pointer
filenameAjPStrFilename
lruAjPBtpageLeast recently used cache page
mruAjPBtpageMost recently used cache page
bmemAjPBtMemPrimary array allocation MRU bottom
tmemAjPBtMemPrimary array allocation MRU top
bsmemAjPBtMemSecondary array allocation MRU bottom
tsmemAjPBtMemSecondary array allocation MRU top
replaceAjPStrReplacement ID
pagetableAjPTableTable of cached pages
totsizeajulongTree index total length
filesizeajulongTree index length after any compression
extendsizeajulongTree index extension block length
pagecountajulongTree index number of pages
secrootblockajulongSecondary tree root block
numreplaceajulongReplacement numeric ID
countuniqueajulongNumber of unique tokens indexed
countallajulongNumber of total tokens indexed
cachehitsajulongNumber of cached page reads
readsajulongNumber of physical reads from disk
writesajulongNumber of physical writes to disk
pagesizeajuintSize of cache pages
listLengthajuintNumber of pages in cache
orderajuintOrder of primary tree
levelajuintDepth of primary tree
cachesizeajuintMaximum number of pages to cache
nperbucketajuintNumber of entries in a primary bucket
slevelajuintDepth of secondary tree
sorderajuintOrder of secondary tree
snperbucketajuintNumber of entries in a secondary bucket
kwlimitajuintMax length of secondary key
secondaryAjBoolSecondary index
readonlyAjBoolRead only flag
deletedAjBoolDeletion flag
compressedAjBoolIndex is compressed


Data type AjPBtPri

Btree primary keyword

Attributes

NameTypeDescription
keywordAjPStrkeyword
treeblockajulongdisc block of secondary tree
idAjPStrId string


Data type AjPPriBucket

Keyword primary bucket structure on disc

Attributes

NameTypeDescription
NodeTypeajuintNode type
MaxentriesajuintNumber of entries available
NentriesajuintNumber of entries
OverflowajulongOffset to overflow block
keylenajuint*key lengths
codesAjPBtPri*Primary keywords


Data type AjPSecBucket

Keyword secondary bucket structure on disc

Attributes

NameTypeDescription
NodeTypeajuintNode type
MaxentriesajuintNumber of entries available
NentriesajuintNumber of entries
OverflowajulongOffset to overflow block
keylenajuint*key lengths
SecIdsAjPStr*Ids


Data type AjPBtKeyWild

Btree keyword wildcard object

Attributes

NameTypeDescription
keywordAjPStrWildcard keyword
pageposajulongPage number of primary tree leaf
listAjPListlist of AjPBtPris
cacheAjPBtcachecache for secondary tree
idlistAjPListlist of AjPStr IDs
secpageposajulongPage number of secondary tree leaf
firstAjBooltrue for first search
Paddingchar[4]Padding to alignment boundary


Data type AjPBtHybrid

Btree ID

Attributes

NameTypeDescription
key1AjPStrUnique ID
dbnoajuintDatabase file number
dupsajuintDuplicates
offsetajulongOffset within database file (ftello)
refoffsetajulongOffset within reference database file (ftello)
treeblockajulongSecondary tree root page