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

cn.fangxinqian.operator.sdk.convert.FileConvertService Maven / Gradle / Ivy

There is a newer version: 1.1.2
Show newest version
package cn.fangxinqian.operator.sdk.convert;

import cn.fangxinqian.operator.sdk.constant.UrlConstant;
import cn.fangxinqian.operator.sdk.convert.dto.ConvertDTO;
import cn.fangxinqian.operator.sdk.replace.vo.ConvertVO;
import cn.fangxinqian.operator.sdk.utils.OkHttp;
import com.alibaba.fastjson.JSON;

import java.io.IOException;

/**
 * @Author NieZhiLiang
 * @Email [email protected]
 * @GitHub https://github.com/niezhiliang
 * @Date 2019-10-15 2:12 下午
 */
public class FileConvertService {

    /**
     * doc转换pdf
     * @param convertDTO
     * @return
     * @throws IOException
     */
    public static ConvertVO convert(ConvertDTO convertDTO) throws IOException {

        String result = OkHttp.doPost(UrlConstant.FILE_CONVERT_OFFICE, JSON.toJSONString(convertDTO));
        return JSON.parseObject(result,ConvertVO.class);
    }

    public static void pdfConvertImg(ConvertDTO convertDTO) {

    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy