37 os <<
"<?xml version=\"1.0\"?>"
38 <<
"<nfdStatus xmlns=\"ndn:/localhost/nfd/status/1\">";
50 for (
char ch : text.
s) {
78 return "PT" + to_string(d.count()) +
"S";
84 return time::toString(t,
"%Y-%m-%dT%H:%M:%S%F");
94 for (
int i = 0; i < spaces.
nSpaces; ++i) {
102 , m_subsequent(subsequent)
115 if (++sep.m_count == 1) {
116 return os << sep.m_first;
118 return os << sep.m_subsequent;
124 return to_string(d.count()) + (isLong ?
" seconds" :
"s");
130 return time::toIsoString(t);
std::string formatSeconds(time::seconds d, bool isLong)
Copyright (c) 2014-2015, Regents of the University of California, Arizona Board of Regents...
std::string formatTimestamp(time::system_clock::TimePoint t)
Separator(const std::string &first, const std::string &subsequent)
int nSpaces
number of spaces; print nothing if negative
std::ostream & operator<<(std::ostream &os, const Spaces &spaces)
print different string on first and subsequent usage
print a number of whitespaces