Object GenericEncrypter

  • All Implemented Interfaces:

    
    public class GenericEncrypter
    
                        

    Allows the encryption of any type of data to be sent to Adyen's APIs. Use this class with custom component integrations.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final String encryptField(String fieldKeyToEncrypt, Object fieldValueToEncrypt, String publicKey) Encrypts a single field into a block of content.
      final String encryptFields(String publicKey, Pair<String, Object> fieldsToEncrypt) Encrypts multiple fields into a single block of content.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • encryptField

         final String encryptField(String fieldKeyToEncrypt, Object fieldValueToEncrypt, String publicKey)

        Encrypts a single field into a block of content.

        Parameters:
        fieldKeyToEncrypt - The key of the field to be encrypted.
        fieldValueToEncrypt - The value of the field to be encrypted.
        publicKey - The key to be used for encryption.
        Returns:

        The encrypted string.

      • encryptFields

         final String encryptFields(String publicKey, Pair<String, Object> fieldsToEncrypt)

        Encrypts multiple fields into a single block of content.

        Parameters:
        publicKey - The key to be used for encryption.
        fieldsToEncrypt - The fields to be encrypted.
        Returns:

        The encrypted string.