Application Framework Reference

Splunk API

popIntention()

The popIntention() method gets the specified intention, intentionName , constrained by the optional secondArgKey parameter. The retrieved intention is removed from the intentions list.

Synopsis

intention = popIntention( intentionName , secondArgKey )

Parameters

intentionName

String

Name of intention to be retrieved and removed from list.

secondArgKey

String

(Optional) Secondary key that must be present as an argument of the intentionName for the reference to be removed and returned.

Return Value

Object

Requested intention.

Example

var context = this.getContext();var search = context.get('search');
if (search.getIntentionReference('setfields')) {
    search.popIntention('setfields');
}
 

See Also

absorbIntentions()
addIntention()
clearIntentions()
getIntentionReference()
hasIntentions()
setIntentions()