Class EncryptionMaterialsRequest

java.lang.Object
com.amazonaws.encryptionsdk.model.EncryptionMaterialsRequest

public final class EncryptionMaterialsRequest extends Object
Contains the contextual information needed to prepare an encryption operation.
See Also:
CryptoMaterialsManager.getMaterialsForEncrypt(EncryptionMaterialsRequest)
  • Method Details

    • getContext

      public Map<String,​String> getContext()
      Returns:
      the encryption context (possibly an empty map)
    • getRequestedAlgorithm

      public CryptoAlgorithm getRequestedAlgorithm()
      Returns:
      If a specific encryption algorithm was requested by calling AwsCrypto.setEncryptionAlgorithm(CryptoAlgorithm), the algorithm requested. Otherwise, returns null.
    • getPlaintextSize

      public long getPlaintextSize()
      Returns:
      The size of the plaintext if known, or -1 otherwise
    • getPlaintext

      public byte[] getPlaintext()
      Returns:
      The entire input plaintext, if available (and not streaming). Note that for performance reason this is not a copy of the plaintext; you should never modify this buffer, lest the actual data being encrypted be modified. If the input plaintext is unavailable, this will be null.
    • getCommitmentPolicy

      public CommitmentPolicy getCommitmentPolicy()
    • toBuilder

    • newBuilder

      public static EncryptionMaterialsRequest.Builder newBuilder()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object