uri class : Authority getter

Description

Gets the DNS host name or IP address and the port number for a server.

Syntax

uriInstance.Authority

Arguments

None.

Return value

ClassDescription
stringThe DNS host name or IP address and the port number for a server.

Sample code

1:

uri u = new uri("http://www.example.com/aaa/bbb.html");

2:

string absolutePath = u.Authority;

Notes

It's a wrapper of the System.Uri.Authority property.

Links for reference

Copyright © Cooker All rights reserved.