C# Class HandCoded.Finance.Time

Inheritance: Temporal, IComparable
Datei anzeigen Open project: formicary/fpml-toolkit-csharp Class Usage Examples

Public Properties

Property Type Description
END_OF_DAY Time
START_OF_DAY Time

Public Methods

Method Description
CompareTo ( Object other ) : int

Returns the result of comparing this instance to another Object.

CompareTo ( Time other ) : int

Returns the result of comparing this instance to another Time instance.

Equals ( Time other ) : bool

Determines if the Time instance and another hold the same value.

Equals ( object other ) : bool

Determines if the Time instance and another Object hold the same value.

GetHashCode ( ) : int

Returns the hash value of the date for hash based data structures and algorithms.

Parse ( string text ) : Time

Parses a character string in the format HH:MM:SS and uses the extracted values to construct a Time instance.

Time ( int hours, int minutes ) : System

Constructs a Time instance based on the supplied hour and minute values.

Time ( int hours, int minutes, decimal seconds, bool utc ) : System

Constructs a Time instance based on the supplied hour, minute and seconds values.

Time ( int hours, int minutes, decimal seconds, int offset ) : System

Constructs a Time instance based on the supplied hour, minute and seconds values.

Time ( int hours, int minutes, int seconds ) : System

Constructs a Time instance based on the supplied hour, minute and seconds values.

Time ( int hours, int minutes, int seconds, bool utc ) : System

Constructs a Time instance based on the supplied hour, minute and seconds values.

Time ( int hours, int minutes, int seconds, int offset ) : System

Constructs a Time instance based on the supplied hour, minute and seconds values.

ToString ( ) : string

Converts the value of this Time instance into a string for display in full ISO format (e.g. HH:MM:SS[.S+][[Z|+HH:MM|-HH:MM]]).

Private Methods

Method Description
Time ( TimeValue timeValue, TimeZone timeZone ) : System

Constructs a Time from its time and time zone components.

ToDateTime ( ) : DateTime

Creates a DateTime instance from the current time.

Method Details

CompareTo() public method

Returns the result of comparing this instance to another Object.
public CompareTo ( Object other ) : int
other Object The other instance to compare with.
return int

CompareTo() public method

Returns the result of comparing this instance to another Time instance.
public CompareTo ( Time other ) : int
other Time The other Time instance to compare with.
return int

Equals() public method

Determines if the Time instance and another hold the same value.
public Equals ( Time other ) : bool
other Time The to compare with.
return bool

Equals() public method

Determines if the Time instance and another Object hold the same value.
public Equals ( object other ) : bool
other object The to compare with.
return bool

GetHashCode() public method

Returns the hash value of the date for hash based data structures and algorithms.
public GetHashCode ( ) : int
return int

Parse() public static method

Parses a character string in the format HH:MM:SS and uses the extracted values to construct a Time instance.
If the character string is not /// in the correct format or the hour, minute or second values are outside /// the correct range.
public static Parse ( string text ) : Time
text string The character string to be parsed.
return Time

Time() public method

Constructs a Time instance based on the supplied hour and minute values.
public Time ( int hours, int minutes ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
return System

Time() public method

Constructs a Time instance based on the supplied hour, minute and seconds values.
public Time ( int hours, int minutes, decimal seconds, bool utc ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
seconds decimal The number of seconds (0-59.99).
utc bool Indicates UTC time zone.
return System

Time() public method

Constructs a Time instance based on the supplied hour, minute and seconds values.
public Time ( int hours, int minutes, decimal seconds, int offset ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
seconds decimal The number of seconds (0-59.99).
offset int The time zone offset.
return System

Time() public method

Constructs a Time instance based on the supplied hour, minute and seconds values.
public Time ( int hours, int minutes, int seconds ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
seconds int The number of seconds (0-59).
return System

Time() public method

Constructs a Time instance based on the supplied hour, minute and seconds values.
public Time ( int hours, int minutes, int seconds, bool utc ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
seconds int The number of seconds (0-59).
utc bool Indicates UTC time zone.
return System

Time() public method

Constructs a Time instance based on the supplied hour, minute and seconds values.
public Time ( int hours, int minutes, int seconds, int offset ) : System
hours int The number of hours (0-24).
minutes int The number of minutes (0-59).
seconds int The number of seconds (0-59).
offset int The time zone offset.
return System

ToString() public method

Converts the value of this Time instance into a string for display in full ISO format (e.g. HH:MM:SS[.S+][[Z|+HH:MM|-HH:MM]]).
public ToString ( ) : string
return string

Property Details

END_OF_DAY public_oe static_oe property

A constant Time instance representing the last instant of the day.
public static Time,HandCoded.Finance END_OF_DAY
return Time

START_OF_DAY public_oe static_oe property

A constant Time instance representing the first instant of the day.
public static Time,HandCoded.Finance START_OF_DAY
return Time