|
ocpp 0.24.1
A C++ implementation of the Open Charge Point Protocol
|
Contains a DateTime implementation that can parse and create RFC 3339 compatible strings. More...
#include <types.hpp>
Public Member Functions | |
| DateTimeImpl () | |
| Creates a new DateTimeImpl object with the current utc time. | |
| DateTimeImpl (std::chrono::time_point< date::utc_clock > timepoint) | |
Creates a new DateTimeImpl object from the given timepoint. | |
| DateTimeImpl (const std::string &timepoint_str) | |
Creates a new DateTimeImpl object from the given timepoint_str. | |
| std::string | to_rfc3339 () const |
| Converts this DateTimeImpl to a RFC 3339 compatible string. More... | |
| void | from_rfc3339 (const std::string &timepoint_str) |
Sets the timepoint of this DateTimeImpl to the given timepoint_str. | |
| std::chrono::time_point< date::utc_clock > | to_time_point () const |
| Converts this DateTimeImpl to a std::chrono::time_point. More... | |
| DateTimeImpl & | operator= (const DateTimeImpl &dt) |
Assignment operator= to assign another DateTimeImpl dt to this DateTimeImpl. | |
| operator std::string () | |
| Conversion operatpr std::string returns a RFC 3339 compatible string representation of the stored DateTime. | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const DateTimeImpl &dt) |
Writes the given DateTimeImpl dt to the given output stream os as a RFC 3339 compatible string. More... | |
| bool | operator> (const DateTimeImpl &lhs, const DateTimeImpl &rhs) |
Comparison operator> between two DateTimeImpl lhs and rhs. | |
| bool | operator>= (const DateTimeImpl &lhs, const DateTimeImpl &rhs) |
Comparison operator>= between two DateTimeImpl lhs and rhs. | |
| bool | operator< (const DateTimeImpl &lhs, const DateTimeImpl &rhs) |
Comparison operator< between two DateTimeImpl lhs and rhs. | |
| bool | operator<= (const DateTimeImpl &lhs, const DateTimeImpl &rhs) |
Comparison operator<= between two DateTimeImpl lhs and rhs. | |
| bool | operator== (const DateTimeImpl &lhs, const DateTimeImpl &rhs) |
Comparison operator== between two DateTimeImpl lhs and rhs. | |
Contains a DateTime implementation that can parse and create RFC 3339 compatible strings.
| std::string ocpp::DateTimeImpl::to_rfc3339 | ( | ) | const |
Converts this DateTimeImpl to a RFC 3339 compatible string.
| std::chrono::time_point< date::utc_clock > ocpp::DateTimeImpl::to_time_point | ( | ) | const |
Converts this DateTimeImpl to a std::chrono::time_point.
|
friend |
Writes the given DateTimeImpl dt to the given output stream os as a RFC 3339 compatible string.