toJson method

Map<String, Object> toJson ()

Implementation

core.Map<core.String, core.Object> toJson() {
  final core.Map<core.String, core.Object> _json =
      new core.Map<core.String, core.Object>();
  if (creationTimestamp != null) {
    _json["creationTimestamp"] = creationTimestamp;
  }
  if (description != null) {
    _json["description"] = description;
  }
  if (enableFlowLogs != null) {
    _json["enableFlowLogs"] = enableFlowLogs;
  }
  if (fingerprint != null) {
    _json["fingerprint"] = fingerprint;
  }
  if (gatewayAddress != null) {
    _json["gatewayAddress"] = gatewayAddress;
  }
  if (id != null) {
    _json["id"] = id;
  }
  if (ipCidrRange != null) {
    _json["ipCidrRange"] = ipCidrRange;
  }
  if (ipv6CidrRange != null) {
    _json["ipv6CidrRange"] = ipv6CidrRange;
  }
  if (kind != null) {
    _json["kind"] = kind;
  }
  if (logConfig != null) {
    _json["logConfig"] = (logConfig).toJson();
  }
  if (name != null) {
    _json["name"] = name;
  }
  if (network != null) {
    _json["network"] = network;
  }
  if (privateIpGoogleAccess != null) {
    _json["privateIpGoogleAccess"] = privateIpGoogleAccess;
  }
  if (privateIpv6GoogleAccess != null) {
    _json["privateIpv6GoogleAccess"] = privateIpv6GoogleAccess;
  }
  if (purpose != null) {
    _json["purpose"] = purpose;
  }
  if (region != null) {
    _json["region"] = region;
  }
  if (role != null) {
    _json["role"] = role;
  }
  if (secondaryIpRanges != null) {
    _json["secondaryIpRanges"] =
        secondaryIpRanges.map((value) => (value).toJson()).toList();
  }
  if (selfLink != null) {
    _json["selfLink"] = selfLink;
  }
  if (state != null) {
    _json["state"] = state;
  }
  return _json;
}