Guitar
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
DateTime Class Reference

#include <DateTime.h>

Collaboration diagram for DateTime:
Collaboration graph
[legend]

Public Member Functions

 DateTime ()=default
 
 DateTime (Date const &date, Time const &time)
 
Date const & date () const
 
Time const & time () const
 
void setDate (Date const &date)
 
void setTime (Time const &time)
 
bool isValid () const
 
time_t toSecsSinceEpoch () const
 
std::string toString () const
 

Static Public Member Functions

static DateTime parseDateTime (char const *s)
 
static DateTime fromSecsSinceEpoch (uint64_t t)
 

Private Attributes

Date date_
 
Time time_
 

Constructor & Destructor Documentation

◆ DateTime() [1/2]

DateTime::DateTime ( )
default

◆ DateTime() [2/2]

DateTime::DateTime ( Date const &  date,
Time const &  time 
)
inline

Member Function Documentation

◆ date()

Date const& DateTime::date ( ) const
inline

◆ fromSecsSinceEpoch()

DateTime DateTime::fromSecsSinceEpoch ( uint64_t  t)
static
Here is the call graph for this function:

◆ isValid()

bool DateTime::isValid ( ) const
inline
Here is the call graph for this function:

◆ parseDateTime()

DateTime DateTime::parseDateTime ( char const *  s)
static
Here is the call graph for this function:

◆ setDate()

void DateTime::setDate ( Date const &  date)
inline
Here is the call graph for this function:

◆ setTime()

void DateTime::setTime ( Time const &  time)
inline
Here is the call graph for this function:

◆ time()

Time const& DateTime::time ( ) const
inline

◆ toSecsSinceEpoch()

time_t DateTime::toSecsSinceEpoch ( ) const
inline
Here is the call graph for this function:

◆ toString()

std::string DateTime::toString ( ) const
Here is the call graph for this function:

Member Data Documentation

◆ date_

Date DateTime::date_
private

◆ time_

Time DateTime::time_
private

The documentation for this class was generated from the following files: