Menu

## WrapperClock
in package
implements ClockInterface

FinalYes
WrapperClock.php : 24

### Table of Contents

#### Interfaces

ClockInterface

#### Properties

$currentClock : ClockInterface|Factory|DateTimeInterface

#### Methods

__construct() : mixed
getFactory() : Factory
now() : DateTimeImmutable
nowAs() : T
nowAsCarbon() : CarbonInterface
sleep() : void
unwrap() : ClockInterface|Factory|DateTimeInterface
withTimeZone() : static
addSeconds() : DateTimeInterface
dateAsCarbon() : CarbonInterface
nowRaw() : DateTimeInterface

### Properties

#### $currentClock

WrapperClock.php : 27
`private ClockInterface|Factory|DateTimeInterface $currentClock`

### Methods

#### __construct()

WrapperClock.php : 26
`public __construct(ClockInterface|Factory|DateTimeInterface $currentClock) : mixed`

##### Parameters

$currentClock : ClockInterface|Factory|DateTimeInterface

#### getFactory()

WrapperClock.php : 36
`public getFactory() : Factory`

##### Return values

Factory

#### now()

WrapperClock.php : 75
`public now() : DateTimeImmutable`

##### Return values

DateTimeImmutable

#### nowAs()

WrapperClock.php : 91
`public nowAs(T> $class[, DateTimeZone|string|int|null $timezone = null ]) : T`

##### Parameters

$class : T>
$timezone : DateTimeZone|string|int|null = null

##### Tags

template

  T of CarbonInterface

##### Return values

T

#### nowAsCarbon()

WrapperClock.php : 99
`public nowAsCarbon([DateTimeZone|string|int|null $timezone = null ]) : CarbonInterface`

##### Parameters

$timezone : DateTimeZone|string|int|null = null

##### Return values

CarbonInterface

#### sleep()

WrapperClock.php : 115
`public sleep(float|int $seconds) : void`

##### Parameters

$seconds : float|int

#### unwrap()

WrapperClock.php : 31
`public unwrap() : ClockInterface|Factory|DateTimeInterface`

##### Return values

ClockInterface|Factory|DateTimeInterface

#### withTimeZone()

WrapperClock.php : 140
`public withTimeZone(DateTimeZone|string $timezone) : static`

##### Parameters

$timezone : DateTimeZone|string

##### Return values

static

#### addSeconds()

WrapperClock.php : 161
`private addSeconds(DateTimeInterface $date, float|int $seconds) : DateTimeInterface`

##### Parameters

$date : DateTimeInterface
$seconds : float|int

##### Return values

DateTimeInterface

#### dateAsCarbon()

WrapperClock.php : 108
`private dateAsCarbon(DateTimeInterface $date, DateTimeZone|string|int|null $timezone) : CarbonInterface`

##### Parameters

$date : DateTimeInterface
$timezone : DateTimeZone|string|int|null

##### Return values

CarbonInterface

#### nowRaw()

WrapperClock.php : 62
`private nowRaw() : DateTimeInterface`

##### Return values

DateTimeInterface

## Search results