Remove MessageTimestamp constructor from time_point (#129)

This commit is contained in:
Matias Fontanini
2018-10-26 18:57:28 -07:00
committed by GitHub
parent 57268e666c
commit 451d60295a
2 changed files with 0 additions and 13 deletions

View File

@@ -244,12 +244,6 @@ public:
*/
MessageTimestamp(std::chrono::milliseconds timestamp, TimestampType type);
/**
* Constructs a timestamp object using a 'time_point'.
*/
template <typename Clock, typename Duration = typename Clock::duration>
MessageTimestamp(std::chrono::time_point<Clock, Duration> timestamp, TimestampType type);
/**
* Gets the timestamp value. If the timestamp was created with a 'time_point',
* the duration represents the number of milliseconds since epoch.

View File

@@ -92,13 +92,6 @@ MessageTimestamp::MessageTimestamp(milliseconds timestamp, TimestampType type)
}
template <typename Clock, typename Duration>
MessageTimestamp::MessageTimestamp(std::chrono::time_point<Clock, Duration> timestamp, TimestampType type)
: timestamp_(std::chrono::duration_cast<std::chrono::milliseconds>(timestamp.time_since_epoch())),
type_(type) {
}
milliseconds MessageTimestamp::get_timestamp() const {
return timestamp_;
}