package ru.yandex.qe.http;

import java.io.IOException;

import org.apache.http.HttpResponse;
import org.apache.http.client.ResponseHandler;

/**
 * Established by terry
 * on 25.06.14.
 */
public class ResponseHandlers {

    public static <T> ResponseHandler<T> nothing() {
        //noinspection unchecked
        return (ResponseHandler<T>) NOTHING;
    }

    private static final ResponseHandler<?> NOTHING = new ResponseHandler<Object>() {
        @Override
        public Object handleResponse(HttpResponse response) throws IOException {
            return null;
        }
    };
}
