Documentation

HRTime
in package

FinalYes
Tags
psalm-immutable
no-named-arguments

Parameter names are not covered by the backward compatibility promise for PHPUnit

Table of Contents

Properties

$nanoseconds  : int
$seconds  : int

Methods

duration()  : Duration
fromSecondsAndNanoseconds()  : self
nanoseconds()  : int
seconds()  : int
__construct()  : mixed
ensureNanoSecondsInRange()  : void
ensureNotNegative()  : void

Properties

$nanoseconds read-only

private int $nanoseconds

$seconds read-only

private int $seconds

Methods

fromSecondsAndNanoseconds()

public static fromSecondsAndNanoseconds(int $seconds, int $nanoseconds) : self
Parameters
$seconds : int
$nanoseconds : int
Tags
throws
InvalidArgumentException
Return values
self

nanoseconds()

public nanoseconds() : int
Return values
int

seconds()

public seconds() : int
Return values
int

__construct()

private __construct(int $seconds, int $nanoseconds) : mixed
Parameters
$seconds : int
$nanoseconds : int
Tags
throws
InvalidArgumentException

ensureNanoSecondsInRange()

private ensureNanoSecondsInRange(int $nanoseconds) : void
Parameters
$nanoseconds : int
Tags
throws
InvalidArgumentException

ensureNotNegative()

private ensureNotNegative(int $value, string $type) : void
Parameters
$value : int
$type : string
Tags
throws
InvalidArgumentException

        
On this page

Search results