Date
public extension Date
-
Creates a
PostgresDate
by interpreting thisDate
in a specified time zone.Equivalent to
PostgresDate(date: self, in: timeZone)
.Declaration
Swift
func postgresDate(in timeZone: TimeZone) -> PostgresDate
Parameters
timeZone
the time zone
Return Value
the
PostgresDate
-
Creates a
PostgresTime
by interpreting thisDate
in a specified time zone.Equivalent to
PostgresTime(date: self, in: timeZone)
.Declaration
Swift
func postgresTime(in timeZone: TimeZone) -> PostgresTime
Parameters
timeZone
the time zone
Return Value
the
PostgresTime
-
Creates a
PostgresTimeWithTimeZone
by interpreting thisDate
in a specified time zone.Equivalent to
PostgresTimeWithTimeZone(date: self, in: timeZone)
.Declaration
Swift
func postgresTimeWithTimeZone(in timeZone: TimeZone) -> PostgresTimeWithTimeZone?
Parameters
timeZone
the time zone
Return Value
-
Creates a
PostgresTimestamp
by interpreting thisDate
in a specified time zone.Equivalent to
PostgresTimestamp(date: self, in: timeZone)
.Declaration
Swift
func postgresTimestamp(in timeZone: TimeZone) -> PostgresTimestamp
Parameters
timeZone
the time zone
Return Value
-
A
PostgresTimestampWithTimeZone
for thisDate
.Equivalent to
PostgresTimestampWithTimeZone(date: self)
.Declaration
Swift
var postgresTimestampWithTimeZone: PostgresTimestampWithTimeZone { get }