QueuedResource.fromJson constructor

QueuedResource.fromJson(
  1. Map json_
)

Implementation

QueuedResource.fromJson(core.Map json_)
    : this(
        createTime: json_.containsKey('createTime')
            ? json_['createTime'] as core.String
            : null,
        guaranteed: json_.containsKey('guaranteed')
            ? Guaranteed.fromJson(
                json_['guaranteed'] as core.Map<core.String, core.dynamic>)
            : null,
        name: json_.containsKey('name') ? json_['name'] as core.String : null,
        queueingPolicy: json_.containsKey('queueingPolicy')
            ? QueueingPolicy.fromJson(json_['queueingPolicy']
                as core.Map<core.String, core.dynamic>)
            : null,
        reservationName: json_.containsKey('reservationName')
            ? json_['reservationName'] as core.String
            : null,
        spot: json_.containsKey('spot')
            ? Spot.fromJson(
                json_['spot'] as core.Map<core.String, core.dynamic>)
            : null,
        state: json_.containsKey('state')
            ? QueuedResourceState.fromJson(
                json_['state'] as core.Map<core.String, core.dynamic>)
            : null,
        tpu: json_.containsKey('tpu')
            ? Tpu.fromJson(
                json_['tpu'] as core.Map<core.String, core.dynamic>)
            : null,
      );