Application Framework Reference

Model API

all()

The all() method retrieves the entire set of model objects for all the models in scope. This convenience method is a wrapper for SplunkQuerySet.all().

Use this method in combination with SplunkQuerySet.filter(), SplunkQuerySet.filter_by_app(), SplunkQuerySet.filter_by_user(), and SplunkQuerySet.search() to populate lists or locate specific entities from the pool of models in scope.

Synopsis

qsObj = all()

Return Value

Object

A SplunkQuerySet object containing a list of all models in scope.

Example

Example 1
from splunk.models.base  import SplunkRESTModel
class MyAppModel(SplunkRESTModel):
    
    def index(self):
        apps  = self.all()

class MyAppModel(SplunkRESTModel):
    
    def index(self):
        apps  = self.all().filter(is_disabled=False)
 
Example 2
from splunk.models.base  import SplunkRESTModel
class MyAppModel(SplunkRESTModel):
    
    def index(self):
        apps  = self.all().filter(is_disabled=False)
 

See Also

SplunkQuerySet.all()
SplunkQuerySet.filter()
SplunkQuerySet.filter_by_app()
SplunkQuerySet.filter_by_user()
SplunkQuerySet.order_by()
SplunkQuerySet.search()