Char.ISpanFormattable.TryFormat 메서드

정의

현재 인스턴스의 값 형식을 제공된 문자 범위로 지정하려고 시도합니다.

 virtual bool System.ISpanFormattable.TryFormat(Span<char> destination, [Runtime::InteropServices::Out] int % charsWritten, ReadOnlySpan<char> format, IFormatProvider ^ provider) = ISpanFormattable::TryFormat;
bool ISpanFormattable.TryFormat (Span<char> destination, out int charsWritten, ReadOnlySpan<char> format, IFormatProvider provider);
abstract member System.ISpanFormattable.TryFormat : Span<char> * int * ReadOnlySpan<char> * IFormatProvider -> bool
override this.System.ISpanFormattable.TryFormat : Span<char> * int * ReadOnlySpan<char> * IFormatProvider -> bool
Function TryFormat (destination As Span(Of Char), ByRef charsWritten As Integer, format As ReadOnlySpan(Of Char), provider As IFormatProvider) As Boolean Implements ISpanFormattable.TryFormat

매개 변수

destination
Span<Char>

문자 범위로 서식이 지정된 이 인스턴스의 값을 쓸 범위입니다.

charsWritten
Int32

이 메서드가 반환될 경우 destination에 기록된 문자 수입니다.

format
ReadOnlySpan<Char>

destination에 허용되는 형식을 정의하는 표준 또는 사용자 지정 형식 문자열을 나타내는 문자를 포함하는 범위입니다.

provider
IFormatProvider

destination의 문화권별 형식 정보를 제공하는 선택적 개체입니다.

반환

Boolean

형식 지정에 성공했으면 true이고, 실패했으면 false입니다.

구현

적용 대상