語言

IPNetwork.TryFormat 方法

定義

多載

名稱 Description
TryFormat(Span<Char>, Int32)

嘗試將 的 CIDR 符號寫 IPNetwork入給定 destination 的區間,並回傳一個值表示操作是否成功。

TryFormat(Span<Byte>, Int32)

嘗試將 的 CIDR 符號寫 IPNetwork入給定 utf8Destination 的 UTF-8 範圍,並回傳一個值以表示操作是否成功。

TryFormat(Span<Char>, Int32)

來源:
IPNetwork.cs
來源:
IPNetwork.cs
來源:
IPNetwork.cs
來源:
IPNetwork.cs

嘗試將 的 CIDR 符號寫 IPNetwork入給定 destination 的區間,並回傳一個值表示操作是否成功。

public:
 bool TryFormat(Span<char> destination, [Runtime::InteropServices::Out] int % charsWritten);
public bool TryFormat(Span<char> destination, out int charsWritten);
member this.TryFormat : Span<char> * int -> bool
Public Function TryFormat (destination As Span(Of Char), ByRef charsWritten As Integer) As Boolean

參數

destination
Span<Char>

角色的目的地範圍。

charsWritten
Int32

當此方法返回時,包含寫入 destination的字元數。

傳回

true 如果格式化成功;否則 false。

適用於

TryFormat(Span<Byte>, Int32)

來源:
IPNetwork.cs
來源:
IPNetwork.cs
來源:
IPNetwork.cs
來源:
IPNetwork.cs

嘗試將 的 CIDR 符號寫 IPNetwork入給定 utf8Destination 的 UTF-8 範圍,並回傳一個值以表示操作是否成功。

public:
 bool TryFormat(Span<System::Byte> utf8Destination, [Runtime::InteropServices::Out] int % bytesWritten);
public bool TryFormat(Span<byte> utf8Destination, out int bytesWritten);
member this.TryFormat : Span<byte> * int -> bool
Public Function TryFormat (utf8Destination As Span(Of Byte), ByRef bytesWritten As Integer) As Boolean

參數

utf8Destination
Span<Byte>

UTF-8 位元組的目的地範圍。

bytesWritten
Int32

當此方法回傳時,包含寫入的 utf8Destination位元組數。

傳回

true 如果格式化成功;否則 false。

適用於