Beef Corlib
Public Member Functions | Static Public Member Functions | Static Public Attributes | Properties | List of all members
System.DateTime Struct Reference
Inheritance diagram for System.DateTime:
System.IHashable System.IFormattable

Public Member Functions

 DateTime (int64 ticks)
 
 DateTime (int64 ticks, DateTimeKind kind)
 
 DateTime (int64 ticks, DateTimeKind kind, bool isAmbiguousDst)
 
 DateTime (int year, int month, int day)
 
 DateTime (int year, int month, int day, int hour, int minute, int second)
 
 DateTime (int year, int month, int day, int hour, int minute, int second, int millisecond)
 
int GetHashCode ()
 
bool IsAmbiguousDaylightSavingTime ()
 
int64 ToFileTime ()
 
Result< int64 > ToFileTimeUtc ()
 
TimeSpan Subtract (DateTime value)
 
int64 ToBinaryRaw ()
 
Result< DateTimeAddTicks (int64 value)
 
Result< DateTimeAddYears (int value)
 
DateTime AddDays (double value)
 Returns the DateTime resulting from adding a fractional number of days to this DateTime. More...
 
DateTime AddHours (double value)
 
DateTime AddMilliseconds (double value)
 
DateTime AddMinutes (double value)
 
Result< DateTimeAddMonths (int months)
 
DateTime AddSeconds (double value)
 
Result< DateTimeSubtract (TimeSpan t)
 
DateTime ToLocalTime ()
 
DateTime ToLocalTime (bool throwOnOverflow)
 
void ToLongDateString (String outString)
 
void ToLongTimeString (String outString)
 
void ToShortDateString (String outString)
 
void ToShortTimeString (String outString)
 
override void ToString (String outString)
 
void ToString (String outString, String format)
 
void ToString (String outString, IFormatProvider provider)
 
void ToString (String outString, String format, IFormatProvider provider)
 
DateTime ToUniversalTime ()
 

Static Public Member Functions

static Result< int > DaysInMonth (int year, int month)
 
static Result< bool > IsLeapYear (int year)
 
static bool IsLeapYear (int32 year)
 
static DateTime SpecifyKind (DateTime value, DateTimeKind kind)
 
static DateTime FromFileTime (int64 fileTime)
 
static DateTime FromFileTimeUtc (int64 fileTime)
 
static Result< DateTimeFromBinaryRaw (int64 dateData)
 
static int operator<=> (DateTime lhs, DateTime rhs)
 
static Result< DateTimeoperator+ (DateTime d, TimeSpan t)
 
static DateTime operator- (DateTime d, TimeSpan t)
 
static TimeSpan operator- (DateTime lhs, DateTime rhs)
 
static Result< DateTimeTryCreate (int year, int month, int day, int hour, int minute, int second, int millisecond)
 

Static Public Attributes

static readonly DateTime MinValue = DateTime(MinTicks, DateTimeKind.Unspecified)
 
static readonly DateTime MaxValue = DateTime(MaxTicks, DateTimeKind.Unspecified)
 

Properties

int64 InternalTicks [get]
 
DateTime Date [get]
 
int32 Day [get]
 
DayOfWeek DayOfWeek [get]
 
int32 DayOfYear [get]
 
int Hour [get]
 
DateTimeKind Kind [get]
 
int Millisecond [get]
 
int Minute [get]
 
int Second [get]
 Returns the second part of this DateTime. More...
 
int Month [get]
 
static DateTime Now [get]
 
static DateTime UtcNow [get]
 
int64 Ticks [get]
 
TimeSpan TimeOfDay [get]
 
static DateTime Today [get]
 
int32 Year [get]
 

Member Function Documentation

◆ AddDays()

DateTime System.DateTime.AddDays ( double  value)
inline

Returns the DateTime resulting from adding a fractional number of days to this DateTime.

The result is computed by rounding the fractional number of days given by value to the nearest millisecond, and adding that interval to this DateTime. The value argument is permitted to be negative.

Property Documentation

◆ Second

int System.DateTime.Second
get

Returns the second part of this DateTime.

The returned value is an integer between 0 and 59.