Package org.springframework.http

Examples of org.springframework.http.HttpHeaders


    public void setRestTemplate(RestTemplate rt) {
        this.rt = rt;
    }

    private HttpHeaders getHeaders() {
        HttpHeaders headers = new HttpHeaders();
        headers.add("Accept", "application/json");
        headers.add("Content-Type", "application/json");
        headers.add("Zencoder-Api-Key", api_key);
        headers.add("User-Agent", "zencoder-java-2.0");
        return headers;
    }
View Full Code Here


            throw new ZencoderClientException(
                    "Unable to serialize ZencoderCreateJobRequest as JSON",
                    e);
        }

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>(body, headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

                per_page = 50;
            }
            url = url + "?page=" + page + "&per_page=" + per_page;
        }

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderJobDetail getZencoderJob(String id) throws ZencoderClientException {
        String url = api_url + "/jobs/" + id + ".json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderJobProgress getJobProgress(String id) throws ZencoderClientException {
        String url = api_url + "/jobs/" + id + "/progress.json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderInputOutputProgress getInputProgress(String id) throws ZencoderClientException {
        String url = api_url + "/inputs/" + id + "/progress.json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderInputOutputProgress getOutputProgress(String id) throws ZencoderClientException {
        String url = api_url + "/outputs/" + id + "/progress.json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderMediaFile getInputDetails(String id) throws ZencoderClientException {
        String url = api_url + "/inputs/" + id + ".json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public ZencoderMediaFile getOutputDetails(String id) throws ZencoderClientException {
        String url = api_url + "/outputs/" + id + ".json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        ResponseEntity<String> response = null;
        try {
View Full Code Here

     * @throws ZencoderClientException
     */
    public void resubmitJob(String id) throws ZencoderClientException {
        String url = api_url + "/jobs/" + id + "/resubmit.json";

        HttpHeaders headers = getHeaders();
        @SuppressWarnings("rawtypes")
        HttpEntity entity = new HttpEntity<String>("", headers);

        try {
            rt.exchange(
View Full Code Here

TOP

Related Classes of org.springframework.http.HttpHeaders

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.