Lines Matching refs:instream
3157 boolean restoreOneFile(InputStream instream, byte[] buffer) {
3160 info = readTarHeaders(instream);
3186 mPackagePolicies.put(pkg, readAppManifest(info, instream));
3191 skipTarPadding(info.size, instream);
3210 okay = installApk(info, installerName, instream);
3218 skipTarPadding(info.size, instream);
3352 int nRead = instream.read(buffer, 0, toRead);
3371 skipTarPadding(info.size, instream);
3398 long nRead = instream.read(buffer, 0, toRead);
3526 boolean installApk(FileMetadata info, String installerPackage, InputStream instream) {
3540 int didRead = instream.read(buffer, 0, (int)toRead);
3621 void skipTarPadding(long size, InputStream instream) throws IOException {
3626 if (readExactly(instream, buffer, 0, needed) == needed) {
3633 RestorePolicy readAppManifest(FileMetadata info, InputStream instream)
3641 if (readExactly(instream, buffer, 0, (int)info.size) == info.size) {
3802 FileMetadata readTarHeaders(InputStream instream) throws IOException {
3806 boolean gotHeader = readTarHeader(instream, block);
3826 gotHeader = readPaxExtendedHeader(instream, info);
3830 gotHeader = readTarHeader(instream, block);
3947 boolean readTarHeader(InputStream instream, byte[] block) throws IOException {
3948 final int got = readExactly(instream, block, 0, 512);
3956 boolean readPaxExtendedHeader(InputStream instream, FileMetadata info)
3968 if (readExactly(instream, data, 0, data.length) < data.length) {