다음을 통해 공유


BigDecimal.Subtract Method

Definition

Overloads

Subtract(BigDecimal)

Returns a plain BigDecimal whose value is this-rhs, using fixed point arithmetic.

Subtract(BigDecimal, MathContext)

Returns a BigDecimal whose value is this-rhs.

Subtract(BigDecimal)

Returns a plain BigDecimal whose value is this-rhs, using fixed point arithmetic.

[Android.Runtime.Register("subtract", "(Landroid/icu/math/BigDecimal;)Landroid/icu/math/BigDecimal;", "GetSubtract_Landroid_icu_math_BigDecimal_Handler", ApiSince=24)]
public virtual Android.Icu.Math.BigDecimal? Subtract (Android.Icu.Math.BigDecimal? rhs);
[<Android.Runtime.Register("subtract", "(Landroid/icu/math/BigDecimal;)Landroid/icu/math/BigDecimal;", "GetSubtract_Landroid_icu_math_BigDecimal_Handler", ApiSince=24)>]
abstract member Subtract : Android.Icu.Math.BigDecimal -> Android.Icu.Math.BigDecimal
override this.Subtract : Android.Icu.Math.BigDecimal -> Android.Icu.Math.BigDecimal

Parameters

rhs
BigDecimal

The BigDecimal for the right hand side of the subtraction.

Returns

A BigDecimal whose value is this-rhs, using fixed point arithmetic.

Attributes

Remarks

Returns a plain BigDecimal whose value is this-rhs, using fixed point arithmetic.

The same as #subtract(BigDecimal, MathContext), where the BigDecimal is rhs, and the context is new MathContext(0, MathContext.PLAIN).

The length of the decimal part (the scale) of the result will be the maximum of the scales of the two operands.

Java documentation for android.icu.math.BigDecimal.subtract(android.icu.math.BigDecimal).

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

Subtract(BigDecimal, MathContext)

Returns a BigDecimal whose value is this-rhs.

[Android.Runtime.Register("subtract", "(Landroid/icu/math/BigDecimal;Landroid/icu/math/MathContext;)Landroid/icu/math/BigDecimal;", "GetSubtract_Landroid_icu_math_BigDecimal_Landroid_icu_math_MathContext_Handler", ApiSince=24)]
public virtual Android.Icu.Math.BigDecimal? Subtract (Android.Icu.Math.BigDecimal? rhs, Android.Icu.Math.MathContext? set);
[<Android.Runtime.Register("subtract", "(Landroid/icu/math/BigDecimal;Landroid/icu/math/MathContext;)Landroid/icu/math/BigDecimal;", "GetSubtract_Landroid_icu_math_BigDecimal_Landroid_icu_math_MathContext_Handler", ApiSince=24)>]
abstract member Subtract : Android.Icu.Math.BigDecimal * Android.Icu.Math.MathContext -> Android.Icu.Math.BigDecimal
override this.Subtract : Android.Icu.Math.BigDecimal * Android.Icu.Math.MathContext -> Android.Icu.Math.BigDecimal

Parameters

rhs
BigDecimal

The BigDecimal for the right hand side of the subtraction.

set
MathContext

The MathContext arithmetic settings.

Returns

A BigDecimal whose value is this-rhs.

Attributes

Remarks

Returns a BigDecimal whose value is this-rhs.

Implements the subtraction (<b>-</b>) operator (as defined in the decimal documentation, see BigDecimal class header), and returns the result as a BigDecimal object.

Java documentation for android.icu.math.BigDecimal.subtract(android.icu.math.BigDecimal, android.icu.math.MathContext).

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