MCPcopy Create free account
hub / github.com/TzuHuanTai/RaspberryPi-WebRTC / ParseDatetime

Method ParseDatetime

src/common/utils.cpp:257–263  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

255}
256
257std::chrono::system_clock::time_point Utils::ParseDatetime(const std::string &datetime_str) {
258 std::tm tm = {};
259 std::stringstream ss(datetime_str);
260 ss >> std::get_time(&tm, "%Y%m%d_%H%M%S");
261 tm.tm_isdst = -1;
262 return std::chrono::system_clock::from_time_t(std::mktime(&tm));
263}
264
265std::string Utils::FindFilesFromDatetime(const std::string &root, const std::string &basename) {
266 if (basename.length() < 15) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected