• CacheManager
  • Documentation
  • Api Docs
  • MichaCo.net
    Show / Hide Table of Contents

    Class Clock

    Time related helper.

    Inheritance
    Object
    Clock
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace:CacheManager.Core.Utility
    Assembly:CacheManager.Core.dll
    Syntax
    public static class Clock

    Fields

    | Improve this Doc View Source

    TicksPerMillisecond

    Number of ticks per millisecond.

    Declaration
    public const long TicksPerMillisecond = 10000L
    Field Value
    Type Description
    Int64
    | Improve this Doc View Source

    UnixEpochSeconds

    Seconds since 1970.

    Declaration
    public const long UnixEpochSeconds = 62135596800L
    Field Value
    Type Description
    Int64
    | Improve this Doc View Source

    UnixEpochTicks

    Ticks since 1970.

    Declaration
    public const long UnixEpochTicks = 621355968000000000L
    Field Value
    Type Description
    Int64

    Methods

    | Improve this Doc View Source

    GetUnixTimestampMillis()

    Computes a timestamp representing milliseconds since 1970.

    Declaration
    public static long GetUnixTimestampMillis()
    Returns
    Type Description
    Int64

    The milliseconds.

    | Improve this Doc View Source

    GetUnixTimestampTicks()

    Computes a timestamp representing ticks since 1970.

    Declaration
    public static long GetUnixTimestampTicks()
    Returns
    Type Description
    Int64

    The ticks.

    | Improve this Doc View Source

    ToUnixTimestampMillis(DateTime)

    Computes the milliseconds since 1970 up to the given date.

    Declaration
    public static long ToUnixTimestampMillis(DateTime date)
    Parameters
    Type Name Description
    DateTime date

    The DateTime base.

    Returns
    Type Description
    Int64

    The milliseconds since 1970.

    • Improve this Doc
    • View Source
    © 2025 by Michael Conrad. All rights reserved. - MichaCo.net