Package de.devbliss.apitester.factory

Examples of de.devbliss.apitester.factory.HttpDeleteWithBody


    public DeleteWithoutRedirectImpl(Gson gson) {
        this.gson = gson;
    }

    public HttpDeleteWithBody createDeleteRequest(URI uri, Object payload) throws IOException {
        HttpDeleteWithBody httpDelete = new HttpDeleteWithBody(uri);
        HttpParams params = new BasicHttpParams();
        params.setParameter(HANDLE_REDIRECTS, false);
        httpDelete.setParams(params);

        if (payload != null) {
            String json = gson.toJson(payload);
            StringEntity entity = new StringEntity(json, ENCODING);
            entity.setContentType(ContentType.APPLICATION_JSON.getMimeType());
            httpDelete.setEntity(entity);
        }

        return httpDelete;
    }
View Full Code Here


    public DeleteWithoutRedirectImpl(EntityBuilder entityBuilder) {
        this.entityBuilder = entityBuilder;
    }

    public HttpDeleteWithBody createDeleteRequest(URI uri, Object payload) throws IOException {
        HttpDeleteWithBody httpDelete = new HttpDeleteWithBody(uri);
        HttpParams params = new BasicHttpParams();
        params.setParameter(HANDLE_REDIRECTS, false);
        httpDelete.setParams(params);

        if (payload != null) {
            httpDelete.setEntity(entityBuilder.buildEntity(payload));
        }

        return httpDelete;
    }
View Full Code Here

    public DeleteWithoutRedirectImpl(Gson gson) {
        this.gson = gson;
    }

    public HttpDeleteWithBody createDeleteRequest(URI uri, Object payload) throws IOException {
        HttpDeleteWithBody httpDelete = new HttpDeleteWithBody(uri);
        HttpParams params = new BasicHttpParams();
        params.setParameter(HANDLE_REDIRECTS, false);
        httpDelete.setParams(params);

        if (payload != null) {
            String json = gson.toJson(payload);
            StringEntity entity = new StringEntity(json, ENCODING);
            entity.setContentType(ContentType.APPLICATION_JSON.getMimeType());
            httpDelete.setEntity(entity);
        }

        return httpDelete;
    }
View Full Code Here

    public DeleteWithoutRedirectImpl(Gson gson) {
        this.gson = gson;
    }

    public HttpDeleteWithBody createDeleteRequest(URI uri, Object payload) throws IOException {
        HttpDeleteWithBody httpDelete = new HttpDeleteWithBody(uri);
        HttpParams params = new BasicHttpParams();
        params.setParameter(HANDLE_REDIRECTS, false);
        httpDelete.setParams(params);

        if (payload != null) {
            String json = gson.toJson(payload);
            StringEntity entity = new StringEntity(json, ENCODING);
            entity.setContentType(ContentType.APPLICATION_JSON.getMimeType());
            httpDelete.setEntity(entity);
        }

        return httpDelete;
    }
View Full Code Here

TOP

Related Classes of de.devbliss.apitester.factory.HttpDeleteWithBody

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.