With the URI type is serialized to string, you can only do direct comparison (equal/not equal) whereas in C#, the type has various more properties like scheme, host, path etc. Because of this, you can't do many useful queries against this type, making it kinda useless to even support serialization of the Uri type.
For example, take the following class:
Unable to find source-code formatter for language: csharp. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
class ExampleClass { public string Id { get; set; } public Uri WebsiteUri { get; set; } }
I can't query it like:
Unable to find source-code formatter for language: csharp. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
myCollection.AsQueryable().Where(e => e.WebsiteUri.Host == "somedomain.com");
Because
InvalidOperationException: {document}{WebsiteUri}.Host is not supported.
I can only do this:
Unable to find source-code formatter for language: csharp. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
myCollection.AsQueryable().Where(e => e.WebsiteUri == new Uri("http://somedomain.com/some-page"));