您应该尽可能喜欢 Files.copy 。它以本机代码实现,因此可以更快。 transferTo 仅当两个流都不是FileInputStream / FileOutputStream时才应使用。
確定! 回上一頁