mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-12-22 10:57:58 +01:00
Mark ArmoredInputStreamFactory methods as @Nonnull
This commit is contained in:
parent
772c0407b3
commit
5c11b8af08
1 changed files with 4 additions and 1 deletions
|
@ -9,6 +9,8 @@ import java.io.InputStream;
|
|||
|
||||
import org.bouncycastle.bcpg.ArmoredInputStream;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
/**
|
||||
* Factory class for instantiating preconfigured {@link ArmoredInputStream ArmoredInputStreams}.
|
||||
* {@link #get(InputStream)} will return an {@link ArmoredInputStream} that is set up to properly detect CRC errors.
|
||||
|
@ -26,7 +28,8 @@ public final class ArmoredInputStreamFactory {
|
|||
* @return armored input stream
|
||||
* @throws IOException in case of an IO error
|
||||
*/
|
||||
public static ArmoredInputStream get(InputStream inputStream) throws IOException {
|
||||
@Nonnull
|
||||
public static ArmoredInputStream get(@Nonnull InputStream inputStream) throws IOException {
|
||||
if (inputStream instanceof CRCingArmoredInputStreamWrapper) {
|
||||
return (ArmoredInputStream) inputStream;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue