Did I find the right examples for you? yes no

All Samples(5)  |  Call(1)  |  Derive(4)  |  Import(0)

src/d/o/dodai-compute-HEAD/nova/api/openstack/servers.py   dodai-compute(Download)
class HeadersSerializer(wsgi.ResponseHeadersSerializer):
 
    def create(self, response, data):
        response.status_int = 202
 

src/d/o/dodai-compute-HEAD/nova/api/openstack/versions.py   dodai-compute(Download)
class VersionsHeadersSerializer(wsgi.ResponseHeadersSerializer):
    def multi(self, response, data):
        response.status_int = 300
 
 

src/d/o/dodai-compute-HEAD/nova/api/openstack/common.py   dodai-compute(Download)
class MetadataHeadersSerializer(wsgi.ResponseHeadersSerializer):
 
    def delete(self, response, data):
        response.status_int = 204
 

src/d/o/dodai-compute-HEAD/nova/tests/api/openstack/test_wsgi.py   dodai-compute(Download)
    def test_default(self):
        serializer = wsgi.ResponseHeadersSerializer()
        response = webob.Response()
        serializer.serialize(response, {'v': '123'}, 'asdf')
        self.assertEqual(response.status_int, 200)
 
    def test_custom(self):
        class Serializer(wsgi.ResponseHeadersSerializer):