Date
public extension Date
-
Get the current date and time, formatted.
Declaration
Swift
static func getFormattedTime() -> StringReturn Value
The current data and time as a timestamp.
-
Initializes a
Dataobject from a timestamp string.Declaration
Swift
init?(yyyyMMddTHHmmss: String?)Parameters
yyyyMMddTHHmmssThe timestamp string.
Return Value
nilif the timestamp string cannot be converted to aDate. -
Returns a string representation of the
Dateobject.Declaration
Swift
var yyyyMMddTHHmmss: String { get } -
Returns a DateFormatter instance customized for
JSONEncoder.dateEncodingStrategy.Declaration
Swift
static let asTransactionTimestamp: DateFormatter
View on GitHub
Date Extension Reference