第一种获取图片文件方式:
File file = new File(“d:\1548321541179.jpg”)
第二种获取图片文件方式:
String fileUrl=“http://111.111.1.111:11111//upload/img/storejoinin/1548321541179.jpg”
URL url = new URL(fileUrl);
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
int code = conn.getResponseCode();
if (200== code) {
InputStream inputStream = conn.getInputStream();
log.info("========= 远程服务图片流获取成功 ==============");
}