Swagger constructor

Swagger({
  1. String? swagger,
  2. Info? info,
  3. String? host,
  4. String? basePath,
  5. Iterable<Scheme>? schemes,
  6. Iterable<String>? consumes,
  7. Iterable<String>? produces,
  8. Map<String, Response>? responses,
  9. SecurityDefinitions? securityDefinitions,
  10. Iterable<SecurityRequirement>? security,
  11. ExternalDocumentation? externalDocs,
  12. Map<String, Value>? extensions,
})

Implementation

factory Swagger({
  $core.String? swagger,
  Info? info,
  $core.String? host,
  $core.String? basePath,
  $core.Iterable<Scheme>? schemes,
  $core.Iterable<$core.String>? consumes,
  $core.Iterable<$core.String>? produces,
  $core.Map<$core.String, Response>? responses,
  SecurityDefinitions? securityDefinitions,
  $core.Iterable<SecurityRequirement>? security,
  ExternalDocumentation? externalDocs,
  $core.Map<$core.String, $3.Value>? extensions,
}) {
  final _result = create();
  if (swagger != null) {
    _result.swagger = swagger;
  }
  if (info != null) {
    _result.info = info;
  }
  if (host != null) {
    _result.host = host;
  }
  if (basePath != null) {
    _result.basePath = basePath;
  }
  if (schemes != null) {
    _result.schemes.addAll(schemes);
  }
  if (consumes != null) {
    _result.consumes.addAll(consumes);
  }
  if (produces != null) {
    _result.produces.addAll(produces);
  }
  if (responses != null) {
    _result.responses.addAll(responses);
  }
  if (securityDefinitions != null) {
    _result.securityDefinitions = securityDefinitions;
  }
  if (security != null) {
    _result.security.addAll(security);
  }
  if (externalDocs != null) {
    _result.externalDocs = externalDocs;
  }
  if (extensions != null) {
    _result.extensions.addAll(extensions);
  }
  return _result;
}