8 const std::string& fileData) {
9 FILE* fp = fopen(fileName.c_str(),
"w");
11 printf(
"Failed to fopen %s\n", fileName.c_str());
12 throw std::runtime_error(
"Failed to open file");
14 fprintf(fp,
"%s", fileData.c_str());
19 auto t = std::time(
nullptr);
20 auto tm = *std::localtime(&t);
21 std::ostringstream ss;
22 ss << std::put_time(&tm,
"%c");
33 assert(ttl >= 0 && ttl <= 255);
34 return "udpm://239.255.76.67:7667?ttl=" + std::to_string(ttl);
void writeStringToFile(const std::string &fileName, const std::string &fileData)
std::string getLcmUrl(s64 ttl)
std::string getConfigDirectoryPath()
std::string getCurrentTimeAndDate()