将64位十六进制转换为纳秒时间戳 [英] Convert 64-bit Hex to nanoseconds timestamps
本文介绍了将64位十六进制转换为纳秒时间戳的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有以64位十六进制表示的时间戳。有没有办法将其转换为纳秒级的时间戳? (最好是在c ++中)
I have timestamps that are represented in 64-bit hex. Is there a way to convert it to nanosecond timestamps? (preferably in c++)
推荐答案
找到了!
我用过std :: hex将十六进制值转换为long,这反过来又使我获得了纳秒级的精度。
I used std::hex to convert a hex value to long, which in turn gives me the nanosecond precision.
这篇关于将64位十六进制转换为纳秒时间戳的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文