TAO_TIO.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 //=============================================================================
00004 /**
00005  *  @file    TAO_TIO.h
00006  *
00007  *  $Id: TAO_TIO.h 77001 2007-02-12 07:54:49Z johnnyw $
00008  *
00009  *  This class implements the CosTime::TIO IDL interface.
00010  *
00011  *
00012  *  @author Vishal Kachroo  <vishal@cs.wustl.edu>
00013  */
00014 //=============================================================================
00015 
00016 
00017 #ifndef TAO_TIO_H
00018 #define TAO_TIO_H
00019 #include /**/ "ace/pre.h"
00020 
00021 #include "orbsvcs/TimeServiceS.h"
00022 #include "orbsvcs/Time/TAO_UTO.h"
00023 #include "orbsvcs/Time/time_export.h"
00024 
00025 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00026 
00027 /**
00028  * @class TAO_TIO
00029  *
00030  * @brief Time Interval Object Implementation.
00031  *
00032  * The TIO represents a time interval and has operations to
00033  * compare itself with a UTO or another TIO. It also has an
00034  * operation to create a UTO from the value of it's time
00035  * interval.
00036  */
00037 class TAO_Time_Export TAO_TIO : public POA_CosTime::TIO
00038 {
00039 public:
00040   // = Initialization and termination methods.
00041   /// Constructor.
00042   TAO_TIO (TimeBase::TimeT lower,
00043            TimeBase::TimeT upper);
00044 
00045   /// Destructor.
00046   ~TAO_TIO (void);
00047 
00048   /// This is the get method for the attribute time interval.
00049   virtual TimeBase::IntervalT  time_interval ();
00050 
00051   /**
00052    * This operation returns a value of type OverlapType depending on
00053    * how the interval in the object and the time range represented by
00054    * the parameter UTO overlap.  If OverlapType is not OTNoOverlap,
00055    * then the out parameter overlap contains the overlap interval,
00056    * otherwise the out parameter contains the gap between the two
00057    * intervals.
00058    */
00059   virtual CosTime::OverlapType spans (CosTime::UTO_ptr time,
00060                                       CosTime::TIO_out overlap);
00061 
00062   /**
00063    * This operation returns a value of type OverlapType depending on
00064    * how the interval in the object and interval in the parameter TIO
00065    * overlap. If OverlapType is not OTNoOverlap, then the out
00066    * parameter overlap contains the overlap interval, otherwise the
00067    * out parameter contains the gap between the two intervals.
00068    */
00069   virtual CosTime::OverlapType overlaps (CosTime::TIO_ptr interval,
00070                                          CosTime::TIO_out overlap);
00071 
00072   /**
00073    * Returns a UTO in which the inaccuracy interval is equal to the
00074    * time interval in the TIO and time value is the midpoint of the
00075    * interval.
00076    */
00077   virtual CosTime::UTO_ptr time (void);
00078 
00079 private:
00080   /// This attribute returns an IntervalT structure with the values of
00081   /// its fields filled in with the corresponding values from the TIO.
00082   TimeBase::IntervalT attr_time_interval;
00083 };
00084 
00085 TAO_END_VERSIONED_NAMESPACE_DECL
00086 
00087 #include /**/ "ace/post.h"
00088 #endif /* TAO_TIO_H */

Generated on Tue Feb 2 17:49:17 2010 for TAO_CosTime by  doxygen 1.4.7