# Half 结构

## 定义

``public value class Half : IComparable, IComparable<Half>, IEquatable<Half>, IFormattable``
``public struct Half : IComparable, IComparable<Half>, IEquatable<Half>, IFormattable``
``````type Half = struct
interface IFormattable``````
``````Public Structure Half
Implements IComparable, IComparable(Of Half), IEquatable(Of Half), IFormattable``````

## 属性

 表示大于零的最小正 Half 值。Represents the smallest positive Half value that is greater than zero. 表示 Half 的最大可能值。Represents the largest possible value of Half. 表示 Half 的最小可能值。Represents the smallest possible value of Half. 表示非数字。Represents not a number. 表示负无穷。Represents negative infinity. 表示正无穷。Represents positive infinity.

## 方法

 将此实例与指定的半精度浮点数进行比较，并返回一个整数，该整数指示此实例的值是小于、等于还是大于指定半精度浮点数的值。Compares this instance to a specified half-precision floating-point number and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified half-precision floating-point number. 将此实例与指定对象进行比较，并返回一个整数，该整数指示此实例的值是小于、等于还是大于指定对象的值。Compares this instance to a specified object and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified object. 比较此实例与 `other` 的相等性。Compares this instance for equality with `other`. 返回指示此实例是否与指定的 `obj` 相等的值。Returns a value that indicates whether this instance is equal to the specified `obj`. 返回此实例的哈希代码。Returns the hash code for this instance. 确定指定值是否为有限值（零、不正常或正常）。Determines whether the specified value is finite (zero, subnormal, or normal). 返回一个值，通过该值指示指定数字是否计算为正无穷大。Returns a value indicating whether the specified number evaluates to positive infinity. 确定指定值是否为数字。Determines whether the specified value is not a number. 确定指定值是否为负值。Determines whether the specified value is negative. 确定指定的值是否为负无穷大。Determines whether the specified value is negative infinity. 确定指定值是否为正规数。Determines whether the specified value is normal. 确定指定的值是否为正无穷大。Determines whether the specified value is positive infinity. 确定指定值是否是次正规数。Determines whether the specified value is subnormal. 将具有指定样式和区域性特定格式的数字的字符串表示形式转换为它的等效单精度浮点数。Converts the string representation of a number in a specified style and culture-specific format to its single-precision floating-point number equivalent. 将数字的字符串表示形式转换为它的等效半精度浮点数。Converts the string representation of a number to its half-precision floating-point number equivalent. 将具有指定区域性特定格式的数字的字符串表示形式转换为它的等效单精度浮点数。Converts the string representation of a number in a specified culture-specific format to its single-precision floating-point number equivalent. 将具有指定样式的数字的字符串表示形式转换为它的等效单精度浮点数。Converts the string representation of a number in a specified style to its single-precision floating-point number equivalent. 将具有指定样式和区域性特定格式的数字的字符串表示形式转换为它的等效单精度浮点数。Converts the string representation of a number in a specified style and culture-specific format to its single-precision floating-point number equivalent. 将此实例的数值转换为其等效的字符串表示形式。Converts the numeric value of this instance to its equivalent string representation. 使用指定的区域性特定格式信息，将此实例的数值转换为它的等效字符串表示形式。Converts the numeric value of this instance to its equivalent string representation using the specified culture-specific format information. 使用指定的格式，将此实例的数值转换为它的等效字符串表示形式。Converts the numeric value of this instance to its equivalent string representation, using the specified format. 使用指定的格式和区域性特定格式信息，将此实例的数值转换为它的等效字符串表示形式。Converts the numeric value of this instance to its equivalent string representation using the specified format and culture-specific format information. 尝试将当前 Half 实例的值的格式设置为提供的字符范围。Tries to format the value of the current Half instance into the provided span of characters. 将数字的范围表示形式转换为它的等效半精度浮点数。Converts the span representation of a number to its half-precision floating-point number equivalent. 一个指示转换是否成功的返回值。A return value indicates whether the conversion succeeded or failed. 将数字的范围表示形式转换为它的等效半精度浮点数。Converts the span representation of a number to its half-precision floating-point number equivalent. 一个指示转换是否成功的返回值。A return value indicates whether the conversion succeeded or failed. 将数字的字符串表示形式转换为它的等效半精度浮点数。Converts the string representation of a number to its half-precision floating-point number equivalent. 一个指示转换是否成功的返回值。A return value indicates whether the conversion succeeded or failed. 将数字的字符串表示形式转换为它的等效半精度浮点数。Converts the string representation of a number to its half-precision floating-point number equivalent. 一个指示转换是否成功的返回值。A return value indicates whether the conversion succeeded or failed.

## 运算符

 返回一个值，该值指示两个指定的 Half 值是否相等。Returns a value that indicates whether two specified Half values are equal. 用于将 Double 值转换为 Half 的显式运算符。An explicit operator to convert a Double value to a Half. 用于将 Half 值转换为 Double 的显式运算符。An explicit operator to convert a Half value to a Double. 用于将 Half 值转换为 Single 的显式运算符。An explicit operator to convert a Half value to a Single. 用于将 Single 值转换为 Half 的显式运算符。An explicit operator to convert a Single value to a Half. 返回一个值，该值指示指定的 Half 值是否大于另一个指定的 Half 值。Returns a value that indicates whether a specified Half value is greater than another specified Half value. 返回一个值，该值指示 `left` 是否大于等于 `right`。Returns a value that indicates whether `left` is greater than or equal to `right`. 返回一个值，该值指示两个指定的 Half 值是否不相等。Returns a value that indicates whether two specified Half values are not equal. 返回一个值，该值指示指定的 Half 值是否小于另一个指定的 Half 值。Returns a value that indicates whether a specified Half value is less than another specified Half value. 返回一个值，该值指示指定的 Half 值是否小于或等于另一个指定的 Half 值。Returns a value that indicates whether a specified Half value is less than or equal to another specified Half value.