Class Int
- Namespace
- YndigoBlue.Velocity.Functions
- Assembly
- YndigoBlue.Velocity.dll
Represents the INT (integer) mathematical function that truncates a number to its integer part.
public class Int : Function, IElement, ICheckItem, IDefaultItem, IFilterItem
- Inheritance
-
Int
- Implements
Remarks
The INT function removes the fractional part of a number, returning only the integer portion. Unlike FLOOR, INT always rounds toward zero: INT(4.7) returns 4, INT(-4.7) returns -4. This is useful for removing decimal places without rounding, extracting whole number parts, or type conversion operations.
Constructors
- Int(IEnumerable<IElement>)
Initializes a new instance of INT for multiple elements.
- Int(IElement)
Initializes a new instance of INT for a single element.