LogoSignals.dart
Copy Markdown
rodydavis/signals.dart 999999

Type: DoubleSignalExtension

API reference and details for DoubleSignalExtension from signals.dart.

DoubleSignalExtension#

Kind: extension  |  Package: package:signals_core

Extension: DoubleSignalExtension#

extension DoubleSignalExtension on ReadonlySignal<double>

Helper extensions for ReadonlySignal, enabling direct reactive arithmetic and rounding operations on double signals.

import 'package:signals_core/signals_core.dart';

final doubleSignal = 2.5.$;
final rounded = doubleSignal.round(); // 3
final negated = -doubleSignal; // -2.5

Members of DoubleSignalExtension#

Member Type Signature Description
remainder method dart double remainder(num other) Returns the remainder of this value divided by other.
+ method dart double +(num other) Returns the sum of this value and other.
- method dart double -(num other) Returns the difference of this value and other.
***** method dart double *(num other) Returns the product of this value and other.
% method dart double %(num other) Returns the modulo of this value and other.
/ method dart double /(num other) Returns the division of this value and other.
~/ method dart int ~/(num other) Returns the truncating division of this value and other.
- method dart double -() Returns the negation of this value.
abs method dart double abs() Returns the absolute value of this value.
sign method dart double sign The sign of the double's numerical value.
round method dart int round() Returns the integer closest to this number.
floor method dart int floor() Returns the greatest integer no greater than this number.
ceil method dart int ceil() Returns the least integer that is not smaller than this number.
truncate method dart int truncate() Returns the integer obtained by discarding any fractional
roundToDouble method dart double roundToDouble() Returns the integer double value closest to this.
floorToDouble method dart double floorToDouble() Returns the greatest integer double value no greater than this.
ceilToDouble method dart double ceilToDouble() Returns the least integer double value no smaller than this.
truncateToDouble method dart double truncateToDouble() Returns the integer double value obtained by discarding any fractional

References#

The DoubleSignalExtension type is referenced and used in the following pages: