# | Line 30 | Line 30 | ext::String Stamp::getW3() const | |
---|---|---|
30 | ||
31 | return when; | |
32 | } | |
33 | + | |
34 | + | void Stamp::setSeconds(int seconds) |
35 | + | { |
36 | + | stamp.tm_sec = seconds; |
37 | + | when = timegm(&stamp); |
38 | + | } |
39 | + | |
40 | + | void Stamp::setMinutes(int minutes) |
41 | + | { |
42 | + | stamp.tm_min = minutes; |
43 | + | when = timegm(&stamp); |
44 | + | } |
45 | + | |
46 | + | Stamp::operator ext::String() const |
47 | + | { |
48 | + | char when[20]; |
49 | + | |
50 | + | std::strftime(when, 20, "%F %T", &stamp); |
51 | + | |
52 | + | return when; |
53 | + | } |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |