Crate bitcoin_time

Source

Structs§

MedianFilter
| Median filter over a stream of values. | | Returns the median of the last N numbers |

Constants§

BITCOIN_TIMEDATA_MAX_SAMPLES
DEFAULT_MAX_TIME_ADJUSTMENT

Traits§

MillisToTimeval
| Convert milliseconds to a struct timeval | for e.g. select. |

Functions§

chrono_sanity_check
| Sanity check epoch match normal Unix | epoch |
format_iso8601date
format_iso8601date_time
| ISO 8601 formatting is preferred. Use | the FormatISO8601{DateTime,Date} | helper functions if possible. |
get_adjusted_datetime
get_adjusted_time
get_datetime
get_mock_time_since_epoch
| For testing |
get_system_time_since_epoch
get_time
get_time_micros_since_epoch
| Returns the system time (not mockable) |
get_time_millis_since_epoch
| Returns the system time (not mockable) |
get_time_offset
| “Never go to sea with two chronometers; | take one or three.” | | Our three time sources are: | | - System clock | | - Median of other nodes clocks | | - The user (asking the user to fix the | system clock if the first two disagree) |
get_time_seconds_since_epoch
| Returns the system time (not mockable) | | Like GetTime(), but not mockable
get_time_since_epoch
| Return system time (or mocked time, | if set) |
max_unix_timestamp
parse_iso8601date_time
set_mock_time
| For testing. Set e.g. with the setmocktime | rpc, or -mocktime argument |
uninterruptible_sleep