c# uri.host

Uri.Equality()运算符 (Uri.Equality() Operator)

Uri.Equality() Operator is overloaded which is used to compare two Uri objects. It returns true if two Uri objects contain the same Uri otherwise it returns false.

Uri.Equality()运算符已重载,该运算符用于比较两个Uri对象。 如果两个开放的对象包含相同的URI否则返回false返回true。

Syntax:

句法:

    bool operator == (Uri uri1, Uri uri2);

Parameter(s):

参数:

  • Uri uri1 – represents the first Uri to be compared.

    Uri uri1 –表示要比较的第一个Uri。

  • Uri uri2 – represents the second Uri to be compared.

    Uri uri2 –表示要比较的第二个Uri。

Return value:

返回值:

The return type of this method is Boolean, it returns true if the Uri instances are the same; otherwise, false.

此方法的返回类型为Boolean ,如果Uri实例相同,则返回true;否则,返回true 。 否则为false

Example to demonstrate example of Uri.Equality() Operator

演示Uri.Equality()运算符示例的示例

using System;
class UriExample
{//Entry point of Program
static public void Main()
{// Create some Uri objects
Uri uri1 = new Uri("https://www.includehelp.com/");
Uri uri2 = new Uri("https://www.includehelp.com/");
Uri uri3 = new Uri("https://www.includehelp.com/index.html");
if (uri1 == uri2)
Console.WriteLine("uri1 and uri2 are equal");
else
Console.WriteLine("uri1 and uri2 are not equal");
if (uri1 == uri3)
Console.WriteLine("uri1 and uri3 are equal");
else
Console.WriteLine("uri1 and uri3 are not equal");
}
}

Output

输出量

uri1 and uri2 are equal
uri1 and uri3 are not equal

Reference: Uri.Equality(Uri, Uri) Operator

参考: Uri.Equality(Uri,Uri)运算符

翻译自: https://www.includehelp.com/dot-net/uri-equality-operator-with-example.aspx

c# uri.host

c# uri.host_C#| 具有示例的Uri.Equality()运算符相关推荐

  1. c# uri.host_C#| Uri.GetLeftPart()方法与示例

    c# uri.host Uri.GetLeftPart()方法 (Uri.GetLeftPart() Method) Uri.GetLeftPart() method is an instance m ...

  2. c# uri.host_C#| Uri.IsHexEncoding()方法与示例

    c# uri.host Uri.IsHexEncoding()方法 (Uri.IsHexEncoding() Method) Uri.IsHexEncoding() method is a stati ...

  3. c# uri.host_C#| Uri.FromHex()方法与示例

    c# uri.host Uri.FromHex()方法 (Uri.FromHex() Method) Uri.FromHex() method is a static method that retu ...

  4. c# uri.host_C#| Uri.CheckHostName()方法与示例

    c# uri.host Uri.CheckHostName()方法 (Uri.CheckHostName() Method) Uri.CheckHostName() method is a stati ...

  5. c# uri.host_C#| 具有示例的Uri.Host属性

    c# uri.host Uri.Host属性 (Uri.Host Property) Uri.Host Property is the instance property of Uri class w ...

  6. c# uri.host_C#| Uri.EscapeUriString()方法与示例

    c# uri.host Uri.EscapeUriString()方法 (Uri.EscapeUriString() Method) Uri.EscapeUriString() method is a ...

  7. c# uri.host_C#| Uri.HostNameType属性与示例

    c# uri.host Uri.HostNameType属性 (Uri.HostNameType Property) Uri.HostNameType Property is the instance ...

  8. java uri 是什么_java的URI和URL到底是什么

    在我们做开发时,经常有URI和URL弄混的问题,如果当时直接看URI和URL的源码就不可能弄混.首先我总结一下URI和URL的关系:他们的关系是:URL是一种特殊的URI,是URI包括URL, 下面用 ...

  9. URI是什么意思?URI和URL有什么区别?

    URI是什么意思?URI和URL有什么区别? 详解! HTTP = Hyper Text Transfer Protocol URI = Universal Resource Identifier U ...

最新文章

  1. CKEditor上传视频(java)
  2. 方立勋_30天掌握JavaWeb_JavaBean、mvc开发模式、el表达式、jstl标签
  3. 全国计算机等级考试题库二级C操作题100套(第76套)
  4. PhantomJS 一个隐形的浏览器
  5. 跳转,location.href,window.open(),load加载页面,iframe加载页面,兼容相关
  6. python进阶19垃圾回收GC
  7. 在linux下,为php增加mbstring扩展
  8. windows10下搭建spark平台
  9. Atitit 融合战略的艺术 目录 1.1. Os方向 uwp ms。。 1 1.2. Sdk 方向 。ms netcore 1 2. Netcore优点 1 2.1. .NET应用程序可以
  10. 数字经济时代,企业的核心竞争力究竟是什么?
  11. 计算机绘图课程选用课本,机械制图与计算机绘图 机械制图与计算机绘图 机械制图与计算机绘图课程标准.doc...
  12. [Vue warn]: Extraneous non-props attributes (style) were passed to component but could not be 警告
  13. 参考三:容易误解读的量子擦除实验
  14. Stable Diffusion Prompt用法
  15. 奇瑞QQ序列首款新能源汽车QQ冰淇淋上市;上海嘉定集中发展氢燃料电池和ICV | 能动...
  16. 64位 Eclipse IDE for Java EE Developers 下载地址
  17. 梯形波的傅里叶级数分解
  18. 【C语言】练习函数调用
  19. hexo博客的yilia主题之添加分类
  20. 宝哥说币|近期爆火的项目Trister′s Lend究竟有什么发展潜力和前景?

热门文章

  1. ASP.NET.CORE发布后启动网站出现500.19-0x8007000d错误解决方法
  2. 怎么在ReactNative里面使用Typescript
  3. 在react中使用svg的各种骚姿势
  4. 三个实用的提升网页性能技巧
  5. vue笔记(四)注册组件,路由,vuex
  6. 常用的JVM调优参数总结汇总【随时查阅学习】
  7. Fix “Windows cannot access the specified device path or file” Error
  8. VS2010 运行库设置
  9. [转]Ubuntu远程桌面登陆
  10. 广元南山隧道南河互通立交图_广元城区一隧道工程竣工时间已定,今后出行更加方便了!...