Starting March 27, 2025, we recommend using android-latest-release
instead of aosp-main
to build and contribute to AOSP. For more information, see Changes to AOSP.
Stay organized with collections
Save and categorize content based on your preferences.
DigestCalculator
public
class
DigestCalculator
extends Object
java.lang.Object
|
↳ |
com.android.tradefed.cache.DigestCalculator
|
Utility methods to compute Digest
.
Summary
Public methods |
static
Digest
|
compute(Message message)
Computes a digest for a proto message.
|
static
Digest
|
compute(File file)
Computes a digest for a file.
|
static
Digest
|
compute(byte[] blob)
Computes a digest for a byte array.
|
Fields
DIGEST_FUNCTION
public static final DigestFunction.Value DIGEST_FUNCTION
Public constructors
DigestCalculator
public DigestCalculator ()
Public methods
compute
public static Digest compute (Message message)
Computes a digest for a proto message.
Parameters |
message |
Message : the Message that the digest is calculated for |
Returns |
Digest |
the Digest of the message |
compute
public static Digest compute (File file)
Computes a digest for a file.
Parameters |
file |
File : the ERROR(/File) that the digest is calculated for |
Returns |
Digest |
the Digest of the file |
compute
public static Digest compute (byte[] blob)
Computes a digest for a byte array.
Parameters |
blob |
byte : the byte array that the digest is calculated for |
Returns |
Digest |
the Digest of the blob |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2024-10-08 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-08 UTC."],[],[]]