Nebula
Loading...
Searching...
No Matches
Posix::PosixCalendarTime Class Reference

#include <posixcalendartime.h>

Detailed Description

Posix implementation of CalendarTime.

(C) 2007 Radon Labs GmbH (C) 2013-2018 Individual contributors, see AUTHORS file

Inherits Base::CalendarTimeBase.

Static Public Member Functions

static Timing::CalendarTime GetSystemTime ()
 get the current system time
static Timing::CalendarTime GetLocalTime ()
 get the current local time
static IO::FileTime SystemTimeToFileTime (const Timing::CalendarTime &systemTime)
 convert system time to file time
static Timing::CalendarTime FileTimeToSystemTime (const IO::FileTime &fileTime)
 convert file time to system time
static IO::FileTime LocalTimeToFileTime (const Timing::CalendarTime &localTime)
 convert local time to file time
static Timing::CalendarTime FileTimeToLocalTime (const IO::FileTime &fileTime)
 convert file time to local time
Static Public Member Functions inherited from Base::CalendarTimeBase
static Timing::CalendarTime GetSystemTime ()
 get the current system time
static Timing::CalendarTime GetLocalTime ()
 get the current local time
static IO::FileTime SystemTimeToFileTime (const Timing::CalendarTime &systemTime)
 convert system time to file time
static Timing::CalendarTime FileTimeToSystemTime (const IO::FileTime &fileTime)
 convert file time to system time
static IO::FileTime LocalTimeToFileTime (const Timing::CalendarTime &localTime)
 convert local time to file time
static Timing::CalendarTime FileTimeToLocalTime (const IO::FileTime &fileTime)
 convert file time to local time
static Util::String Format (const Util::String &fmtString, const Timing::CalendarTime &calTime)
 format to string
static Util::String MonthToString (Month m)
 convert month to string
static Month StringToMonth (const Util::String &str)
 convert string to month
static Util::String WeekdayToString (Weekday d)
 convert weekday to string
static Weekday StringToWeekday (const Util::String &str)
 convert string to weekday

Static Private Member Functions

static Timing::CalendarTime FromPosixSystemTime (const timeval &t)
 convert from Posix time_t
static timeval ToPosixSystemTime (const Timing::CalendarTime &calTime)
 convert to Posix time_t

Additional Inherited Members

Public Types inherited from Base::CalendarTimeBase
enum  Month {
  January = 1 , February , March , April ,
  May , June , July , August ,
  September , October , November , December
}
 months enum More...
enum  Weekday {
  Sunday = 0 , Monday , Tuesday , Wednesday ,
  Thursday , Friday , Saturday
}
 weekdays enum More...
typedef unsigned int Year
 typedefs
typedef unsigned int Day
typedef unsigned int Hour
typedef unsigned int Minute
typedef unsigned int Second
typedef unsigned int MilliSecond
Public Member Functions inherited from Base::CalendarTimeBase
 CalendarTimeBase ()
 constructor
void SetYear (Year y)
 set the year
Year GetYear () const
 get the year
void SetMonth (Month m)
 set the month
Month GetMonth () const
 get the month
void SetWeekday (Weekday wd)
 set the day-of-week
Weekday GetWeekday () const
 get the day-of-week
void SetDay (Day d)
 set the day (of month)
Day GetDay () const
 get the day (of month)
void SetHour (Hour h)
 set hour-of-day
Hour GetHour () const
 get hour-of-day
void SetMinute (Minute m)
 set minute-of-hour
Minute GetMinute () const
 get minute-of-hour
void SetSecond (Second s)
 set second-of-minute
Second GetSecond () const
 get second-of-minute
void SetMilliSecond (MilliSecond ms)
 set milliseconds
MilliSecond GetMilliSecond () const
 get milliseconds
Protected Attributes inherited from Base::CalendarTimeBase
Year year
Month month
Weekday weekday
Day day
Hour hour
Minute minute
Second second
MilliSecond milliSecond

Member Function Documentation

◆ FileTimeToLocalTime()

CalendarTime Posix::PosixCalendarTime::FileTimeToLocalTime ( const IO::FileTime & fileTime)
static

convert file time to local time

◆ FileTimeToSystemTime()

CalendarTime Posix::PosixCalendarTime::FileTimeToSystemTime ( const IO::FileTime & fileTime)
static

convert file time to system time

◆ FromPosixSystemTime()

CalendarTime Posix::PosixCalendarTime::FromPosixSystemTime ( const timeval & t)
staticprivate

convert from Posix time_t

◆ GetLocalTime()

CalendarTime Posix::PosixCalendarTime::GetLocalTime ( )
static

get the current local time

Obtains the current local time (with time-zone adjustment).

◆ GetSystemTime()

CalendarTime Posix::PosixCalendarTime::GetSystemTime ( )
static

get the current system time

Obtains the current system time.

This does not depend on the current time zone.

◆ LocalTimeToFileTime()

FileTime Posix::PosixCalendarTime::LocalTimeToFileTime ( const Timing::CalendarTime & localTime)
static

convert local time to file time

◆ SystemTimeToFileTime()

FileTime Posix::PosixCalendarTime::SystemTimeToFileTime ( const Timing::CalendarTime & systemTime)
static

convert system time to file time

◆ ToPosixSystemTime()

timeval Posix::PosixCalendarTime::ToPosixSystemTime ( const Timing::CalendarTime & calTime)
staticprivate

convert to Posix time_t


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