GetHealthCheckResult.fromMap constructor

GetHealthCheckResult.fromMap(
  1. Map<String, dynamic> map
)

Implementation

factory GetHealthCheckResult.fromMap(Map<String, dynamic> map) {
  return GetHealthCheckResult(
    checkIntervalSec: map['checkIntervalSec'] as int,
    creationTimestamp: map['creationTimestamp'] as String,
    description: map['description'] as String,
    grpcHealthCheck: GRPCHealthCheckResponse.fromMap((map['grpcHealthCheck']! as Map).cast<String, dynamic>()),
    healthyThreshold: map['healthyThreshold'] as int,
    http2HealthCheck: HTTP2HealthCheckResponse.fromMap((map['http2HealthCheck']! as Map).cast<String, dynamic>()),
    httpHealthCheck: HTTPHealthCheckResponse.fromMap((map['httpHealthCheck']! as Map).cast<String, dynamic>()),
    httpsHealthCheck: HTTPSHealthCheckResponse.fromMap((map['httpsHealthCheck']! as Map).cast<String, dynamic>()),
    kind: map['kind'] as String,
    logConfig: HealthCheckLogConfigResponse.fromMap((map['logConfig']! as Map).cast<String, dynamic>()),
    name: map['name'] as String,
    region: map['region'] as String,
    selfLink: map['selfLink'] as String,
    selfLinkWithId: map['selfLinkWithId'] as String,
    sourceRegions: (map['sourceRegions'] as List).cast<String>(),
    sslHealthCheck: SSLHealthCheckResponse.fromMap((map['sslHealthCheck']! as Map).cast<String, dynamic>()),
    tcpHealthCheck: TCPHealthCheckResponse.fromMap((map['tcpHealthCheck']! as Map).cast<String, dynamic>()),
    timeoutSec: map['timeoutSec'] as int,
    type: map['type'] as String,
    udpHealthCheck: UDPHealthCheckResponse.fromMap((map['udpHealthCheck']! as Map).cast<String, dynamic>()),
    unhealthyThreshold: map['unhealthyThreshold'] as int,
  );
}