00001 
00002 
00003 
00004 
00005 
00006 
00007 #ifndef COH_RAW_DATE_TIME_HPP
00008 #define COH_RAW_DATE_TIME_HPP
00009 
00010 #include "coherence/lang.ns"
00011 
00012 #include "coherence/io/pof/PofIntrinsic.hpp"
00013 #include "coherence/io/pof/RawDate.hpp"
00014 #include "coherence/io/pof/RawTime.hpp"
00015 
00016 
00017 #include <time.h>
00018 
00019 COH_OPEN_NAMESPACE3(coherence,io,pof)
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 class COH_EXPORT RawDateTime
00028     : public cloneable_spec<RawDateTime,
00029           extends<Object>,
00030           implements<PofIntrinsic> >
00031     {
00032     friend class factory<RawDateTime>;
00033 
00034     
00035 
00036     public:
00037 
00038 
00039 
00040         typedef struct tm BoxedType;
00041 
00042 
00043     
00044 
00045     protected:
00046 
00047 
00048 
00049 
00050 
00051 
00052 
00053 
00054         RawDateTime(RawDate::View vDate, RawTime::View vTime);
00055 
00056 
00057 
00058 
00059 
00060 
00061 
00062 
00063 
00064 
00065 
00066         RawDateTime(const struct tm& timeinfo, bool fUTC = false);
00067 
00068 
00069 
00070 
00071         RawDateTime(const RawDateTime& that);
00072 
00073 
00074     
00075 
00076     public:
00077 
00078 
00079 
00080         virtual bool equals(Object::View v) const;
00081 
00082 
00083 
00084 
00085         virtual size32_t hashCode() const;
00086 
00087 
00088 
00089 
00090         virtual bool isImmutable() const;
00091 
00092 
00093 
00094 
00095         virtual TypedHandle<const String> toString() const;
00096 
00097 
00098     
00099 
00100     public:
00101 
00102 
00103 
00104 
00105 
00106         virtual RawDate::View getRawDate() const;
00107 
00108 
00109 
00110 
00111 
00112 
00113         virtual RawTime::View getRawTime() const;
00114 
00115 
00116 
00117 
00118 
00119 
00120 
00121         virtual operator struct tm() const;
00122 
00123 
00124     
00125 
00126     protected:
00127 
00128 
00129 
00130         FinalView<RawDate> f_vDate;
00131 
00132 
00133 
00134 
00135         FinalView<RawTime> f_vTime;
00136     };
00137 
00138 COH_CLOSE_NAMESPACE3
00139 
00140 #endif // COH_RAW_DATE_TIME_HPP