Open Reality Reference Guide
FBTimeSpan Class Reference

TimeSpan class. More...

#include <fbtime.h>

Public Member Functions

 FBTimeSpan (FBTime pStart=0, FBTime pStop=0)
 Constructor. More...
 
void Set (FBTime pStart, FBTime pStop)
 Set the TimeSpan. More...
 
FBTime GetDuration ()
 Get the unsigned duration value of a timespan. More...
 
FBTime GetSignedDuration ()
 Get the signed duration value of a timespan. More...
 
int GetDirection ()
 Get the direction of the timespan. More...
 
bool operator & (FBTime &pTime)
 Verify if pTime is contained within the timespan. More...
 
FBTimeSpan operator & (FBTimeSpan &pTimeSpan)
 Calculate the intersection of two timespans. More...
 
FBTimeGetStart ()
 Get the start/stop time. More...
 
FBTimeGetStop ()
 Get the start/stop time. More...
 
const FBTimeGetStart () const
 Get the start/stop time. More...
 
const FBTimeGetStop () const
 Get the start/stop time. More...
 

Detailed Description

TimeSpan class.

Definition at line 383 of file fbtime.h.

Constructor & Destructor Documentation

◆ FBTimeSpan()

FBTimeSpan ( FBTime  pStart = 0,
FBTime  pStop = 0 
)

Constructor.

Parameters
pStartStart time(default=0).
pStopStop time(default=0).

Member Function Documentation

◆ GetDirection()

int GetDirection ( )

Get the direction of the timespan.

Returns 1 if positive, -1 otherwise.

Returns
Direction of timespan.

◆ GetDuration()

FBTime GetDuration ( )

Get the unsigned duration value of a timespan.

Returns
Unsigned duration of the timespan.

◆ GetSignedDuration()

FBTime GetSignedDuration ( )

Get the signed duration value of a timespan.

Returns
Signed duration of the timespan.

◆ GetStart() [1/2]

FBTime& GetStart ( )

Get the start/stop time.

Returns
Start/Stop time.

◆ GetStart() [2/2]

const FBTime& GetStart ( ) const

Get the start/stop time.

Returns
Start/Stop time.

◆ GetStop() [1/2]

FBTime& GetStop ( )

Get the start/stop time.

Returns
Start/Stop time.

◆ GetStop() [2/2]

const FBTime& GetStop ( ) const

Get the start/stop time.

Returns
Start/Stop time.

◆ operator &() [1/2]

bool operator& ( FBTime pTime)

Verify if pTime is contained within the timespan.

Parameters
pTimeTime to verify if within the timespan.
Returns
true if pTime is within the timespan.

◆ operator &() [2/2]

FBTimeSpan operator& ( FBTimeSpan pTimeSpan)

Calculate the intersection of two timespans.

Returns
Timespan representing the intersection of the two timespans.

◆ Set()

void Set ( FBTime  pStart,
FBTime  pStop 
)

Set the TimeSpan.

Parameters
pStartStart time.
pStopStop time.

The documentation for this class was generated from the following file: