Home Reference Source
import {LocalTime} from 'neo4j-driver-core/lib/temporal-types.js'
public class | source

LocalTime

Represents an instant capturing the time of day, but not the date, nor the timezone. Created LocalTime objects are frozen with Object.freeze() in constructor and thus immutable.

Static Method Summary

Static Public Methods
public static

fromStandardDate(standardDate: global.Date, nanosecond: NumberOrInteger | undefined): LocalTime<number>

Create a LocalTime object from the given standard JavaScript Date and optional nanoseconds.

Constructor Summary

Public Constructor
public

constructor(hour: NumberOrInteger, minute: NumberOrInteger, second: NumberOrInteger, nanosecond: NumberOrInteger)

Member Summary

Public Members
public

hour: NumberOrInteger

The hour.

public

minute: NumberOrInteger

The minute.

public

nanosecond: NumberOrInteger

The nanosecond.

public

second: NumberOrInteger

The second.

Static Public Methods

public static fromStandardDate(standardDate: global.Date, nanosecond: NumberOrInteger | undefined): LocalTime<number> source

Create a LocalTime object from the given standard JavaScript Date and optional nanoseconds. Year, month, day and time zone offset components of the given date are ignored.

Params:

NameTypeAttributeDescription
standardDate global.Date

The standard JavaScript date to convert.

nanosecond NumberOrInteger | undefined

The optional amount of nanoseconds.

Return:

LocalTime<number>

New LocalTime.

Public Constructors

public constructor(hour: NumberOrInteger, minute: NumberOrInteger, second: NumberOrInteger, nanosecond: NumberOrInteger) source

Params:

NameTypeAttributeDescription
hour NumberOrInteger

The hour for the new local time.

minute NumberOrInteger

The minute for the new local time.

second NumberOrInteger

The second for the new local time.

nanosecond NumberOrInteger

The nanosecond for the new local time.

Public Members

public hour: NumberOrInteger source

The hour.

public minute: NumberOrInteger source

The minute.

public nanosecond: NumberOrInteger source

The nanosecond.

public second: NumberOrInteger source

The second.