Uri constructor

Uri({
  1. Uri_Protocol? protocol,
  2. Uri_Authorization? auth,
  3. String? host,
  4. String? port,
  5. String? path,
  6. Iterable<Uri_QueryParameter>? query,
  7. String? fragment,
})

Implementation

factory Uri({
  Uri_Protocol? protocol,
  Uri_Authorization? auth,
  $core.String? host,
  $core.String? port,
  $core.String? path,
  $core.Iterable<Uri_QueryParameter>? query,
  $core.String? fragment,
}) {
  final _result = create();
  if (protocol != null) {
    _result.protocol = protocol;
  }
  if (auth != null) {
    _result.auth = auth;
  }
  if (host != null) {
    _result.host = host;
  }
  if (port != null) {
    _result.port = port;
  }
  if (path != null) {
    _result.path = path;
  }
  if (query != null) {
    _result.query.addAll(query);
  }
  if (fragment != null) {
    _result.fragment = fragment;
  }
  return _result;
}