Map<String, dynamic> toMap() { return { "username": username, "password": password, "iosCertificates": iosCertificates?.map((e) => e.toMap()).toList(), "iosPersistence": iosPersistence?.toValue(), }; }