You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Licensed to the Apache Software Foundation (ASF) under one
3
+
* or more contributor license agreements. See the NOTICE file
4
+
* distributed with this work for additional information
5
+
* regarding copyright ownership. The ASF licenses this file
6
+
* to you under the Apache License, Version 2.0 (the
7
+
* "License"); you may not use this file except in compliance
8
+
* with the License. You may obtain a copy of the License at
9
+
*
10
+
* https://www.apache.org/licenses/LICENSE-2.0
11
+
*
12
+
* Unless required by applicable law or agreed to in writing,
13
+
* software distributed under the License is distributed on an
14
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15
+
* KIND, either express or implied. See the License for the
16
+
* specific language governing permissions and limitations
17
+
* under the License.
18
+
*/
19
+
packageru.solrudev.ackpine.compress;
20
+
21
+
importjava.io.IOException;
22
+
23
+
/**
24
+
* Signals that a Pack200 Compress exception of some sort has occurred.
25
+
*
26
+
* @since 1.28.0
27
+
*/
28
+
publicclassCompressExceptionextendsIOException {
29
+
30
+
/** Serial. */
31
+
privatestaticfinallongserialVersionUID = 1;
32
+
33
+
/**
34
+
* Constructs an {@code CompressException} with {@code null} as its error detail message.
35
+
*/
36
+
publicCompressException() {
37
+
// empty
38
+
}
39
+
40
+
/**
41
+
* Constructs a new exception with the specified detail message. The cause is not initialized.
42
+
*
43
+
* @param message The message (which is saved for later retrieval by the {@link #getMessage()} method).
44
+
*/
45
+
publicCompressException(finalStringmessage) {
46
+
super(message);
47
+
}
48
+
49
+
/**
50
+
* Constructs a new exception with the specified detail message and cause.
51
+
*
52
+
* @param message The message (which is saved for later retrieval by the {@link #getMessage()} method).
53
+
* @param cause The cause (which is saved for later retrieval by the {@link #getCause()} method). A null value indicates that the cause is nonexistent or
* Constructs a {@code CompressException} with the specified cause and a detail message.
62
+
*
63
+
* @param cause The cause (which is saved for later retrieval by the {@link #getCause()} method). (A null value is permitted, and indicates that the cause
Copy file name to clipboardExpand all lines: ackpine-splits/compress-android/src/main/java/ru/solrudev/ackpine/compress/MemoryLimitException.java
+54-17Lines changed: 54 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -18,45 +18,82 @@
18
18
*/
19
19
packageru.solrudev.ackpine.compress;
20
20
21
-
importjava.io.IOException;
22
-
23
21
/**
24
22
* If a stream checks for estimated memory allocation, and the estimate goes above the memory limit, this is thrown. This can also be thrown if a stream tries
25
23
* to allocate a byte array that is larger than the allowable limit.
Copy file name to clipboardExpand all lines: ackpine-splits/compress-android/src/main/java/ru/solrudev/ackpine/compress/archivers/ArchiveInputStream.java
* Archive input streams <b>MUST</b> override the {@link #read(byte[], int, int)} - or {@link #read()} - method so that reading from the stream generates EOF
31
-
* for the end of data in each entry as well as at the end of the file proper.
30
+
* Archive input streams <strong>MUST</strong> override the {@link #read(byte[], int, int)} - or {@link #read()} - method so that reading from the stream
31
+
* generates EOF for the end of data in each entry as well as at the end of the file proper.
32
32
* <p>
33
33
* The {@link #getNextEntry()} method is used to reset the input stream ready for reading the data from the next entry.
34
34
* </p>
35
35
* <p>
36
36
* The input stream classes must also implement a method with the signature:
37
37
* </p>
38
+
*
38
39
* <pre>
39
40
* public static boolean matches(byte[] signature, int length)
40
41
* </pre>
@@ -50,16 +51,17 @@ public abstract class ArchiveInputStream<E extends ArchiveEntry> extends FilterI
Copy file name to clipboardExpand all lines: ackpine-splits/compress-android/src/main/java/ru/solrudev/ackpine/compress/archivers/zip/AbstractUnicodeExtraField.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -96,7 +96,7 @@ public ZipShort getCentralDirectoryLength() {
0 commit comments