All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.robe.common.service.headers.ResponseHeadersUtil Maven / Gradle / Ivy

There is a newer version: 0.5.0.0-1039
Show newest version
package io.robe.common.service.headers;

import io.robe.common.service.search.model.SearchModel;

import javax.servlet.http.HttpServletResponse;

public final class ResponseHeadersUtil {
    private ResponseHeadersUtil() {

    }

    public static final void addTotalCount(SearchModel model) {
        model.getResponse().setHeader("X-Total-Count", model.getTotalCount() + "");
    }

    public static final void addLocation(HttpServletResponse response, String location) {
        response.setHeader("Location", location);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy