Not part of STL but well known library is boost.
I would go the way of using boost::date
. Here are some examples: http://www.boost.org/doc/libs/1_55_0/doc/html/date_time/date_time_io.html#date_time.io_tutorial.
If you did not try out boost yet I encourage you to do so as it saves you from a lot of nasty issues, as it masks most OS dependent things like threading for example. Many things in boost
are header only (template libraries). However datetime requires a lib or dll.