Revert "Minor modernization of DynamicAny code"
[ACE_TAO.git] / TAO / tao / PortableServer / Creation_Time.h
bloba3bfc8e440afa70846721ff7189d68285db34f00
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Creation_Time.h
7 * Header file for Creation_Time and Temporary_Creation_Time
9 * @author Irfan Pyarali <irfan@cs.wustl.edu>
11 //=============================================================================
13 #ifndef TAO_CREATION_TIME_H
14 #define TAO_CREATION_TIME_H
16 #include /**/ "ace/pre.h"
18 #include "ace/Time_Value.h"
19 #include "tao/Basic_Types.h"
21 #if !defined (ACE_LACKS_PRAGMA_ONCE)
22 # pragma once
23 #endif /* ACE_LACKS_PRAGMA_ONCE */
25 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
27 namespace TAO
29 namespace Portable_Server
31 class Temporary_Creation_Time;
33 class Creation_Time
35 public:
36 explicit Creation_Time (const ACE_Time_Value &creation_time);
38 Creation_Time ();
40 void creation_time (const void *creation_time);
42 const void *creation_time () const;
44 static CORBA::ULong creation_time_length ();
46 bool operator== (const Creation_Time &rhs) const;
48 bool operator!= (const Creation_Time &rhs) const;
50 bool operator== (const Temporary_Creation_Time &rhs) const;
52 bool operator!= (const Temporary_Creation_Time &rhs) const;
54 protected:
55 enum
57 SEC_FIELD = 0,
58 USEC_FIELD = 1
61 /// Timestamp
62 CORBA::ULong time_stamp_[2];
65 /**
66 * @class Temporary_Creation_Time
68 * @brief Special creation time only useful in the lifetime of the
69 * upcall.
71 * Special creation time only useful in the lifetime of the upcall.
73 class Temporary_Creation_Time
75 public:
76 Temporary_Creation_Time ();
78 void creation_time (const void *creation_time);
80 bool operator== (const Creation_Time &rhs) const;
82 bool operator!= (const Creation_Time &rhs) const;
84 protected:
85 void *time_stamp_;
90 TAO_END_VERSIONED_NAMESPACE_DECL
92 #if defined (__ACE_INLINE__)
93 # include "tao/PortableServer/Creation_Time.inl"
94 #endif /* __ACE_INLINE__ */
96 #include /**/ "ace/post.h"
98 #endif /* TAO_CREATION_TIME_H */