ConfigurableDriversLicense

class ConfigurableDriversLicense(sdkConfig: SdkConfigInterface, seed: Long, pinSetting: Boolean? = null, driversLicensePIN1: String? = null, driversLicensePIN2: String? = null, name: String? = null, nameKana: String? = null, aliasName: String? = null, unifiedName: String? = null, dateOfBirth: String? = null, address: String? = null, dateOfIssue: String? = null, referenceNumber: String? = null, driverClass: DriverClass? = null, dateOfExpiration: String? = null, licenseRestrictions: String? = null, publicSafetyCommission: String? = null, driversLicenseNumber: String? = null, dateOfAcquisition: LicenseCategory? = null, registeredDomicile: String? = null, faceImage: ByteArray? = null) : MockDriversLicense

格納されるデータを設定可能な疑似免許証を表すMockDriversLicenseを実装したクラス

このクラスのインスタンスをMockCardSupplier.getCardの返却値とするようなMockCardSupplierを作成し、 ReaderSession.registerMockCardSupplierを使用してセッションに設定することでモック環境で生成するカード情報を設定できます。 氏名、住所、生年月日、顔写真などを設定できます。

暗証番号の設定

引数の driversLicensePIN1driversLicensePIN2 で設定した暗証番号が設定されます。 これらを指定していない場合、引数の pinSetting によってデフォルト値が異なります。

  • 引数の pinSetting が 設定されていない、もしくは、trueの場合、PIN1、PIN2の両方に "1234" が設定されます。

  • 引数の pinSetting が false の場合、PIN1、PIN2の両方に "****" が設定されます。

年月日のフォーマット

生年月日や交付年月日など、年月日を指定する箇所では、半角数字7桁で年月日を指定します。 フォーマットは「(元号)YYMMDD」で、元号は以下のように半角数字に変換されます。

  • 令和:"5"

  • 平成:"4"

  • 昭和:"3"

  • 大正:"2"

  • 明治:"1"

交付日、有効期限の設定

有効期限の末日は、引数の dateOfExpiration によって設定できます。 交付日 dateOfIssue のみを指定した場合、末日は dateOfIssue の5年後に設定されます。 dateOfExpiration のみを指定した場合、交付日は dateOfExpiration の5年前に設定されます。

免許の条件の設定

引数の licenseRestrictions によって免許の条件を設定できます。 引数に渡された文字列は改行 "\n" で分割され、分割された文字列ごとに「免許の条件」に格納されます。

外字、欠字の設定

引数の文字列に\uE000~\uE006を設定すると、それぞれ外字を表すバイト列0xFFF1~0xFFF7として読み出されます。 また、\uFFFDを設定すると、欠字を表すバイト列0xFFFAとして読み出されます。

顔写真の設定

引数の faceImage によって顔写真を設定できます。 設定するデータは JPEG 2000フォーマットの白黒写真で、データサイズは2000バイト以下にしてください。

Parameters

sdkConfig

SDK設定

seed

乱数のシード

pinSetting

暗証番号設定

driversLicensePIN1

暗証番号1(PIN 1)

driversLicensePIN2

暗証番号2(PIN 2)

name

氏名

nameKana

呼び名(カナ)

aliasName

通称名

unifiedName

統一氏名(カナ)

dateOfBirth

生年月日

address

住所

dateOfIssue

交付年月日

referenceNumber

照会番号

driverClass

免許証の色区分

dateOfExpiration

有効期間の末日

licenseRestrictions

免許の条件

publicSafetyCommission

公安委員会名

driversLicenseNumber

免許証の番号

dateOfAcquisition

免許の年月日

registeredDomicile

本籍

faceImage

写真

Constructors

Link copied to clipboard
constructor(sdkConfig: SdkConfigInterface, seed: Long, pinSetting: Boolean? = null, driversLicensePIN1: String? = null, driversLicensePIN2: String? = null, name: String? = null, nameKana: String? = null, aliasName: String? = null, unifiedName: String? = null, dateOfBirth: String? = null, address: String? = null, dateOfIssue: String? = null, referenceNumber: String? = null, driverClass: DriverClass? = null, dateOfExpiration: String? = null, licenseRestrictions: String? = null, publicSafetyCommission: String? = null, driversLicenseNumber: String? = null, dateOfAcquisition: LicenseCategory? = null, registeredDomicile: String? = null, faceImage: ByteArray? = null)

テナントIDを引数により指定してConfigurableDriversLicenseを生成する

constructor(context: ERROR CLASS: Symbol not found for Context, seed: Long, pinSetting: Boolean? = null, driversLicensePIN1: String? = null, driversLicensePIN2: String? = null, name: String? = null, nameKana: String? = null, aliasName: String? = null, unifiedName: String? = null, dateOfBirth: String? = null, address: String? = null, dateOfIssue: String? = null, referenceNumber: String? = null, driverClass: DriverClass? = null, dateOfExpiration: String? = null, licenseRestrictions: String? = null, publicSafetyCommission: String? = null, driversLicenseNumber: String? = null, dateOfAcquisition: LicenseCategory? = null, registeredDomicile: String? = null, faceImage: ByteArray? = null)

テナントIDを設定ファイルにより取得してConfigurableDriversLicenseを生成する

Properties

Link copied to clipboard
open override val commonData: ByteArray

共通データ要素を読み出すときに参照される値

Link copied to clipboard
open override val pinSetting: ByteArray

暗証番号(PIN)設定を読み出すときに参照される値

Functions

Link copied to clipboard
open override fun selectDF1(): MockDriversLicense.DF1

SELECT コマンドでDF1を選択したときに実行される関数

Link copied to clipboard
open override fun selectDF2(): MockDriversLicense.DF2

SELECT コマンドでDF1を選択したときに実行される関数

Link copied to clipboard
open override fun verifyDriversLicensePIN1(password: String)

入力が暗証番号1と一致するかを検査する関数

Link copied to clipboard
open override fun verifyDriversLicensePIN2(password: String)

入力が暗証番号2と一致するかを検査する関数