cinderclient/v1/volume_snapshots.py
def list(self, detailed=True, search_opts=None):
        """
        Get a list of all snapshots.

        :rtype: list of :class:`Snapshot`
        """

        if search_opts is None:
            search_opts = {}

        qparams = {}

        for opt, val in six.iteritems(search_opts):
            if val:
                qparams[opt] = val

        # Transform the dict to a sequence of two-element tuples in fixed
        # order, then the encoded string will be consistent in Python 2&3.
        if qparams:
            new_qparams = sorted(qparams.items(), key=lambda x: x[0])
            query_string = "?%s" % urlencode(new_qparams)
        else:
            query_string = ""

        detail = ""
        if detailed:
            detail = "/detail"

        return self._list("/snapshots%s%s" % (detail, query_string),
                          "snapshots")

        Get a list of all snapshots.

        :rtype: list of :class:`Snapshot`
        
Get a list of all snapshots.
Get a list of all snapshots .
def list(self, detailed=True, search_opts=None):
        if search_opts is None:
            search_opts = {}
        qparams = {}
        for opt, val in six.iteritems(search_opts):
            if val:
                qparams[opt] = val
        if qparams:
            new_qparams = sorted(qparams.items(), key=lambda x: x[0])
            query_string = "?%s" % urlencode(new_qparams)
        else:
            query_string = ""
        detail = ""
        if detailed:
            detail = "/detail"
        return self._list("/snapshots%s%s" % (detail, query_string),
                          "snapshots")
def list ( self , detailed = True , search_opts = None ) : if search_opts is None : search_opts = { } qparams = { } for opt , val in six . iteritems ( search_opts ) : if val : qparams [ opt ] = val if qparams : new_qparams = sorted ( qparams . items ( ) , key = lambda x : x [ 0 ] ) query_string = "?%s" % urlencode ( new_qparams ) else : query_string = "" detail = "" if detailed : detail = "/detail" return self . _list ( "/snapshots%s%s" % ( detail , query_string ) , "snapshots" )
Get a list of all snapshots.
Get a list of all snapshots .
"""
        Get a list of all snapshots.

        :rtype: list of :class:`Snapshot`
        """ # Transform the dict to a sequence of two-element tuples in fixed # order, then the encoded string will be consistent in Python 2&3.
None
list of :class:`Snapshot`
self
detailed
search_opts