KTimeSpan
#include<ktime.h>

List of all members.

Detailed Description

Class to encapsulate time intervals.

Definition at line544of filektime.h.


Public Member Functions

 KTimeSpan()
 Constructor.
 KTimeSpan(KTimepStart,KTimepStop)
 Constructor.
void Set(KTimepStart,KTimepStop)
 Set start and stop time.
void SetStart(KTimepStart)
 Set start time.
void SetStop(KTimepStop)
 Set stop time.
KTimeGetStart()
 Get start time.
KTimeGetStop()
 Get stop time.
KTime GetDuration() const
 Get time interval in absolute value.
KTime GetSignedDuration() const
 Get time interval.
int GetDirection() const
 Get direction of the time interval.
bool operator&(KTime&pTime) const
 Returntrueif the time is inside the timespan.
KTimeSpan operator&(KTimeSpan&pTime) const
 Return the intersection of the two time spans.
bool operator!=(KTimeSpan&pTime)
 Inequality operator.

Constructor&Destructor Documentation

KTimeSpan( ) [inline]

Constructor.

Definition at line550of filektime.h.

KTimeSpan(KTime pStart,
KTime pStop 
)[inline]

Constructor.

Parameters:
pStart Beginning of the time interval.
pStop Ending of the time interval.

Definition at line556of filektime.h.

Member Function Documentation

void Set(KTime pStart,
KTime pStop 
)[inline]

Set start and stop time.

Parameters:
pStart Beginning of the time interval.
pStop Ending of the time interval.

Definition at line562of filektime.h.

void SetStart(KTime pStart ) [inline]

Set start time.

Parameters:
pStart Beginning of the time interval.

Definition at line567of filektime.h.

void SetStop(KTime pStop ) [inline]

Set stop time.

Parameters:
pStop Ending of the time interval.

Definition at line572of filektime.h.

KTime&GetStart( ) [inline]

Get start time.

Returns:
Beginning of time interval.

Definition at line577of filektime.h.

KTime&GetStop( ) [inline]

Get stop time.

Returns:
Ending of time interval.

Definition at line582of filektime.h.

KTimeGetDuration( ) const[inline]

Get time interval in absolute value.

Returns:
Time interval.

Definition at line587of filektime.h.

KTimeGetSignedDuration( ) const[inline]

Get time interval.

Returns:
Signed time interval.

Definition at line592of filektime.h.

int GetDirection( ) const[inline]

Get direction of the time interval.

Returns:
KTS_FORWARDif time interval is forward,KTS_BACKWARDif backward.

Definition at line597of filektime.h.

bool operator&(KTimepTime ) const

Returntrueif the time is inside the timespan.

Parameters:
pTime Judge whether pTime is inside the timespan.
Returns:
Trueif is,falseotherwise.

KTimeSpanoperator&(KTimeSpanpTime ) const

Return the intersection of the two time spans.

Parameters:
pTime 
Returns:
The intersection of pTime and thisKTimeSpan.

bool operator!=(KTimeSpanpTime ) 

Inequality operator.

Parameters:
pTime KTimeSpancompared with this one.
Returns:
Trueif unequal,falseotherwise.