DatosDNIe.fromJson constructor

DatosDNIe.fromJson(
  1. Map? json
)

Implementation

DatosDNIe.fromJson(Map? json)
{
 this.nif = json?["nif"];
 this.nombreCompleto = json?["nombreCompleto"];
 this.nombre = json?["nombre"];
 this.apellido1 = json?["apellido1"];
 this.apellido2 = json?["apellido2"];
 this.firma = json?["firma"] ?? "";
 this.imagen = json?["imagen"];
 this.fechaNacimiento = json?["fechaNacimiento"];
 this.provinciaNacimiento = json?["provinciaNacimiento"] ?? "";
 this.municipioNacimiento = json?["municipioNacimiento"] ?? "";
 this.nombrePadre = json?["nombrePadre"] ?? "";
 this.nombreMadre = json?["nombreMadre"] ?? "";
 this.fechaValidez = json?["fechaValidez"] ?? "";
 this.emisor = json?["emisor"] ?? "";
 this.nacionalidad = json?["nacionalidad"] ?? "";
 this.sexo = json?["sexo"] ?? "";
 this.direccion = json?["direccion"] ?? "";
 this.provinciaActual = json?["provinciaActual"] ?? "";
 this.municipioActual = json?["municipioActual"] ?? "";
 this.numSoporte = json?["numSoporte"] ?? "";
 this.certificadoAutenticacion = DatosCertificado.fromJson(json?["certificadoAutenticacion"]);
 this.certificadoFirma = DatosCertificado.fromJson(json?["certificadoFirma"]);
 this.certificadoCA = DatosCertificado.fromJson(json?["certificadoCA"]);
 this.integridadDocumento = json?["integridadDocumento"] ?? false;
 this.pemCertificadoFirmaSOD = json?["pemCertificadoFirmaSOD"] ?? "";
 this.datosICAO  = DatosICAO.fromJson(json?["datosICAO"]);
 this.can = json?["can"] ?? "";

 if(json?["erroresVerificacion"] != null && !json?["erroresVerificacion"].isEmpty)
 {
    List<Object?> lista = json?["erroresVerificacion"];
    for (var element in lista) {
      this.erroresVerificacion.add(element as String);
    }
 }
}