public function Fraction::getNumerator in Fraction 8
Same name and namespace in other branches
- 2.x src/Fraction.php \Drupal\fraction\Fraction::getNumerator()
Get the numerator.
Return value
string Returns the numerator value.
Overrides FractionInterface::getNumerator
10 calls to Fraction::getNumerator()
- Fraction::add in src/
Fraction.php - Adds another fraction to this one.
- Fraction::divide in src/
Fraction.php - Divides this fraction by another one.
- Fraction::gcd in src/
Fraction.php - Calculate the fraction's greatest common divisor using Euclid's algorithm.
- Fraction::multiply in src/
Fraction.php - Multiplies this fraction with another one.
- Fraction::reciprocate in src/
Fraction.php - Reciprocates the fraction.
File
- src/
Fraction.php, line 115
Class
- Fraction
- A simple class for representing and acting upon a fraction.
Namespace
Drupal\fractionCode
public function getNumerator() {
return $this->numerator;
}