C# Class XSerializer.DefaultDateTimeHandler

The default implementation of IDateTimeHandler. Expects values to be in the "yyyy-MM-ddTHH:mm:ss.fffffffK" format.
Inheritance: IDateTimeHandler
Show file Open project: QuickenLoans/XSerializer

Public Methods

Method Description
Equals ( object obj ) : bool

Determines whether the specified object is equal to the current object.

GetHashCode ( ) : int

Serves as a hash function for a particular type.

ParseDateTime ( string value ) : System.DateTime

Parse the given string representation into a DateTime value.

ParseDateTimeOffset ( string value ) : DateTimeOffset

Parse the given string representation into a DateTimeOffset value.

Private Methods

Method Description
Adjust ( int &year, int &month, int &day, int &hour, int &minute ) : void
AdvancePastFractionalPart ( int &formatIndex ) : void
GetDateTimeComponents ( string value, int &year, int &month, int &day, int &hour, int &minute, int &second, long &ticks, int &offsetHours, int &offsetMinutes, DateTimeKind &dateTimeKind ) : void
OverflowsMonth ( int day, int month, int year ) : bool
ParseFraction ( string sourceString, int &valueIndex, int &formatIndex ) : double
ParseOffset ( string sourceString, int i, int &offsetHours, int &offsetMinutes, DateTimeKind &dateTimeKind ) : void
ThrowIfNotDigit ( char c, int i, string sourceString, string dateTimePart ) : void

Method Details

Equals() public method

Determines whether the specified object is equal to the current object.
public Equals ( object obj ) : bool
obj object /// The to compare with the current . ///
return bool

GetHashCode() public method

Serves as a hash function for a particular type.
public GetHashCode ( ) : int
return int

ParseDateTime() public method

Parse the given string representation into a DateTime value.
public ParseDateTime ( string value ) : System.DateTime
value string A string representation of a date time.
return System.DateTime

ParseDateTimeOffset() public method

Parse the given string representation into a DateTimeOffset value.
public ParseDateTimeOffset ( string value ) : DateTimeOffset
value string A string representation of a date time.
return DateTimeOffset