Class BiometricsProperties.BiometricInformationRecord

java.lang.Object
de.gmxhome.conrad.jpos.jpos_base.biometrics.BiometricsProperties.BiometricInformationRecord
Enclosing class:
BiometricsProperties

public static class BiometricsProperties.BiometricInformationRecord extends Object
Helper class for Biometric Information Record (BIR) interpretation. Based on the BioAPI 1.1 reference implementation on Github.
  • Field Details

    • BiometricDataBlockOffset

      public static final int BiometricDataBlockOffset
      Offset of the Biometric Data Block (BDB), equals to the BIR header length.
      See Also:
      Constant Field Values
    • DATA_TYPE_RAW

      public static final int DATA_TYPE_RAW
      Constant for BIR data type conforming to BioAPI type RAW.
      See Also:
      Constant Field Values
    • DATA_TYPE_INTERMEDIATE

      public static final int DATA_TYPE_INTERMEDIATE
      Constant for BIR data type conforming to BioAPI type INTERMEDIATE.
      See Also:
      Constant Field Values
    • DATA_TYPE_PROCESSED

      public static final int DATA_TYPE_PROCESSED
      Constant for BIR data type conforming to BioAPI type PROCESSED.
      See Also:
      Constant Field Values
    • DATA_TYPE_ENCRYPTED

      public static final int DATA_TYPE_ENCRYPTED
      Constant for BIR data type conforming to BioAPI type ENCRYPTED.
      See Also:
      Constant Field Values
    • DATA_TYPE_SIGNED

      public static final int DATA_TYPE_SIGNED
      Constant for BIR data type conforming to BioAPI type SIGNED.
      See Also:
      Constant Field Values
    • QUALITY_NOT_SET

      public static final int QUALITY_NOT_SET
      Constant for BIR quality conforming to BioAPI type Quality.
      See Also:
      Constant Field Values
    • QUALITY_NOT_SUPPORTED

      public static final int QUALITY_NOT_SUPPORTED
      Constant for BIR quality conforming to BioAPI type Quality.
      See Also:
      Constant Field Values
    • PURPOSE_VERIFY

      public static final int PURPOSE_VERIFY
      Constant for BIR data type conforming to BioAPI purpose VERIFY.
      See Also:
      Constant Field Values
    • PURPOSE_IDENTIFY

      public static final int PURPOSE_IDENTIFY
      Constant for BIR data type conforming to BioAPI purpose IDENTIFY.
      See Also:
      Constant Field Values
    • PURPOSE_ENROLL

      public static final int PURPOSE_ENROLL
      Constant for BIR data type conforming to BioAPI purpose ENROLL.
      See Also:
      Constant Field Values
    • PURPOSE_ENROLL_FOR_VERIFICATION

      public static final int PURPOSE_ENROLL_FOR_VERIFICATION
      Constant for BIR data type conforming to BioAPI purpose ENROLL_FOR_VERIFICATION_ONLY.
      See Also:
      Constant Field Values
    • PURPOSE_ENROLL_FOR_IDENTIFICATION

      public static final int PURPOSE_ENROLL_FOR_IDENTIFICATION
      Constant for BIR data type conforming to BioAPI purpose ENROLL_FOR_IDENTIFICATION_ONLY.
      See Also:
      Constant Field Values
    • PURPOSE_AUDIT

      public static final int PURPOSE_AUDIT
      Constant for BIR data type conforming to BioAPI purpose AUDIT.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_MULTIPLE

      public static final int BIOMETRIC_TYPE_MULTIPLE
      Constant for biometric type conforming to BioAPI auth factor MULTIPLE.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_FACIAL_FEATURES

      public static final int BIOMETRIC_TYPE_FACIAL_FEATURES
      Constant for biometric type conforming to BioAPI auth factor FACIAL_FEATURES.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_VOICE

      public static final int BIOMETRIC_TYPE_VOICE
      Constant for biometric type conforming to BioAPI auth factor VOICE.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_FINGERPRINT

      public static final int BIOMETRIC_TYPE_FINGERPRINT
      Constant for biometric type conforming to BioAPI auth factor FINGERPRINT.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_IRIS

      public static final int BIOMETRIC_TYPE_IRIS
      Constant for biometric type conforming to BioAPI auth factor IRIS.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_RETINA

      public static final int BIOMETRIC_TYPE_RETINA
      Constant for biometric type conforming to BioAPI auth factor RETINA.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_HAND_GEOMETRY

      public static final int BIOMETRIC_TYPE_HAND_GEOMETRY
      Constant for biometric type conforming to BioAPI auth factor HAND_GEOMETRY.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_SIGNATURE_DYNAMICS

      public static final int BIOMETRIC_TYPE_SIGNATURE_DYNAMICS
      Constant for biometric type conforming to BioAPI auth factor SIGNATURE_DYNAMICS.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_KEYSTOKE_DYNAMICS

      public static final int BIOMETRIC_TYPE_KEYSTOKE_DYNAMICS
      Constant for biometric type conforming to BioAPI auth factor KEYSTOKE_DYNAMICS.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_LIP_MOVEMENT

      public static final int BIOMETRIC_TYPE_LIP_MOVEMENT
      Constant for biometric type conforming to BioAPI auth factor LIP_MOVEMENT.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_THERMAL_FACE_IMAGE

      public static final int BIOMETRIC_TYPE_THERMAL_FACE_IMAGE
      Constant for biometric type conforming to BioAPI auth factor THERMAL_FACE_IMAGE.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_THERMAL_HAND_IMAGE

      public static final int BIOMETRIC_TYPE_THERMAL_HAND_IMAGE
      Constant for biometric type conforming to BioAPI auth factor THERMAL_HAND_IMAGE.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_GAIT

      public static final int BIOMETRIC_TYPE_GAIT
      Constant for biometric type conforming to BioAPI auth factor GAIT.
      See Also:
      Constant Field Values
    • BIOMETRIC_TYPE_PASSWORD

      public static final int BIOMETRIC_TYPE_PASSWORD
      Constant for biometric type conforming to BioAPI auth factor PASSWORD.
      See Also:
      Constant Field Values
  • Constructor Details

    • BiometricInformationRecord

      public BiometricInformationRecord(byte[] bir)
      Constructor. Creates a BIR from byte array.
      Parameters:
      bir - Byte array representing the BIR.
    • BiometricInformationRecord

      public BiometricInformationRecord()
      Default constructor. Creates empty BIR.
  • Method Details

    • getBytes

      public byte[] getBytes()
      Extracts byte array containing the representation of the BIR as byte array, as required by UPOS Biometrics.
      Returns:
      Byte array interpretation of this object.
    • getLength

      public int getLength()
      Length getter.
      Returns:
      Length of BIR (without optional signature).
    • setLength

      public void setLength(int length) throws jpos.JposException
      Length setter. Must be at least the header size.
      Parameters:
      length - New value for Length field.
      Throws:
      jpos.JposException - if length is less than the BIR header length (16).
    • getHeaderVersion

      public int getHeaderVersion()
      Header Version getter.
      Returns:
      Header version.
    • setHeaderVersion

      public void setHeaderVersion(int version) throws jpos.JposException
      Header Version setter.
      Parameters:
      version - New version value. Must be between zero and 0xff (255).
      Throws:
      jpos.JposException - If version is out of range.
    • getBIRDataType

      public int getBIRDataType()
      BIR Data Type getter.
      Returns:
      BIR data type.
    • setBIRDataType

      public void setBIRDataType(int birDataType) throws jpos.JposException
      BIR Data Type setter.
      Parameters:
      birDataType - New birDataType value. Must be between zero and 0xff (255).
      Throws:
      jpos.JposException - If birDataType is out of range.
    • getFormatIDOwner

      public int getFormatIDOwner()
      Format ID component Owner getter.
      Returns:
      Format ID component Owner.
    • setFormatIDOwner

      public void setFormatIDOwner(int owner) throws jpos.JposException
      Format ID component Owner setter. Must be between zero and 0xffff.
      Parameters:
      owner - New value for Length field.
      Throws:
      jpos.JposException - if owner is out of range.
    • getFormatIDType

      public int getFormatIDType()
      Format ID component Type getter.
      Returns:
      Format ID component Type.
    • setFormatIDType

      public void setFormatIDType(int type) throws jpos.JposException
      Format ID component Type setter. Must be between zero and 0xffff.
      Parameters:
      type - New value for Length field.
      Throws:
      jpos.JposException - if type is out of range.
    • getQuality

      public int getQuality()
      Quality getter.
      Returns:
      Quality.
    • setQuality

      public void setQuality(int quality) throws jpos.JposException
      Quality setter.
      Parameters:
      quality - New quality value. Must be between -100 (lowest quality) and 100 (highest quality) or one of QUALITY_NOT_SET or QUALITY_NOT_SUPPORTED.
      Throws:
      jpos.JposException - If quality is out of range.
    • getPurpose

      public int getPurpose()
      Purpose getter.
      Returns:
      Purpose.
    • setPurpose

      public void setPurpose(int purpose) throws jpos.JposException
      Purpose setter.
      Parameters:
      purpose - New purpose value. Must be between zero and 0xff (255).
      Throws:
      jpos.JposException - If purpose is out of range.
    • getBiometricType

      public int getBiometricType()
      Biometric Type getter.
      Returns:
      Biometric type.
    • setBiometricType

      public void setBiometricType(int biometricType)
      Biometric Type setter.
      Parameters:
      biometricType - New value for Length field.
    • getBiometricDataBlock

      public byte[] getBiometricDataBlock()
      Retrieves the biometric data block.
      Returns:
      The biometric data block, if the BIR contains a biometric data block, null if the BIR is empty or if the Length field of the BIR is invalid (less than header size, greater than BIR size).
    • setBiometricDataBlock

      public void setBiometricDataBlock(byte[] bdb)
      Sets the biometric data block
      Parameters:
      bdb - Biometric data block
    • addSignature

      public void addSignature(byte[] signature)
      Add signature to biometric properties.
      Parameters:
      signature - Any device specific signature data.