RevisionResponse constructor

RevisionResponse({
  1. Kref? kref,
  2. Kref? itemKref,
  3. int? number,
  4. Iterable<String>? tags,
  5. Iterable<MapEntry<String, String>>? metadata,
  6. String? createdAt,
  7. String? modifiedAt,
  8. String? author,
  9. bool? deprecated,
  10. bool? published,
  11. bool? latest,
  12. String? username,
  13. String? defaultArtifact,
  14. String? name,
})

Implementation

factory RevisionResponse({
  Kref? kref,
  Kref? itemKref,
  $core.int? number,
  $core.Iterable<$core.String>? tags,
  $core.Iterable<$core.MapEntry<$core.String, $core.String>>? metadata,
  $core.String? createdAt,
  $core.String? modifiedAt,
  $core.String? author,
  $core.bool? deprecated,
  $core.bool? published,
  $core.bool? latest,
  $core.String? username,
  $core.String? defaultArtifact,
  $core.String? name,
}) {
  final result = create();
  if (kref != null) result.kref = kref;
  if (itemKref != null) result.itemKref = itemKref;
  if (number != null) result.number = number;
  if (tags != null) result.tags.addAll(tags);
  if (metadata != null) result.metadata.addEntries(metadata);
  if (createdAt != null) result.createdAt = createdAt;
  if (modifiedAt != null) result.modifiedAt = modifiedAt;
  if (author != null) result.author = author;
  if (deprecated != null) result.deprecated = deprecated;
  if (published != null) result.published = published;
  if (latest != null) result.latest = latest;
  if (username != null) result.username = username;
  if (defaultArtifact != null) result.defaultArtifact = defaultArtifact;
  if (name != null) result.name = name;
  return result;
}