IngressTLS.fromJson constructor

IngressTLS.fromJson(
  1. Map<String, dynamic> json
)

Creates a IngressTLS from JSON data.

Implementation

factory IngressTLS.fromJson(Map<String, dynamic> json) {
  final tempHostsJson = json['hosts'];
  final tempSecretNameJson = json['secretName'];

  final List<String>? tempHosts =
      tempHostsJson != null ? List<String>.from(tempHostsJson) : null;
  final String? tempSecretName = tempSecretNameJson;

  return IngressTLS(
    hosts: tempHosts,
    secretName: tempSecretName,
  );
}