use of com.intel.mtwilson.util.io.ByteArray in project OpenAttestation by OpenAttestation.
the class Document method getEtag.
public String getEtag() {
if (etag != null) {
return etag;
}
if (modifiedOn != null) {
String hex = Long.toHexString(modifiedOn.getTime());
ByteArray byteArray = ByteArray.fromHex(hex);
Sha1Digest digest = Sha1Digest.digestOf(byteArray.getBytes());
return digest.toHexString();
}
return null;
}
Aggregations