toJson method

  1. @override
Object toJson()

Implementation

@override
Object toJson() => {
  'accessMode': ?accessMode,
  'architecture': ?architecture,
  'asyncPrimaryDisk': ?asyncPrimaryDisk?.toJson(),
  if (asyncSecondaryDisks.isNotDefault)
    'asyncSecondaryDisks': {
      for (final e in asyncSecondaryDisks.entries) e.key: e.value.toJson(),
    },
  'creationTimestamp': ?creationTimestamp,
  'description': ?description,
  'diskEncryptionKey': ?diskEncryptionKey?.toJson(),
  'enableConfidentialCompute': ?enableConfidentialCompute,
  if (guestOsFeatures.isNotDefault)
    'guestOsFeatures': [for (final i in guestOsFeatures) i.toJson()],
  'id': ?id?.toString(),
  'kind': ?kind,
  'labelFingerprint': ?labelFingerprint,
  if (labels.isNotDefault) 'labels': labels,
  'lastAttachTimestamp': ?lastAttachTimestamp,
  'lastDetachTimestamp': ?lastDetachTimestamp,
  if (licenseCodes.isNotDefault)
    'licenseCodes': [for (final i in licenseCodes) i.toString()],
  if (licenses.isNotDefault) 'licenses': licenses,
  'locationHint': ?locationHint,
  'name': ?name,
  'options': ?options,
  'params': ?params?.toJson(),
  'physicalBlockSizeBytes': ?physicalBlockSizeBytes?.toString(),
  'provisionedIops': ?provisionedIops?.toString(),
  'provisionedThroughput': ?provisionedThroughput?.toString(),
  'region': ?region,
  if (replicaZones.isNotDefault) 'replicaZones': replicaZones,
  if (resourcePolicies.isNotDefault) 'resourcePolicies': resourcePolicies,
  'resourceStatus': ?resourceStatus?.toJson(),
  'satisfiesPzi': ?satisfiesPzi,
  'satisfiesPzs': ?satisfiesPzs,
  'selfLink': ?selfLink,
  'sizeGb': ?sizeGb?.toString(),
  'sourceConsistencyGroupPolicy': ?sourceConsistencyGroupPolicy,
  'sourceConsistencyGroupPolicyId': ?sourceConsistencyGroupPolicyId,
  'sourceDisk': ?sourceDisk,
  'sourceDiskId': ?sourceDiskId,
  'sourceImage': ?sourceImage,
  'sourceImageEncryptionKey': ?sourceImageEncryptionKey?.toJson(),
  'sourceImageId': ?sourceImageId,
  'sourceInstantSnapshot': ?sourceInstantSnapshot,
  'sourceInstantSnapshotId': ?sourceInstantSnapshotId,
  'sourceSnapshot': ?sourceSnapshot,
  'sourceSnapshotEncryptionKey': ?sourceSnapshotEncryptionKey?.toJson(),
  'sourceSnapshotId': ?sourceSnapshotId,
  'sourceStorageObject': ?sourceStorageObject,
  'status': ?status,
  'storagePool': ?storagePool,
  'type': ?type,
  if (users.isNotDefault) 'users': users,
  'zone': ?zone,
};