17 #import "OFMessagePackRepresentation.h"
19 OF_ASSUME_NONNULL_BEGIN
31 #ifdef OF_HAVE_CLASS_PROPERTIES
44 @property (readonly, nonatomic)
unsigned char second;
49 @property (readonly, nonatomic)
unsigned char minute;
59 @property (readonly, nonatomic)
unsigned char hour;
64 @property (readonly, nonatomic)
unsigned char localHour;
69 @property (readonly, nonatomic)
unsigned char dayOfMonth;
89 @property (readonly, nonatomic)
unsigned short year;
94 @property (readonly, nonatomic)
unsigned short localYear;
99 @property (readonly, nonatomic)
unsigned char dayOfWeek;
109 @property (readonly, nonatomic)
unsigned short dayOfYear;
131 + (instancetype)
date;
140 + (instancetype)dateWithTimeIntervalSince1970: (
OFTimeInterval)seconds;
148 + (instancetype)dateWithTimeIntervalSinceNow: (
OFTimeInterval)seconds;
168 + (instancetype)dateWithDateString: (
OFString *)string
186 + (instancetype)dateWithLocalDateString: (
OFString *)string
214 - (instancetype)initWithTimeIntervalSince1970: (
OFTimeInterval)seconds
215 OF_DESIGNATED_INITIALIZER;
224 - (instancetype)initWithTimeIntervalSinceNow: (
OFTimeInterval)seconds;
244 - (instancetype)initWithDateString: (
OFString *)string
263 - (instancetype)initWithLocalDateString: (
OFString *)string
341 OF_ASSUME_NONNULL_END
OFComparisonResult
A result of a comparison.
Definition: OFObject.h:54
double OFTimeInterval
A time interval in seconds.
Definition: OFObject.h:150
A class for storing constant strings using the @"" literal.
Definition: OFConstantString.h:38
A class for storing, accessing and comparing dates.
Definition: OFDate.h:30
instancetype distantFuture()
Returns a date in the distant future.
Definition: OFDate.m:366
unsigned char dayOfMonth
The day of the month of the date.
Definition: OFDate.h:69
unsigned char localDayOfMonth
The day of the month of the date in local time.
Definition: OFDate.h:74
unsigned char monthOfYear
The month of the year of the date.
Definition: OFDate.h:79
unsigned char localMonthOfYear
The month of the year of the date in local time.
Definition: OFDate.h:84
unsigned long microsecond
The microsecond of the date.
Definition: OFDate.h:39
instancetype date()
Creates a new OFDate with the current date and time.
Definition: OFDate.m:335
unsigned char dayOfWeek
The day of the week of the date.
Definition: OFDate.h:99
unsigned short dayOfYear
The day of the year of the date.
Definition: OFDate.h:109
unsigned char localMinute
The minute of the date in local time.
Definition: OFDate.h:54
OFTimeInterval timeIntervalSince1970
The seconds since 1970-01-01T00:00:00Z.
Definition: OFDate.h:119
unsigned short year
The year of the date.
Definition: OFDate.h:89
unsigned short localYear
The year of the date in local time.
Definition: OFDate.h:94
unsigned char minute
The minute of the date.
Definition: OFDate.h:49
instancetype distantPast()
Returns a date in the distant past.
Definition: OFDate.m:373
unsigned char hour
The hour of the date.
Definition: OFDate.h:59
unsigned char localDayOfWeek
The day of the week of the date in local time.
Definition: OFDate.h:104
unsigned char localHour
The hour of the date in local time.
Definition: OFDate.h:64
OFTimeInterval timeIntervalSinceNow
The seconds the date is in the future.
Definition: OFDate.h:124
unsigned char second
The second of the date.
Definition: OFDate.h:44
unsigned short localDayOfYear
The day of the year of the date in local time.
Definition: OFDate.h:114
The root class for all other classes inside ObjFW.
Definition: OFObject.h:688
A class for handling strings.
Definition: OFString.h:135
A protocol for comparing objects.
Definition: OFObject.h:1384
A protocol for the creation of copies.
Definition: OFObject.h:1346
A protocol implemented by classes that support encoding to a MessagePack representation.
Definition: OFMessagePackRepresentation.h:29