C# Class NExtends.Primitives.DateTimeExtensions

Show file Open project: LuccaSA/NExtends

Public Properties

Property Type Description
dayText String[]

Public Methods

Method Description
AddDaysSafe ( this date, double value ) : System.DateTime
DayText ( int day ) : String
FirstOfMonth ( this d ) : System.DateTime
GetDifferenceInFullMonths ( this firstDate, System.DateTime secondDate ) : int
GetDifferenceInFullYearsWith ( this firstDate, System.DateTime secondDate ) : int
IsFirstOfMonth ( System.DateTime d ) : bool
IsLastOfMonth ( System.DateTime d ) : bool
LastOfMonth ( this d ) : System.DateTime
Max ( this a, System.DateTime b ) : System.DateTime
Min ( this a, System.DateTime b ) : System.DateTime
Minutes ( this d ) : int

Minutes écoulées depuis minuit pour cette date : entre 0 et 1440

Next ( this d, DayOfWeek day ) : System.DateTime
NextOrCurrent ( this d, DayOfWeek day ) : System.DateTime
Previous ( this d, DayOfWeek day ) : System.DateTime
PreviousOrCurrent ( this d, DayOfWeek day ) : System.DateTime
ToFrenchLongText ( this d ) : String
ToFrenchLongTextHeure ( this d ) : String
ToHttpDate ( this d ) : string
ToISO ( this d ) : String
ToISOz ( this d ) : String

Prend en charge le TimeZone envoyé par le client embed dans la date/time exprimée en UTC

ToJQuery ( this d ) : String
ToJSONDate ( this d ) : String
ToJSONDateTime ( this d ) : String
ToMidnightTimeIfEmpty ( this date ) : System.DateTime

Permet d'affecter un time à 23:59:59.999 à une date qui n'a pas de time

ToShortDate ( this d ) : String

new DateTime(2008, 8, 29, 19, 27, 15) ==> août 2008

ToShortDateTimeString ( this d ) : String
ToShortFrenchTimeString ( this d ) : String
ToShortISO ( this d ) : String
ToShortUpperDay ( this d ) : String
ToShortUpperMonth ( this d ) : String
toShortUserFormat ( this date, int format ) : String
weekNumber ( this d ) : int

Private Methods

Method Description
LookFor ( System.DateTime start, DayOfWeek day, int step ) : System.DateTime
ToJSON ( this d ) : String

Method Details

AddDaysSafe() public static method

public static AddDaysSafe ( this date, double value ) : System.DateTime
date this
value double
return System.DateTime

DayText() public static method

public static DayText ( int day ) : String
day int
return String

FirstOfMonth() public static method

public static FirstOfMonth ( this d ) : System.DateTime
d this
return System.DateTime

GetDifferenceInFullMonths() public static method

public static GetDifferenceInFullMonths ( this firstDate, System.DateTime secondDate ) : int
firstDate this
secondDate System.DateTime
return int

GetDifferenceInFullYearsWith() public static method

public static GetDifferenceInFullYearsWith ( this firstDate, System.DateTime secondDate ) : int
firstDate this
secondDate System.DateTime
return int

IsFirstOfMonth() public static method

public static IsFirstOfMonth ( System.DateTime d ) : bool
d System.DateTime
return bool

IsLastOfMonth() public static method

public static IsLastOfMonth ( System.DateTime d ) : bool
d System.DateTime
return bool

LastOfMonth() public static method

public static LastOfMonth ( this d ) : System.DateTime
d this
return System.DateTime

Max() public static method

public static Max ( this a, System.DateTime b ) : System.DateTime
a this
b System.DateTime
return System.DateTime

Min() public static method

public static Min ( this a, System.DateTime b ) : System.DateTime
a this
b System.DateTime
return System.DateTime

Minutes() public static method

Minutes écoulées depuis minuit pour cette date : entre 0 et 1440
public static Minutes ( this d ) : int
d this
return int

Next() public static method

public static Next ( this d, DayOfWeek day ) : System.DateTime
d this
day DayOfWeek
return System.DateTime

NextOrCurrent() public static method

public static NextOrCurrent ( this d, DayOfWeek day ) : System.DateTime
d this
day DayOfWeek
return System.DateTime

Previous() public static method

public static Previous ( this d, DayOfWeek day ) : System.DateTime
d this
day DayOfWeek
return System.DateTime

PreviousOrCurrent() public static method

public static PreviousOrCurrent ( this d, DayOfWeek day ) : System.DateTime
d this
day DayOfWeek
return System.DateTime

ToFrenchLongText() public static method

public static ToFrenchLongText ( this d ) : String
d this
return String

ToFrenchLongTextHeure() public static method

public static ToFrenchLongTextHeure ( this d ) : String
d this
return String

ToHttpDate() public static method

public static ToHttpDate ( this d ) : string
d this
return string

ToISO() public static method

public static ToISO ( this d ) : String
d this
return String

ToISOz() public static method

Prend en charge le TimeZone envoyé par le client embed dans la date/time exprimée en UTC
public static ToISOz ( this d ) : String
d this
return String

ToJQuery() public static method

public static ToJQuery ( this d ) : String
d this
return String

ToJSONDate() public static method

public static ToJSONDate ( this d ) : String
d this
return String

ToJSONDateTime() public static method

public static ToJSONDateTime ( this d ) : String
d this
return String

ToMidnightTimeIfEmpty() public static method

Permet d'affecter un time à 23:59:59.999 à une date qui n'a pas de time
public static ToMidnightTimeIfEmpty ( this date ) : System.DateTime
date this
return System.DateTime

ToShortDate() public static method

new DateTime(2008, 8, 29, 19, 27, 15) ==> août 2008
public static ToShortDate ( this d ) : String
d this
return String

ToShortDateTimeString() public static method

public static ToShortDateTimeString ( this d ) : String
d this
return String

ToShortFrenchTimeString() public static method

public static ToShortFrenchTimeString ( this d ) : String
d this
return String

ToShortISO() public static method

public static ToShortISO ( this d ) : String
d this
return String

ToShortUpperDay() public static method

public static ToShortUpperDay ( this d ) : String
d this
return String

ToShortUpperMonth() public static method

public static ToShortUpperMonth ( this d ) : String
d this
return String

toShortUserFormat() public static method

public static toShortUserFormat ( this date, int format ) : String
date this
format int
return String

weekNumber() public static method

public static weekNumber ( this d ) : int
d this
return int

Property Details

dayText public static property

public static String[] dayText
return String[]