src/Shared/EntityFramework/Core/SchemaObjectModel/SchemaManager.cs
// <summary>
// Checks if the xml reader has base uri. If it doesn't have, it adds error, other
// returns the location from the base uri
// </summary>
Checks if the xml reader has base uri. If it doesn't have, it adds error, other
returns the location from the base uri
Checks if the xml reader has base uri . If it doesn ' t have it adds error other returns the location from the base uri
internal static bool TryGetBaseUri(XmlReader xmlReader, out string location)
        {
            var baseUri = xmlReader.BaseURI;
            Uri uri = null;
            if (!string.IsNullOrEmpty(baseUri)
                &&
                Uri.TryCreate(baseUri, UriKind.Absolute, out uri)
                &&
                uri.Scheme == "file")
            {
                location = Helper.GetFileNameFromUri(uri);
                return true;
            }
            else
            {
                location = null;
                return false;
            }
        }
internal static bool TryGetBaseUri ( XmlReader xmlReader , out string location ) { var baseUri = xmlReader . BaseURI ; Uri uri = null ; if ( ! string . IsNullOrEmpty ( baseUri ) && Uri . TryCreate ( baseUri , UriKind . Absolute , out uri ) && uri . Scheme == " " ) { location = Helper . GetFileNameFromUri ( uri ) ; return true ; } else { location = null ; return false ; } }
Checks if the xml reader has base uri.
Checks if the xml reader has base uri .
xmlReader
XmlReader
string
out