toDataKeyPairSpec method
Implementation
DataKeyPairSpec toDataKeyPairSpec() {
switch (this) {
case 'RSA_2048':
return DataKeyPairSpec.rsa_2048;
case 'RSA_3072':
return DataKeyPairSpec.rsa_3072;
case 'RSA_4096':
return DataKeyPairSpec.rsa_4096;
case 'ECC_NIST_P256':
return DataKeyPairSpec.eccNistP256;
case 'ECC_NIST_P384':
return DataKeyPairSpec.eccNistP384;
case 'ECC_NIST_P521':
return DataKeyPairSpec.eccNistP521;
case 'ECC_SECG_P256K1':
return DataKeyPairSpec.eccSecgP256k1;
}
throw Exception('$this is not known in enum DataKeyPairSpec');
}