Skip to main content

Ens.DocClassMap

class Ens.DocClassMap

Class to implement an efficient listing of SearchTables which have stored data for various document types. The primary purpose of this class is to ensure that the removal of documents which may have been indexed can remove all related SearchTable data for the given document.

Method Inventory

Methods

classmethod AddSearchTable(pDocClass As %String, pSearchTableRoot As %String, pUpdateCache As %Boolean = $data($$$EnsJobLocal)) as %Status
Make a record of the fact that the message class pDocClass has stored data in the extent defined by the class in pSearchTableRoot. pUpdateCache indicates whether the local process cache should be updated. This should generally be performed while within jobs which need to maintain this information for some time.
In order to reduce lock waiting time do not treat as fatal if cannot obtain lock immediately.
classmethod IsCacheCurrent(pDocClass As %String) as %Boolean
Returns a flag to indicate whether the cached values for a given document class are currently valid.
classmethod RebuildMap(pRemoveFirst As %Boolean = 0, pCheckExtent As %Boolean = 1, pVerbose As %Boolean = 0) as %Status
Should there be a problem whereby the data in ^Ens.DocClassMap is lost, this method can be invoked to rebuild the data in the DocClassMap.
pRemoveFirst controls whether the current contents of the map are removed before determining any new entries to add.
pCheckExtent controls whether code will check whether the SearchTable extent contains any data. If it doesn't then the SearchTable won't be added to the DocClassMap.
pVerbose controls whether output is logged to the current device.
classmethod RemoveSearchTable(pSearchTable As %String, pUpdateCache As %Boolean = $data($$$EnsJobLocal)) as %Status
API to clean up the entries for a given SearchTable extent specified by pSearchTable.
classmethod UpdateCache(pDocClass As %String) as %Status
Update the local in-process cache to ensure that it is valid.
FeedbackOpens in a new tab