Condividi tramite


Half.ValueOf Method

Definition

Overloads

ValueOf(Int16)

Returns a Half instance representing the specified half-precision float value.

ValueOf(String)

Returns a Half instance representing the specified string value.

ValueOf(Single)

Returns a Half instance representing the specified float value.

ValueOf(Int16)

Returns a Half instance representing the specified half-precision float value.

[Android.Runtime.Register("valueOf", "(S)Landroid/util/Half;", "", ApiSince=26)]
public static Android.Util.Half ValueOf (short h);
[<Android.Runtime.Register("valueOf", "(S)Landroid/util/Half;", "", ApiSince=26)>]
static member ValueOf : int16 -> Android.Util.Half

Parameters

h
Int16

A half-precision float value

Returns

a Half instance representing h

Attributes

Remarks

Returns a Half instance representing the specified half-precision float value.

Java documentation for android.util.Half.valueOf(short).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

ValueOf(String)

Returns a Half instance representing the specified string value.

[Android.Runtime.Register("valueOf", "(Ljava/lang/String;)Landroid/util/Half;", "", ApiSince=26)]
public static Android.Util.Half ValueOf (string s);
[<Android.Runtime.Register("valueOf", "(Ljava/lang/String;)Landroid/util/Half;", "", ApiSince=26)>]
static member ValueOf : string -> Android.Util.Half

Parameters

s
String

The string to be parsed

Returns

a Half instance representing h

Attributes

Remarks

Returns a Half instance representing the specified string value. Calling this method is equivalent to calling toHalf(Float.parseString(h)). See Float#valueOf(String) for more information on the format of the string representation.

Java documentation for android.util.Half.valueOf(java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

ValueOf(Single)

Returns a Half instance representing the specified float value.

[Android.Runtime.Register("valueOf", "(F)Landroid/util/Half;", "", ApiSince=26)]
public static Android.Util.Half ValueOf (float f);
[<Android.Runtime.Register("valueOf", "(F)Landroid/util/Half;", "", ApiSince=26)>]
static member ValueOf : single -> Android.Util.Half

Parameters

f
Single

A float value

Returns

a Half instance representing f

Attributes

Remarks

Returns a Half instance representing the specified float value.

Java documentation for android.util.Half.valueOf(float).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to