我有金字塔服务和这样的代码:
@view_defaults(route_name="result", context=Result, renderer="json")
class ResultView(RESTView):
"""
Rest view for exercise results
"""
@view_config(request_method='GET', permission='view', role="owner")
@view_config(request_method='GET', permission='view', role="admin")
@view_config(request_method='GET', permission='view', role="gadmin")
@schema(Result)
@log("get result")
def get(self):
"""
Gets result
"""
return self.get.__schema__.dictirialize(self.context, prepare_json=True)
......
我怎样才能在里面获得匹配的视图ResultView.get
?