OpenTTD Source: Time< T > Struct Template Reference

OpenTTD Source 13.1

Static Public Member Functions
Time< T > Struct Template Reference

Container for wall clock time related functionality not directly provided by C++. More...

`#include <walltime_func.h>`

## Static Public Member Functions
static size_t | Format (char *buffer, const char *last, const char *format) NOACCESS(2) WARN_TIME_FORMAT(3)
| Format the current time with the given strftime format specifiers. More...

## Detailed Description

### template<typename T>
struct Time< T >

Container for wall clock time related functionality not directly provided by C++.

Template Parameters

  T | The type of the time-to-struct implementation class.

Definition at line 50 of file walltime_func.h.

## Member Function Documentation

## ◆ Format()

template<typename T >

static size_t Time< T >::Format | ( | char * | buffer,
|  | const char * | last,
|  | const char * | format
| ) |  |
| inlinestatic

Format the current time with the given strftime format specifiers.

Parameters

  buffer | The buffer to write the time string to.
  last | The last element in the buffer.
  format | The format according to strftime format specifiers.

Returns
  The number of characters that were written to the buffer.

Definition at line 58 of file walltime_func.h.

Referenced by CrashLog::CreateFileName(), CrashLog::FillCrashLog(), GetLogPrefix(), and NewGRFProfiler::GetOutputFilename().

The documentation for this struct was generated from the following file:

- src/walltime_func.h