Contents · Forum Home · StreamSec Tools 4.1.5.363 documentation

methodTstAbstractKeyIndex.GetIdentifierForNewKey

function GetIdentifierForNewKey(const aKey : iUnknown; const aStoreID : string = ''; aOverrideReadOnly: Boolean = False) : OctetString;
Computes the lookup identifier a new key would receive in this index, without inserting it (the actual insertion is done later by AddKeyToIndex). Call this when adding a key to a specific store (aStoreID must be one of this index' selected Stores) to learn its lookup identifier in advance. Returns an empty OctetString if the store is not selected by this index, the index is read-only (and aOverrideReadOnly is not passed), the key cannot be indexed, or a duplicate is rejected by an OnIgnoreDuplicate handler; a Duplicates = dupError collision instead raises an exception.