Noda Time
Show / Hide Table of Contents

Class NodaConstants

Useful constants, mostly along the lines of "number of milliseconds in an hour".
Since 1.0.x
Availability net35-Client, PCL
Inheritance
Object
NodaConstants
Inherited Members
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: NodaTime
Assembly: NodaTime.dll
Syntax
public static class NodaConstants

Fields

BclEpoch

The instant at the BCL epoch of midnight 1st January 0001 UTC.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public static readonly Instant BclEpoch
Field Value
Type Description
Instant

DaysPerStandardWeek

Number of days in a standard Gregorian week. The value of this constant is 7.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int DaysPerStandardWeek = 7
Field Value
Type Description
Int32

HoursPerStandardDay

A constant for the number of hours in a standard day. Note that the number of hours in a day can vary due to daylight saving effects. The value of this constant is 24.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int HoursPerStandardDay = 24
Field Value
Type Description
Int32

HoursPerStandardWeek

A constant for the number of hours in a standard week of seven 24-hour days. The value of this constant is 168.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int HoursPerStandardWeek = 168
Field Value
Type Description
Int32

MillisecondsPerHour

A constant for the number of milliseconds per hour. The value of this constant is 3,600,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MillisecondsPerHour = 3600000
Field Value
Type Description
Int32

MillisecondsPerMinute

A constant for the number of milliseconds per minute. The value of this constant is 60,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MillisecondsPerMinute = 60000
Field Value
Type Description
Int32

MillisecondsPerSecond

A constant for the number of milliseconds per second. The value of this constant is 1000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MillisecondsPerSecond = 1000
Field Value
Type Description
Int32

MillisecondsPerStandardDay

A constant for the number of milliseconds per standard 24-hour day. The value of this constant is 86,400,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MillisecondsPerStandardDay = 86400000
Field Value
Type Description
Int32

MillisecondsPerStandardWeek

A constant for the number of milliseconds per standard week of seven 24-hour days. The value of this constant is 604,800,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MillisecondsPerStandardWeek = 604800000
Field Value
Type Description
Int32

MinutesPerHour

A constant for the number of minutes per hour. The value of this constant is 60.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MinutesPerHour = 60
Field Value
Type Description
Int32

MinutesPerStandardDay

A constant for the number of minutes per standard 24-hour day. The value of this constant is 1,440.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MinutesPerStandardDay = 1440
Field Value
Type Description
Int32

MinutesPerStandardWeek

A constant for the number of minutes per standard week of seven 24-hour days. The value of this constant is 10,080.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int MinutesPerStandardWeek = 10080
Field Value
Type Description
Int32

SecondsPerHour

A constant for the number of seconds per hour. The value of this constant is 3,600.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int SecondsPerHour = 3600
Field Value
Type Description
Int32

SecondsPerMinute

A constant for the number of seconds per minute. The value of this constant is 60.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int SecondsPerMinute = 60
Field Value
Type Description
Int32

SecondsPerStandardDay

A constant for the number of seconds per standard 24-hour day. The value of this constant is 86,400.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int SecondsPerStandardDay = 86400
Field Value
Type Description
Int32

SecondsPerWeek

A constant for the number of seconds per standard week of seven 24-hour days. The value of this constant is 604,800.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const int SecondsPerWeek = 604800
Field Value
Type Description
Int32

TicksPerHour

A constant for the number of ticks in an hour. The value of this constant is 36,000,000,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerHour = 36000000000L
Field Value
Type Description
Int64

TicksPerMillisecond

A constant for the number of ticks in a millisecond. The value of this constant is 10,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerMillisecond = 10000L
Field Value
Type Description
Int64

TicksPerMinute

A constant for the number of ticks in a minute. The value of this constant is 600,000,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerMinute = 600000000L
Field Value
Type Description
Int64

TicksPerSecond

A constant for the number of ticks in a second. The value of this constant is 10,000,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerSecond = 10000000L
Field Value
Type Description
Int64

TicksPerStandardDay

A constant for the number of ticks in a standard 24-hour day. The value of this constant is 864,000,000,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerStandardDay = 864000000000L
Field Value
Type Description
Int64

TicksPerStandardWeek

A constant for the number of ticks in a standard week of seven 24-hour days. The value of this constant is 6,048,000,000,000.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public const long TicksPerStandardWeek = 6048000000000L
Field Value
Type Description
Int64

UnixEpoch

The instant at the Unix epoch of midnight 1st January 1970 UTC.
Since 1.0.x
Availability net35-Client, PCL
Declaration
public static readonly Instant UnixEpoch
Field Value
Type Description
Instant
Remarks
This value is not only the Unix epoch, but the Noda Time epoch, as it represents the value with a Ticks property of 0.
In this article
Back to top Generated by DocFX