Package org.eclipse.jgit.api
Class ApplyCommand.SHA1InputStream
- java.lang.Object
-
- java.io.InputStream
-
- org.eclipse.jgit.api.ApplyCommand.SHA1InputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
- Enclosing class:
- ApplyCommand
private static class ApplyCommand.SHA1InputStream extends java.io.InputStreamAnInputStreamthat updates aSHA1on every byte read. The hash is supposed to have been initialized before reading starts.
-
-
Constructor Summary
Constructors Constructor Description SHA1InputStream(SHA1 hash, java.io.InputStream in)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()intread()intread(byte[] b, int off, int len)
-
-
-
Field Detail
-
hash
private final SHA1 hash
-
in
private final java.io.InputStream in
-
-
Constructor Detail
-
SHA1InputStream
SHA1InputStream(SHA1 hash, java.io.InputStream in)
-
-
Method Detail
-
read
public int read() throws java.io.IOException- Specified by:
readin classjava.io.InputStream- Throws:
java.io.IOException
-
read
public int read(byte[] b, int off, int len) throws java.io.IOException- Overrides:
readin classjava.io.InputStream- Throws:
java.io.IOException
-
close
public void close() throws java.io.IOException- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- Overrides:
closein classjava.io.InputStream- Throws:
java.io.IOException
-
-