/**
* 文件拷贝
*
* @param src
* @param dst
* @throws IOException
*/
public static void fileCopy(File src, File dst) throws IOException {
FileInputStream fi = null;
FileOutputStream fo = null;
FileChannel in = null;
FileChannel out = null;
try {
fi = new FileInputStream(src);
fo = new FileOutputStream(dst);
in = fi.getChannel();// 得到对应的文件通道
out = fo.getChannel();// 得到对应的文件通道
out.transferFrom(in, 0, in.size());// 有多大复制多大
} finally {
CloseableUtils.close(fi);
CloseableUtils.close(in);
CloseableUtils.close(fo);
CloseableUtils.close(out);
}
}