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

io.github.saoxuequ.http.request.light.entity.StringEntity Maven / Gradle / Ivy

package io.github.saoxuequ.http.request.light.entity;

import java.io.IOException;
import java.io.OutputStream;

import org.apache.commons.io.IOUtils;

import io.github.saoxuequ.http.request.core.Entity;

public class StringEntity extends Entity {

    @Override
    public void write(OutputStream outputStream) {
        try (OutputStream os = outputStream) {
            IOUtils.write(getEntity(), os);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy