class TimeOfDay extends Message

Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may chose to allow leap seconds. Related types are [google.type.Date][google.type.Date] and google.protobuf.Timestamp.

Generated from protobuf message google.type.TimeOfDay

Methods

__construct(array $data = NULL)

Constructor.

int
getHours()

Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value "24:00:00" for scenarios like business closing time.

$this
setHours(int $var)

Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value "24:00:00" for scenarios like business closing time.

int
getMinutes()

Minutes of hour of day. Must be from 0 to 59.

$this
setMinutes(int $var)

Minutes of hour of day. Must be from 0 to 59.

int
getSeconds()

Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.

$this
setSeconds(int $var)

Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.

int
getNanos()

Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

$this
setNanos(int $var)

Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

Details

at line 65
__construct(array $data = NULL)

Constructor.

Parameters

array $data { Optional. Data for populating the Message object.

@type int $hours
      Hours of day in 24 hour format. Should be from 0 to 23. An API may choose
      to allow the value "24:00:00" for scenarios like business closing time.
@type int $minutes
      Minutes of hour of day. Must be from 0 to 59.
@type int $seconds
      Seconds of minutes of the time. Must normally be from 0 to 59. An API may
      allow the value 60 if it allows leap-seconds.
@type int $nanos
      Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

}

at line 77
int getHours()

Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value "24:00:00" for scenarios like business closing time.

Generated from protobuf field int32 hours = 1;

Return Value

int

at line 90
$this setHours(int $var)

Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value "24:00:00" for scenarios like business closing time.

Generated from protobuf field int32 hours = 1;

Parameters

int $var

Return Value

$this

at line 104
int getMinutes()

Minutes of hour of day. Must be from 0 to 59.

Generated from protobuf field int32 minutes = 2;

Return Value

int

at line 116
$this setMinutes(int $var)

Minutes of hour of day. Must be from 0 to 59.

Generated from protobuf field int32 minutes = 2;

Parameters

int $var

Return Value

$this

at line 131
int getSeconds()

Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.

Generated from protobuf field int32 seconds = 3;

Return Value

int

at line 144
$this setSeconds(int $var)

Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.

Generated from protobuf field int32 seconds = 3;

Parameters

int $var

Return Value

$this

at line 158
int getNanos()

Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

Generated from protobuf field int32 nanos = 4;

Return Value

int

at line 170
$this setNanos(int $var)

Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

Generated from protobuf field int32 nanos = 4;

Parameters

int $var

Return Value

$this