Get the total number of seconds in the interval
@return DecimalValue
187700
public function getTotalSeconds()
	{
		// Use the days value if it is available otherwise the months value will be used which gives
		// nonsense results when the duration has been created from a day interval because the
		// DateInterval assumes 30 days to every month!
		// BMS 2018-03-20 Changed to look at the 'daysOnly' property and use the 'd' value if it is.
		//				  On this date the parent::getTotalSeconds() function returns a value that is out by an hour
		//				  when returning the interval of this expression:
		//				  (xs:dateTime("1999-10-23T09:08:07Z") - xs:dateTime("1998-09-09T04:03:02Z"))
		//				  which appears in test 'op-subtract-dateTimes-yielding-DTD-19' in 'dateTimesSubtract.xml'
		//				  This interval is 408 days 22 hours 58 minutes and 59 seconds

		if ( ! $this->Value->days && ( $this->Value->y || $this->Value->m ) ) return parent::getTotalSeconds();
		// if ( ! $this->Value->days && ! $this->Value->daysOnly ) return parent::getTotalSeconds();

		$seconds = new DecimalValue( ( $this->Value->days ? $this->Value->days : $this->Value->d ) * 86400 + $this->Value->h * 3600 + $this->Value->i * 60 + $this->Value->s );
		$seconds = $seconds->Add( "0.{$this->Value->microseconds}" );
		if ( $this->Value->invert )
		{
			$seconds = $seconds->Mul( -1 );
		}

		return $seconds;
	}
744784
public function getLoopInterval(): int
    {
        $interval_time = $this->params->getScriptParam('i');

        if (null === $interval_time || (\is_string($interval_time) && '' === trim($interval_time))) {
            return 2;
        }

        // Minimum interval is 1 second.
        return max(1, (int) $interval_time);
    }
310447
public function getDuration(): float {
        return $this->duration ? $this->duration : microtime(true) - $this->startTime;
    }
582738
public function getTotalTime()
    {
        if (null === $this->totalTime) {
            $this->totalTime = 0;
            foreach ($this->data['actions'] as $action) {
                if (isset($action['time'])) {
                    $this->totalTime += $action['time'];
                }
            }
            foreach ($this->data['applicableCheckers'] as $applicableChecker) {
                if (isset($applicableChecker['time'])) {
                    $this->totalTime += $applicableChecker['time'];
                }
            }
        }

        return $this->totalTime;
    }
1358994
public function getMinutes($round_method = null)
    {
        $result = $this->interval / (1000 * 60);

        return $this->round($result, $round_method);
    }
233314
public function duration()
    {
        if ($update = $this->latest()) {
            return $this->wrappedObject->created_at->diffInSeconds($update->occurred_at);
        }

        return 0;
    }
760201
private function intervalToSeconds(DateInterval $interval): int
    {
        $seconds = (int) $interval->format('%s');

        $multiplier = 60;
        $seconds += (int) $interval->format('%i') * $multiplier;

        $multiplier *= 60;
        $seconds += (int) $interval->format('%h') * $multiplier;

        $multiplier *= 24;
        $seconds += (int) $interval->format('%d') * $multiplier;

        $multiplier *= 30;
        $seconds += (int) $interval->format('%m') * $multiplier;

        $multiplier *= 12;
        $seconds += (int) $interval->format('%y') * $multiplier;

        return $seconds;
    }
424428
public function getDtEnd()
    {
        if (!$this->valid()) {
            return;
        }
        $end = clone $this->currentDate;

        return $end->modify('+'.$this->eventDuration.' seconds');
    }
1071303
public int getMinute()
    {
        Timestamp adjusted = this;
        if (this._offset != null) {
            if (this._offset.intValue() != 0) {
                adjusted = make_localtime();
            }
        }
        return adjusted._minute;
    }
226970
public function getExecutionTimeProportion()
    {
        if ($this->getExecutionTime() && $this->getProcess()->getAvgExecutionTime()) {
            return round($this->getExecutionTime() / $this->getProcess()->getAvgExecutionTime(), 2);
        } elseif ($this->getExecutionTime()) {
            return $this->getExecutionTime();
        } elseif ($this->getProcess()->getAvgExecutionTime()) {
            return 0;
        } else {
            return 1;
        }
    }
586358
protected function getTotal()
	{
		if (null == $this->_total) {
			$this->_total = 0;
			foreach ($this->types as $type) {
				if (isset($type['value'])) {
					$this->_total += $type['value'];
				}
			}
		}
		return $this->_total;
	}
739476
public function getRemainingSuspensionTime()
	{
		if(!$this->isSuspended())
			return 0;

		$lastAttempt = clone $this->last_attempt_at;

		$suspensionTime  = static::$suspensionTime;
		$clearAttemptsAt = $lastAttempt->modify("+{$suspensionTime} minutes");
		$now             = new Datetime;

		$timeLeft = $clearAttemptsAt->diff($now);

		$minutesLeft = ($timeLeft->s != 0 ?
						($timeLeft->days * 24 * 60) + ($timeLeft->h * 60) + ($timeLeft->i) + 1 :
						($timeLeft->days * 24 * 60) + ($timeLeft->h * 60) + ($timeLeft->i));

		return $minutesLeft;
	}
961203
public function getLdapValue()
    {
        if ($this->never) {
            $value = self::NEVER;
        } else {
            $total = 0;
            foreach (self::UNIT as $unit => $conversion) {
                $total += $this->$unit * $conversion;
            }
            $value = number_format($total, 0, '.', '');
        }

        return $value;
    }
965467
public function getDuration()
    {
        if (!isset($this->data['events']['__section__'])) {
            return 0;
        }

        $lastEvent = $this->data['events']['__section__'];

        return $lastEvent->getOrigin() + $lastEvent->getDuration() - $this->getStartTime();
    }
81171
public function getSeconds()
	{
		return $this->Value->s + ( @isset( $this->Value->microseconds ) ? "0." . $this->Value->microseconds : 0 );
	}
270167
public function getElapsedTime(): float
	{
		$last = end($this->laps);

		return ($last->isRunning() ? microtime(true) : $last->getStopTime()) - $this->laps[0]->getStartTime();
	}
289849
private static function getSeconds(): array
    {
        $seconds = [-1 => static::getConstant('TXT_DATETIME_SS', 'TXT_DATETIME_SS')];
        for ($i = 0; $i <= 59; $i++) {
            $seconds[$i] = \sprintf('%02s', $i);
        }
        return $seconds;
    }