Home > Class Reference > ENSLIB namespace > EnsPortal.MsgFilter.AbstractAssistant


abstract class EnsPortal.MsgFilter.AbstractAssistant extends %RegisteredObject

Base class used to generate results for the various message viewer UI pages in the portal. Users can override this class to provide custom code to parse and process conditions created in the UI pages. It is more likely that users will wish to override one of the subclasses of this class (specifically EnsPortal.MsgFilter.Assistant or Ens.Enterprise.Portal.MsgFilter.Assistant) which are capable of parsing the incoming conditions and producing SQL queries. In addition, these subclasses provide callbacks which allow users to manipulate the generated SQL in useful ways without major development effort. Note: InterSystems is not responsible for user extensions to these classes.


Parameters Properties Methods Queries Indices ForeignKeys Triggers
3 7


%AddToSaveSet %ClassIsLatestVersion %ClassName %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IsA %IsModified %New
%NormalizeObject %ObjectModified %OriginalNamespace %PackageName
%RemoveFromSaveSet %SerializeObject %SetModified %ValidateObject
CheckFilter CreateFilter CreateProxy GetQueryHistory
GetResultSet LogQuery UpdateQuery


parameter FilterClass = "EnsPortal.MsgFilter.Filter";
Name of Filter to use for searches.
parameter QUERYHISTORY = 5;
The maximum number of queries to store when the session query history is being stored.
Subscript under temporary session data to use for storing the search history for the viewer. The storage is activated by setting the ^Ens.Debug("UtilEnsMessages","sql") debug node to a positive number.


classmethod CheckFilter(pFilter As EnsPortal.MsgFilter.Filter, Output pWarnings As %Library.ListOfDataTypes) as %Status
classmethod CreateFilter(pSearchCriteria As %ZEN.proxyObject, Output pFilter As EnsPortal.MsgFilter.Filter, pExcludeSequenceManager As %Boolean = 1, pVirtualKey As %Integer = 0) as %Status
Callback to create the Filter class for this Assistant. Note that the supplied proxyObject may contain information related to paging which is not a part of the filter object model.
classmethod CreateProxy(pFilter As EnsPortal.MsgFilter.Filter, Output pSearchCriteria As %ZEN.proxyObject, pExcludeSequenceManager As %Boolean = 1) as %Status
Callback to create a Zen proxyObject from a supplied Filter. By default, sequence manager searches are excluded.
classmethod GetQueryHistory(Output pHistory, pMaxResults As %Integer = -1) as %Status
API to retrieve the logged query data for the current session. pHistory has the following structure:
pHistory(n) = $listbuild([time_logged],[query_text],[time_to_execute],[time_to_close],[grefs_to_execute],[grefs_to_close])
classmethod GetResultSet(pFilter As EnsPortal.MsgFilter.Filter, Output pResultSet As %ResultSet, pExecute As %Boolean = 1) as %Status
Helper method to return a valid ResultSet for the supplied Filter object. Subclasses must implement this method.
classmethod LogQuery(pQueryText As %String = "", Output pCounter As %Integer) as %Status
API to log data about queries in the current session context if viewer debugging is enabled via the ^Ens.Debug("UtilEnsMessages","sql") debug global. The data for the current session can be retrieved via the GetQueryHistory() API. Note that UpdateQuery() is also used to provide further runtime statistics for queries.
classmethod UpdateQuery(pCounter As %Integer = 0, pType As %String = "") as %Status
API to update the statistics for a previously logged query referenced by pCounter. pType must currently be either "execute" or "close" for the query statistics to be updated.