public abstract class Digester<T extends Digest> extends OutputStream
Modifier and Type | Field and Description |
---|---|
protected MessageDigest |
md |
Constructor and Description |
---|
Digester(MessageDigest instance,
OutputStream... out) |
Modifier and Type | Method and Description |
---|---|
abstract T |
digest() |
abstract T |
digest(byte[] bytes) |
T |
from(byte[] f) |
T |
from(File f) |
T |
from(InputStream in) |
abstract String |
getAlgorithm() |
MessageDigest |
getMessageDigest() |
void |
setOutputs(OutputStream... out) |
void |
write(byte[] buffer,
int offset,
int length) |
void |
write(int b) |
close, flush, write
protected MessageDigest md
public Digester(MessageDigest instance, OutputStream... out)
public void write(byte[] buffer, int offset, int length) throws IOException
write
in class OutputStream
IOException
public void write(int b) throws IOException
write
in class OutputStream
IOException
public MessageDigest getMessageDigest() throws Exception
Exception
public T from(InputStream in) throws Exception
Exception
public void setOutputs(OutputStream... out)
public abstract String getAlgorithm()
Copyright © 2021 aQute SARL. All rights reserved.