Decimal.UnaryNegation(Decimal) Оператор
Определение
public:
static System::Decimal operator -(System::Decimal d);
public static decimal operator - (decimal d);
static member ( ~- ) : decimal -> decimal
Public Shared Operator - (d As Decimal) As Decimal
Параметры
- d
- Decimal
Инвертируемое значение.The value to negate.
Возвращаемое значение
Результат умножения параметра d
на минус единицу (-1).The result of d
multiplied by negative one (-1).
Комментарии
UnaryPlusМетод определяет операцию унарного отрицания (или оператор аддитивного инвертирования) для Decimal значений.The UnaryPlus method defines the operation of the unary negation operator (or the additive inverse operator) for Decimal values. Операция создает значение, результатом которого является 0 (нуль) при добавлении к исходному номеру.The operation produces a value that results in 0 (zero) when it is added to the original number. Языки, которые не поддерживают пользовательские операторы, могут вызывать Negate метод.Languages that do not support custom operators can call the Negate method instead.
Эквивалентным методом для этого оператора является Decimal.Negate(Decimal)The equivalent method for this operator is Decimal.Negate(Decimal)