UriBuilder UriBuilder UriBuilder UriBuilder Class

定義

提供統一資源識別元 (URI) 的自訂建構函式,並修改 Uri 類別的 URI。 Provides a custom constructor for uniform resource identifiers (URIs) and modifies URIs for the Uri class.

public ref class UriBuilder
public class UriBuilder
type UriBuilder = class
Public Class UriBuilder
繼承
UriBuilderUriBuilderUriBuilderUriBuilder

備註

UriBuilder類別會提供便利的方式來修改內容Uri而不需要建立新的執行個體Uri每一項修改的執行個體。The UriBuilder class provides a convenient way to modify the contents of a Uri instance without creating a new Uri instance for each modification.

UriBuilder屬性會提供讀取/寫入存取權的唯讀Uri屬性,以便它們可以修改。The UriBuilder properties provide read/write access to the read-only Uri properties so that they can be modified.

建構函式

UriBuilder() UriBuilder() UriBuilder() UriBuilder()

初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class.

UriBuilder(String) UriBuilder(String) UriBuilder(String) UriBuilder(String)

使用指定的 URI,初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified URI.

UriBuilder(String, String) UriBuilder(String, String) UriBuilder(String, String) UriBuilder(String, String)

使用指定的配置和主機,初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified scheme and host.

UriBuilder(String, String, Int32) UriBuilder(String, String, Int32) UriBuilder(String, String, Int32) UriBuilder(String, String, Int32)

使用指定的配置、主機和連接埠,初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified scheme, host, and port.

UriBuilder(String, String, Int32, String) UriBuilder(String, String, Int32, String) UriBuilder(String, String, Int32, String) UriBuilder(String, String, Int32, String)

使用指定的配置、主機、連接埠編號和路徑,初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified scheme, host, port number, and path.

UriBuilder(String, String, Int32, String, String) UriBuilder(String, String, Int32, String, String) UriBuilder(String, String, Int32, String, String) UriBuilder(String, String, Int32, String, String)

使用指定的配置、主機、連接埠編號、路徑和查詢字串或片段識別項,初始化 UriBuilder 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified scheme, host, port number, path and query string or fragment identifier.

UriBuilder(Uri) UriBuilder(Uri) UriBuilder(Uri) UriBuilder(Uri)

使用指定的 UriBuilder 執行個體,初始化 Uri 類別的新執行個體。 Initializes a new instance of the UriBuilder class with the specified Uri instance.

屬性

Fragment Fragment Fragment Fragment

取得或設定 URI 的片段部分。 Gets or sets the fragment portion of the URI.

Host Host Host Host

取得或設定伺服器的網域名稱系統 (DNS) 主機名稱或 IP 位址。 Gets or sets the Domain Name System (DNS) host name or IP address of a server.

Password Password Password Password

取得或設定存取 URI 之使用者的相關密碼。 Gets or sets the password associated with the user that accesses the URI.

Path Path Path Path

取得或設定 URI 參考的資源路徑。 Gets or sets the path to the resource referenced by the URI.

Port Port Port Port

取得或設定 URI 的連接埠編號。 Gets or sets the port number of the URI.

Query Query Query Query

取得或設定 URI 所包含的任何查詢資訊。 Gets or sets any query information included in the URI.

Scheme Scheme Scheme Scheme

取得或設定 URI 的配置名稱。 Gets or sets the scheme name of the URI.

Uri Uri Uri Uri

取得指定的 UriBuilder 執行個體建構的 Uri 執行個體 。 Gets the Uri instance constructed by the specified UriBuilder instance.

UserName UserName UserName UserName

存取 URI 之使用者的相關使用者名稱。 The user name associated with the user that accesses the URI.

方法

Equals(Object) Equals(Object) Equals(Object) Equals(Object)

比較現有的 Uri 執行個體和 UriBuilder 的內容,檢查是否相等。 Compares an existing Uri instance with the contents of the UriBuilder for equality.

GetHashCode() GetHashCode() GetHashCode() GetHashCode()

傳回 URI 的雜湊碼。 Returns the hash code for the URI.

GetType() GetType() GetType() GetType()

取得目前執行個體的 Type Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

建立目前 Object 的淺層複本 (Shallow Copy)。 Creates a shallow copy of the current Object.

(Inherited from Object)
ToString() ToString() ToString() ToString()

傳回所指定 UriBuilder 執行個體的顯示字串。 Returns the display string for the specified UriBuilder instance.

適用於

另請參閱