C# Класс SharpOS.Kernel.Foundation.Clock

Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
HardwareSyncTicks int

Открытые методы

Метод Описание
GetBootTime ( Time time ) : void

Retrieves the system boot time.

GetCurrentTime ( ) : Time
GetCurrentTime ( Time time ) : void

Retrieves the current system clock time.

GetCurrentTimestamp ( ) : ulong
GetHardwareTime ( Time time ) : bool

Retrieves the current hardware time. If this is not possible, this method returns false.

GetHardwareTimestamp ( ) : ulong

Retrieves the current hardware time as a timestamp. If this is not possible, this method returns 0.

GetNanostamp ( ) : ulong

Returns the amount of nanoseconds since the last ResetNanostamp() call. This value is limited in precision to the frequency of the system timer.

ResetNanostamp ( ) : void

Resets the nanostamp counter.

Setup ( ) : void

Initializes the system clock. First the hardware time is read and stored as the boot time and current time. The times are stored as 64-bit unsigned integers with 100-nanosecond ticks since the epoch (January 1, 0001, 00:00:00). A handler is added to the system timer event which updates the current time and handles periodic synchronization with the hardware time. The amount added to the current time per timer fire is relevant to the frequency reportedly used by the system timer.

Write ( ) : void

Приватные методы

Метод Описание
UpdateClock ( uint ticks ) : void

Описание методов

GetBootTime() публичный статический Метод

Retrieves the system boot time.
public static GetBootTime ( Time time ) : void
time Time
Результат void

GetCurrentTime() публичный статический Метод

public static GetCurrentTime ( ) : Time
Результат Time

GetCurrentTime() публичный статический Метод

Retrieves the current system clock time.
public static GetCurrentTime ( Time time ) : void
time Time
Результат void

GetCurrentTimestamp() публичный статический Метод

public static GetCurrentTimestamp ( ) : ulong
Результат ulong

GetHardwareTime() публичный статический Метод

Retrieves the current hardware time. If this is not possible, this method returns false.
public static GetHardwareTime ( Time time ) : bool
time Time
Результат bool

GetHardwareTimestamp() публичный статический Метод

Retrieves the current hardware time as a timestamp. If this is not possible, this method returns 0.
public static GetHardwareTimestamp ( ) : ulong
Результат ulong

GetNanostamp() публичный статический Метод

Returns the amount of nanoseconds since the last ResetNanostamp() call. This value is limited in precision to the frequency of the system timer.
public static GetNanostamp ( ) : ulong
Результат ulong

ResetNanostamp() публичный статический Метод

Resets the nanostamp counter.
public static ResetNanostamp ( ) : void
Результат void

Setup() публичный статический Метод

Initializes the system clock. First the hardware time is read and stored as the boot time and current time. The times are stored as 64-bit unsigned integers with 100-nanosecond ticks since the epoch (January 1, 0001, 00:00:00). A handler is added to the system timer event which updates the current time and handles periodic synchronization with the hardware time. The amount added to the current time per timer fire is relevant to the frequency reportedly used by the system timer.
public static Setup ( ) : void
Результат void

Write() публичный статический Метод

public static Write ( ) : void
Результат void

Описание свойств

HardwareSyncTicks публичное статическое свойство

The interval of time (in 100-nanosecond ticks) between synchronizations from the hardware clock to the software clock. (default 600000000 ticks is 1 minute).
public static int HardwareSyncTicks
Результат int