ACE  6.0.7
Public Member Functions | Private Attributes
ACE_Countdown_Time_T Class Reference

#include <Countdown_Time_T.h>

Inheritance diagram for ACE_Countdown_Time_T:
Inheritance graph
[legend]
Collaboration diagram for ACE_Countdown_Time_T:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ACE_Countdown_Time_T (ACE_Time_Value *max_wait_time, TIME_POLICY const &time_policy=TIME_POLICY())
 Cache the max_wait_time and call start().
 ~ACE_Countdown_Time_T (void)
void start (void)
 Cache the current time and enter a start state.
void stop (void)
void update (void)
bool stopped (void) const
 Returns true if we've already been stopped, else false.
void set_time_policy (TIME_POLICY const &time_policy)

Private Attributes

TIME_POLICY time_policy_
 The policy to return the current time of day.
ACE_Time_Valuemax_wait_time_
 Maximum time we were willing to wait.
ACE_Time_Value start_time_
 Beginning of the start time.
bool stopped_
 Keeps track of whether we've already been stopped.

Constructor & Destructor Documentation

ACE_Countdown_Time_T::ACE_Countdown_Time_T ( ACE_Time_Value max_wait_time,
TIME_POLICY const &  time_policy = TIME_POLICY() 
) [inline]

Cache the max_wait_time and call start().

ACE_Countdown_Time_T::~ACE_Countdown_Time_T ( void  ) [inline]

Destructor, makes sure the max_wait_time that got passed as pointer to the constructor is updated with the time elapsed.


Member Function Documentation

void ACE_Countdown_Time_T::set_time_policy ( TIME_POLICY const &  time_policy) [inline]

Allows applications to control how the timer queue gets the time of day.

void ACE_Countdown_Time_T::start ( void  ) [inline]

Cache the current time and enter a start state.

void ACE_Countdown_Time_T::stop ( void  ) [inline]

Subtract the elapsed time from max_wait_time_ and enter a stopped state.

bool ACE_Countdown_Time_T::stopped ( void  ) const [inline]

Returns true if we've already been stopped, else false.

void ACE_Countdown_Time_T::update ( void  ) [inline]

Calls stop and then start. max_wait_time_ is modified by the call to stop.


Member Data Documentation

Maximum time we were willing to wait.

Beginning of the start time.

Keeps track of whether we've already been stopped.

TIME_POLICY ACE_Countdown_Time_T::time_policy_ [private]

The policy to return the current time of day.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines