flask_restful_dbbase.resources.CollectionModelResource.as_view¶
- classmethod CollectionModelResource.as_view(name, *class_args, **class_kwargs)¶
Convert the class into a view function that can be registered for a route.
By default, the generated view will create a new instance of the view class for every request and call its
dispatch_request()
method. If the view class setsinit_every_request
toFalse
, the same instance will be used for every request.The arguments passed to this method are forwarded to the view class
__init__
method.Changed in version 2.2: Added the
init_every_request
class attribute.