Class: TSQLDate

Declaration: SQLClock.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

TTime

Inherited By:

TSQLTimestamp

Purpose:

TSQLDate is a concrete class with an accuracy of up to a second. It is intended for calendars, appointments, or any other client context that demands a time based on a reference date. Time is measured in seconds from the reference date of March 1, 2000. Dates earlier than the reference date are negative. Later dates are positive.

Instantiation:

Allocate on the heap or the stack.

Deriving Classes:

None.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Other Considerations:

None.

Member Function: TSQLDate::TSQLDate

  1. TSQLDate ()
  2. TSQLDate (const TSQLDate & time)
  3. TSQLDate (const TSQLTimestamp & time)
  4. TSQLDate (double secs)

Interface Category:

API.

Purpose:

  1. Default constructor.
  2. Copy constructor.
  3. Constructs a date from a time stamp.
  4. Constructs a date object based on the specified number of seconds from a reference date.

Calling Context:

  1. Called by the stream-in operators and any other function that needs to construct an uninitialized object.
  2. Called to copy an object.
  3. Call this function directly.
  4. Call this function directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TSQLDate::~TSQLDate

virtual ~ TSQLDate ()

Interface Category:

API.

Purpose:

Destructor.

Calling Context:

Called to destroy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TSQLDate::operator=

TSQLDate & operator =(const TSQLDate &)

Interface Category:

API.

Purpose:

Assignment operator.

Calling Context:

Called when an object is assigned to another compatible object.

Parameters:

Return Value:

A non-const reference to the left-hand side object.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TSQLDate::GetSeconds

virtual double GetSeconds () const

Interface Category:

API.

Purpose:

Returns the number of seconds elapsed since the reference date. Negative values indicate dates preceding the reference date.

Calling Context:

Call this function directly.

Parameters:

Return Value:

The number of seconds elapsed since the reference date.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.