82 references to ParsingError
System.Private.Uri (82)
System\Uri.cs (66)
659ParsingError error = ParsingError.None; 662if (error == ParsingError.None) 698private static UriFormatException? GetException(ParsingError err) 702case ParsingError.None: 705case ParsingError.BadFormat: 707case ParsingError.BadScheme: 709case ParsingError.BadAuthority: 711case ParsingError.EmptyUriString: 714case ParsingError.SchemeLimit: 716case ParsingError.MustRootedPath: 719case ParsingError.BadHostName: 721case ParsingError.NonEmptyHost: //unix-only 723case ParsingError.BadPort: 725case ParsingError.BadAuthorityTerminator: 727case ParsingError.CannotCreateRelative: 1956private static ParsingError ParseScheme(string uriString, ref Flags flags, ref UriParser? syntax) 1962return ParsingError.EmptyUriString; 1978ParsingError err = ParsingError.None; 1980Debug.Assert((err is ParsingError.None) == (syntax is not null)); 1982if (err != ParsingError.None) 1988return ParsingError.None; 2002ParsingError result = PrivateParseMinimal(); 2003if (result == ParsingError.None) 2023private unsafe ParsingError PrivateParseMinimal() 2054return ParsingError.None; 2092return ParsingError.MustRootedPath; 2153return ParsingError.BadAuthority; 2173return ParsingError.None; 2178return ParsingError.BadAuthority; 2191return ParsingError.None; 2201return ParsingError.None; 2212ParsingError err = ParsingError.None; 2216if (err != ParsingError.None) 2226return ParsingError.BadAuthorityTerminator; 2249return ParsingError.None; 2608throw GetException(ParsingError.BadHostName)!; 2632ParsingError err = ParsingError.None; 2647if (err != ParsingError.None || (flags & Flags.HostTypeMask) == Flags.UnknownHostType) 3653private static int ParseSchemeCheckImplicitFile(string uriString, ref ParsingError err, ref Flags flags, ref UriParser? syntax) 3655Debug.Assert(err == ParsingError.None); 3688err = ParsingError.BadFormat; 3706err = ParsingError.MustRootedPath; 3710err = uriString[i + 1] == ':' ? ParsingError.BadScheme : ParsingError.BadFormat; 3731err = ParsingError.BadFormat; 3737err = ParsingError.BadFormat; 3752private static UriParser? CheckSchemeSyntax(ReadOnlySpan<char> scheme, ref ParsingError error) 3754Debug.Assert(error == ParsingError.None); 3800error = ParsingError.BadScheme; 3806error = ParsingError.SchemeLimit; 3822ref ParsingError err, ref Flags flags, UriParser syntax, ref string? newHost) 3849err = ParsingError.BadHostName; 3854err = ParsingError.BadHostName; 3958err = ParsingError.BadHostName; 3996err = ParsingError.BadPort; 4010err = ParsingError.BadPort; 4053err = ParsingError.BadHostName; 4080err = ParsingError.BadHostName; 4097err = ParsingError.BadFormat; 4105err = ParsingError.BadHostName; 4116ref string? newHost, ref ParsingError err) 4137err = ParsingError.BadHostName;
System\UriExt.cs (16)
39ParsingError err = ParseScheme(_string, ref _flags, ref _syntax!); 46private void InitializeUri(ParsingError err, UriKind uriKind, out UriFormatException? e) 50if (err == ParsingError.None) 83else if (err > ParsingError.LastErrorOkayForRelativeUris) 105if ((err = PrivateParseMinimal()) != ParsingError.None) 107if (uriKind != UriKind.Absolute && err <= ParsingError.LastErrorOkayForRelativeUris) 121e = GetException(ParsingError.CannotCreateRelative); 155if (uriKind != UriKind.Absolute && err != ParsingError.None 156&& err <= ParsingError.LastErrorOkayForRelativeUris) 165if (err != ParsingError.None || InFact(Flags.ErrorOrParsingRecursion)) 175e = GetException(ParsingError.CannotCreateRelative); 197else if (err != ParsingError.None && uriKind != UriKind.Absolute 198&& err <= ParsingError.LastErrorOkayForRelativeUris) 759ParsingError err = ParseScheme(uriString, ref flags, ref syntax); 768if (err != ParsingError.None) 771if (uriKind != UriKind.Absolute && err <= ParsingError.LastErrorOkayForRelativeUris)