UNPKG

predictype

Version:

PredicType is a library of pre-built and tested predicates for TypeScript, covering various data types and operations.

31 lines (30 loc) 1.04 kB
/** * Enums and types for number predicate operations. * * @module numbers/enums */ export declare enum NumberComparisonEnum { EQUALS = "equals", GREATER_OR_EQUAL = "greater_or_equal", GREATER_THAN = "greater_than", LESS_OR_EQUAL = "less_or_equal", LESS_THAN = "less_than", NOT_EQUALS = "not_equals" } export type NumberComparisonOper = NumberComparisonEnum | `${NumberComparisonEnum}`; export declare enum NumberRangeEnum { BETWEEN = "between",// inclusif : min <= x <= max NOT_BETWEEN = "not_between",// inclusif : x < min || x > max STRICT_BETWEEN = "strict_between",// exclusif : min < x < max STRICT_NOT_BETWEEN = "strict_not_between" } export type NumberRangeOper = NumberRangeEnum | `${NumberRangeEnum}`; export declare enum NumberStateEnum { IS_FINITE = "is_finite", IS_FLOAT = "is_float", IS_INTEGER = "is_integer", IS_NEGATIVE = "is_negative", IS_POSITIVE = "is_positive", IS_ZERO = "is_zero" } export type NumberStateOper = NumberStateEnum | `${NumberStateEnum}`;