My problem is that I want to have a way to represent the time (without a date), for example, the time of day in an iOS application. From the REST api, I get strings like β13:12:11β that show the time when something happens, I used NSDateFormatter to convert NSStrings to NSDates, but as far as I can tell, it does not accept date formats with only time components for example HH:mm:ss [EDIT: you can, see below]
So my questions are 1- Is NSTimeInterval (instead of NSDate) what should I use to store the time of day?
2- How can I convert the object "03:04:05" to and objective-c from one of the built-in frameworks.
EDIT:. You can use formats such as "HH: mm: ss", it just replaces the date with 2000-01-01 Nevertheless, it would be very nice to have a date-independent presentation time of the day.
source share