Enum Class DeviceCVMManager

java.lang.Object
java.lang.Enum<DeviceCVMManager>
com.gemalto.mfs.mwsdk.dcm.cdcvm.DeviceCVMManager
All Implemented Interfaces:
Serializable, Comparable<DeviceCVMManager>, Constable

public enum DeviceCVMManager extends Enum<DeviceCVMManager>
The CHVerificationMethod class is used to support the use of biometric fingerprint and device keyguard.
Note:This class can only be used if the card profile supports Flexible CD_CVM.
  • Enum Constant Details

  • Method Details

    • values

      public static DeviceCVMManager[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static DeviceCVMManager valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • initialize

      public void initialize(CHVerificationMethod chVerificationMethod) throws DeviceCVMException
      This API is used to initialize the biometric fingerprint or device keyguard. This method is called when MPA uses either the biometric fingerprint or device keyguard as the default cardholder verification method (CVM) during payment transactions. This API should only be called once.
      Parameters:
      chVerificationMethod - Enumeration of the possible cardholder verification methods may be required when activating a digitized card for a transaction.
      Throws:
      DeviceCVMException - An exception is thrown if an error is encountered while performing the biometric fingerprint operation.
    • setPreEntryActivation

      public void setPreEntryActivation(byte[] param)
      Sets the activation for the pre-entry behavior. This must be called by the BroadcastReceiver when it is initialized.
      Parameters:
      param - The activation value:
      • 0x00: No activation.
      • 0x01: Activation.
    • getExistingKeyValidityPeriod

      public int getExistingKeyValidityPeriod(@NonNull android.content.Context context)
      This API is used to get the validity period of the existing key . It does not depend on SDKInitializer.initialize(Context, Notification, CustomConfiguration) or SDKInitializer.configure(Context, Notification, CustomConfiguration).

      If the key validity period is not stored, then the API will return -1. If the API returns a key validity period, you can use this value for SDK initialization, set a new key validity period or use a default value.

      For example:

           int existingKeyValidityPeriod = DeviceCVMManager.INSTANCE.getExistingKeyValidityPeriod();
           if (existingKeyValidityPeriod != -1) {
                  CustomConfiguration newCustomConfig = new CustomConfiguration.Builder()
                          .domesticCurrencyCode(250)
                          .keyValidityPeriod(existingKeyValidityPeriod)
                          .build();
                  SDKInitializer.INSTANCE.initialize(context, notification, newCustomConfig);
            } else {
                    SDKInitializer.INSTANCE.initialize(context, notification, customConfig);
            }
             
      Refer to SDKInitializer.configure(Context, Notification, CustomConfiguration) and SDKInitializer.initialize(Context, Notification, CustomConfiguration) for more information.

      Parameters:
      context - Context is used to obtain device resources.
      Returns:
      The existing key validity period or else -1 (-1 indicates there is no existing value).
      Since:
      6.7.0