我必须将文件上传到队列。但似乎 toByteArray() 方法实际上并未转换文件。为什么?
//upload the file to the queue
File file = new File("J:/Documents/Head Fund Share Class Attributes.xlsx");
//convert to byte array
byte[] array = null;
try {
array = Files.toByteArray(file);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
//send the file data
headFundUploader.send("helloworld.q", array);
绝地无双
心有法竹
相关分类