Extensions.Quantities.Subtraction

From emotive
Revision as of 08:59, 7 August 2014 by Nb (talk | contribs) (→‎See also)
Jump to navigation Jump to search

Classification

Name Subtraction
Short Description Subtraction of two numeric variables
Class Operations
Extension OTX Quantities extension
Group Overloading semantics
Exceptions InvalidConversionException
Checker Rules -
Standard Compliant Yes

Pseudo-Code Syntax

Quantity result = QuantityTerm1 - QuantityTerm2;

Description

This is a term which as a result of the subtraction of two numeric values ​​(is NumericQuantity) returns with respect to their units.

Return Value

The Term returns the value, see table below.

Icons Note.png In OTX, Terms are categorized according to its return data type!
Data Type Description
Quantity Result of the subtraction of two numeric variables (NumericQuantity)

Properties

Name Data Type Class Default Cardinality Description
QuantityTerm1 Quantity Term - [1] Left operand is of type NumericQuantity
QuantityTerm2 Quantity Term - [1] Right operand is of type NumericQuantity

Examples

Quantity result = @Quantity:1/"km" - @Quantity:500/"m";
//Returns result = 500 m

See also

Addition
Multiplication
Division