Esempio n. 1
0
class SavedShow(RequestFactory.showoneformatted(SavedRequest)):
    '''Re-do a saved request with show one format'''

    def take_action(self, args):
        return super(SavedShow, self).act(method='GET', args=args)
Esempio n. 2
0
class GET(RequestFactory.unformatted(UnSavedRequest)):
    '''Do GET request'''

    def take_action(self, args):
        '''Override parent method'''
        super(GET, self).act(method='GET', args=args)
Esempio n. 3
0
class SavedRedo(RequestFactory.unformatted(SavedRequest)):
    '''Re-do a saved request'''

    def take_action(self, args):
        super(SavedRedo, self).act(method=None, args=args)
Esempio n. 4
0
class SavedList(RequestFactory.listformatted(SavedRequest)):
    '''Re-do a saved request with list format'''

    def take_action(self, args):
        return super(SavedList, self).act(method='GET', args=args)
Esempio n. 5
0
class UnSavedShow(RequestFactory.showoneformatted(UnSavedRequest)):
    '''Show a particular resource'''

    def take_action(self, args):
        return super(UnSavedShow, self).act(method='GET', args=args)
Esempio n. 6
0
class UnSavedList(RequestFactory.listformatted(UnSavedRequest)):
    '''Fetch a list of resources'''

    def take_action(self, args):
        return super(UnSavedList, self).act(method='GET', args=args)
Esempio n. 7
0
class DELETE(RequestFactory.unformatted(UnSavedRequest)):
    '''Do DELETE request'''

    def take_action(self, args):
        super(DELETE, self).act(method='DELETE', args=args)
Esempio n. 8
0
class PATCH(RequestFactory.unformatted(UnSavedRequest)):
    '''Do PATCH request'''

    def take_action(self, args):
        super(PATCH, self).act(method='PATCH', args=args)
Esempio n. 9
0
class PUT(RequestFactory.unformatted(UnSavedRequest)):
    '''Do PUT request'''

    def take_action(self, args):
        super(PUT, self).act(method='PUT', args=args)