Camera.IFormattable.ToString(String, IFormatProvider) 方法

定义

使用指定格式对当前实例的值设置格式。Formats the value of the current instance using the specified format.

 virtual System::String ^ System.IFormattable.ToString(System::String ^ format, IFormatProvider ^ provider) = IFormattable::ToString;
string IFormattable.ToString (string format, IFormatProvider provider);
abstract member System.IFormattable.ToString : string * IFormatProvider -> string
override this.System.IFormattable.ToString : string * IFormatProvider -> string
Function ToString (format As String, provider As IFormatProvider) As String Implements IFormattable.ToString

参数

format
String

要使用的格式。The format to use.

- 或 --or- null 引用(在 Visual Basic 中为 Nothing),用于使用为 IFormattable 实现的类型定义的默认格式。A null reference (Nothing in Visual Basic) to use the default format defined for the type of the IFormattable implementation.

provider
IFormatProvider

要用于格式化值的提供程序。The provider to use to format the value.

- 或 --or- null 引用(在 Visual Basic 中为 Nothing),用于从操作系统的当前区域设置获取数字格式信息。A null reference (Nothing in Visual Basic) to obtain the numeric format information from the current locale setting of the operating system.

返回

String

使用指定的格式,格式化当前实例的值。The value of the current instance in the specified format.

实现

适用于