MCPcopy Create free account
hub / github.com/FongMi/CatVodSpider / download

Method download

app/src/main/java/com/github/catvod/spider/Market.java:71–79  ·  view source on GitHub ↗
(File file, InputStream is)

Source from the content-addressed store, hash-verified

69 }
70
71 private void download(File file, InputStream is) throws IOException {
72 try (BufferedInputStream input = new BufferedInputStream(is); FileOutputStream os = new FileOutputStream(file)) {
73 byte[] buffer = new byte[16384];
74 int readBytes;
75 while ((readBytes = input.read(buffer)) != -1) {
76 os.write(buffer, 0, readBytes);
77 }
78 }
79 }
80
81 private void checkCopy(String url) {
82 for (Data data : datas) {

Callers 1

actionMethod · 0.95

Calls 2

readMethod · 0.80
writeMethod · 0.80

Tested by

no test coverage detected