Skip to content

Temperature

Methods

toCelsius

public toCelsius(): \Qubus\ValueObjects\Climate\Celsius
  • This method is abstract.

toKelvin

public toKelvin(): \Qubus\ValueObjects\Climate\Kelvin
  • This method is abstract.

toFahrenheit

public toFahrenheit(): \Qubus\ValueObjects\Climate\Fahrenheit
  • This method is abstract.

Inherited methods

fromNative

Returns a RealNumber object given a PHP native float as parameter.

public static fromNative(): \Qubus\ValueObjects\Number\RealNumber|\Qubus\ValueObjects\ValueObject
  • This method is static.

Throws:


__construct

Returns a RealNumber object given a PHP native float as parameter.

public __construct(mixed $value): mixed

Parameters:

Parameter Type Description
$value mixed

Throws:


toNative

Returns the native value of the real number

public toNative(): float

equals

Tells whether two RealNumber's are equal by comparing their values.

public equals(\Qubus\ValueObjects\Number\RealNumber|\Qubus\ValueObjects\ValueObject $real): bool

Parameters:

Parameter Type Description
$real \Qubus\ValueObjects\Number\RealNumber|\Qubus\ValueObjects\ValueObject

toInteger

Returns the integer part of the RealNumber number as a IntegerNumber.

public toInteger(\Qubus\ValueObjects\Number\RoundingMode|null $roundingMode = null): \Qubus\ValueObjects\Number\IntegerNumber

Parameters:

Parameter Type Description
$roundingMode \Qubus\ValueObjects\Number\RoundingMode|null Rounding mode of the conversion.
Defaults to RoundingMode::HALF_UP.

Throws:


toNatural

Returns the absolute integer part of the RealNumber number as a Natural.

public toNatural(\Qubus\ValueObjects\Number\RoundingMode|null $roundingMode = null): \Qubus\ValueObjects\Number\Natural

Parameters:

Parameter Type Description
$roundingMode \Qubus\ValueObjects\Number\RoundingMode|null Rounding mode of the conversion.
Defaults to RoundingMode::HALF_UP.

Throws:


__toString

Returns the string representation of the real value

public __toString(): string


Automatically generated on 2025-10-13