def default_put_view(resource, request):
    try:
        data = request.json_body
    except __HOLE__:
        request.response.status_int = 400
        return {'message': 'No JSON data provided.'}
    resource.validate(data, partial=False)
    resource.update_from_dict(data, replace=True)
    return resource.to_dict()
dataset/ETHPy150Open wichert/rest_toolkit/src/rest_toolkit/views.py/default_put_view