Skip to main content

%DeepSee.SetBuilder.Definition

Method Inventory

Parameters

parameter MODE = DYNAMIC;
Default mode of operation for this set definition. The default is "DYNAMIC", which means any calls to fetch the set's members through %GetAsArray(), %Execute(), %GetMemberCount() etc will result in the set being "executed" according to its definition. Setting this parameter to "STATIC" will retrieve the results based on the most recent snapshot of this definition or return an error if there is no snapshot.

Methods

method %ContainsID(pID As %String, ByRef pParameters, Output pSC As %Status, pUseSnapshot As %String = "") as %Boolean

Returns whether or not pID is a member of this set.

If pUseSnapshot is non-null, the returned result will be based on the snapshot named pUseSnapshot. Use "LATEST" to use the most recent snapshot for this set. If MODE="STATIC", a null value for this argument will be interpreted as "LATEST" (to override, pass $c(0)).

final method %CreateSnapshot(Output pSnapshot, ByRef pParameters, ByRef pName As %String = "", pDescription As %String = "", pIgnoreProperties As %Boolean = 1) as %Status

Creates and saves a snapshot of the contents of this set using the named parameter array pParameters. The snapshot name pName should be unique for this set definition, but can also be left blank in which case a unique name will be generated automatically.

classmethod %DropAllSnapshots() as %Status
Drops all snapshots created for this set definition
classmethod %DropSnapshot(pName As %String = "") as %Status
Drops snapshot pName, created for this set definition.
method %Execute(ByRef pParameters, Output pSC As %Status, pUseSnapshot As %String = "") as %SQL.IResultSet

Executes the set definition using parameter array pParameters, returning a ResultSet object.

If pUseSnapshot is non-null, the returned result will be based on the snapshot named pUseSnapshot. Use "LATEST" to use the most recent snapshot for this set. If MODE="STATIC", a null value for this argument will be interpreted as "LATEST" (to override, pass $c(0)).

method %ExecuteListing(pListing As %String = "", ByRef pParameters, Output pSC As %Status, pUseSnapshot As %String = "") as %SQL.StatementResult

Returns a ResultSet object fetching a listing of the members of this set. The fields retrieved are defined through the <listing> element named pListing in the set definition Set. If pListing="", the default listing will be returned and if there is no default listing defined, the first <listing> element counts as the default.

If pUseSnapshot is non-null, the returned result will be based on the snapshot named pUseSnapshot. Use "LATEST" to use the most recent snapshot for this set. If MODE="STATIC", a null value for this argument will be interpreted as "LATEST" (to override, pass $c(0)).

method %GetAsArray(Output pArray, ByRef pParameters, pIgnoreProperties As %Boolean = 0, pUseSnapshot As %String = "") as %Status

Returns the members of the set as an array of identifiers. The value side of the array will contain the external properties defined by the set, unless pIgnoreProperties is set to 1.

If pUseSnapshot is non-null, the returned result will be based on the snapshot named pUseSnapshot. Use "LATEST" to use the most recent snapshot for this set. If MODE="STATIC", a null value for this argument will be interpreted as "LATEST" (to override, pass $c(0)).

final classmethod %GetInstance(pSetName As %String, Output pSC As %Status) as %DeepSee.SetBuilder.Definition

Returns an instance of the defined set named pSetName.

method %GetMemberCount(ByRef pParameters, Output pSC As %Status, pUseSnapshot As %String = "") as %Integer

Returns the total number of members for this set.

If pUseSnapshot is non-null, the returned result will be based on the snapshot named pUseSnapshot. Use "LATEST" to use the most recent snapshot for this set. If MODE="STATIC", a null value for this argument will be interpreted as "LATEST" (to override, pass $c(0)).

classmethod %GetSetName() as %String
Returns the name of this set, as defined in Set
method %GetSnapshot(Output pSnapshot, pName As %String = "", pCheckTargetClass As %Boolean = 1, pCheckChecksum As %Boolean = 0) as %Status

Retrieves the snapshot object named pName, or the most recently created snapshot if pName="LATEST".

If pCheckTargetClass=1, this method will check whether the current target class of this set definition is still the same as the target class when the snapshot was created and return an error if they don't match. The current subclass may be a superclass (more generic) of the one registered with the snapshot. Note that this method does not check the IdField, As it should still be possible to translate between different identifiers.

If pCheckChecksum=1, this method will check whether the set definition is still the same as when the snapshot was created.

Inherited Members

Inherited Methods

FeedbackOpens in a new tab