| class ThspsDomStringPoolOptimizer |
Optimizer module for ChspsDomStringPool .
| Public Member Functions | |
|---|---|
| void | AddEntryL ( ThspsDomStringPoolOptimizerEntry &) |
| void | Close () |
| TInt | Count () |
| ThspsDomStringPoolOptimizerEntry & | Entry (const TInt ) |
| TInt | GetIndex (const TDesC8 &) |
| void | Reset () |
| Private Member Functions | |
|---|---|
| TInt | FindEntry (const TDesC8 &, const TInt , const TInt ) |
| TInt | FindInsertionIndexEstimate (const TDesC8 &, const TInt , const TInt ) |
| Private Attributes | |
|---|---|
| RArray < ThspsDomStringPoolOptimizerEntry > | iEntries |
| void | AddEntryL | ( | ThspsDomStringPoolOptimizerEntry & | aEntry | ) |
Add entry to optimizer list.
| ThspsDomStringPoolOptimizerEntry & aEntry | Entry to be added. |
| ThspsDomStringPoolOptimizerEntry & | Entry | ( | const TInt | aIndex | ) |
Get entry.
| const TInt aIndex | Index to Entry. |
| TInt | FindEntry | ( | const TDesC8 & | aString, |
| const TInt | aLeft, | |||
| const TInt | aRight | |||
| ) | [private] | |||
Find entry from alphabetic list. Uses binary search.
| TInt | FindInsertionIndexEstimate | ( | const TDesC8 & | aString, |
| const TInt | aLeft, | |||
| const TInt | aRight | |||
| ) | [private] | |||
Find a position clue for given string.
Will return index that can be used to initiate linear search. Uses binary search to limit required comparisons when string pools starts to fill.
Note: Returned index is not absolute! it must be only used as a start index for linear searching.
Returned index will be quite close to actual insertion position. it will be 0 - 2 steps backward from actual position.
| TInt | GetIndex | ( | const TDesC8 & | aString | ) |
Get index for string.
| const TDesC8 & aString | Reference to given string. |
| RArray < ThspsDomStringPoolOptimizerEntry > | iEntries | [private] |
Array of optimizer entries.
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.