|
Boost Users : |
Subject: Re: [Boost-users] Converting Timestamp into hex of 8 bytes
From: Rahul Mathur (srivmuk_at_[hidden])
Date: 2013-11-08 10:54:26
YES, do have the TIMESTAMP from string viz 1383889129. Since, the
declaration of TIMESTAMP is "char TIMESTAMP[8]", so looking how to convert
this?
On Fri, Nov 8, 2013 at 11:49 AM, Igor R <boost.lists_at_[hidden]> wrote:
> > I have a string Timestamp of 1383889129 which on ONLINE conversion from
> > string to hex gives a 10 bytes as "31 33 38 33 38 38 39 31 32 39".
>
> The above is not "conversion from string to hex", but merely a hex
> representation of every ascii character in "1383889129" string.
>
>
> > But, the need is to have the TIMEStamp in 8 bytes only.
>
> It's unclear what you want exactly. If you need a time-stamp as a
> number, use boost::lexical_cast<int>("1383889129") or any other
> ascii-to-int conversion.
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net