# fedtime.hh

Go to the documentation of this file.

    00001 // HLA 1.3 Header "fedtime.hh"
    00002 // $Id: fedtime.hh,v 3.13 2009/04/02 19:58:11 erk Exp $
    00003
    00004 #ifndef HLA_FEDTIME_HH
    00005 #define HLA_FEDTIME_HH
    00006
    00007 #include "RTI.hh"
    00008 #include <sys/types.h>
    00009 #include <string.h>
    00010
    00011 class FEDTIME_EXPORT RTIfedTime : public RTI::FedTime
    00012 {
    00013 public:
    00014     RTIfedTime();
    00015     RTIfedTime(const RTI::Double &);
    00016     RTIfedTime(const RTI::FedTime &);
    00017     RTIfedTime(const RTIfedTime &);
    00018     virtual ~RTIfedTime();
    00019
    00020 public:
    00021     virtual void setZero();
    00022     virtual RTI::Boolean isZero();
    00023     virtual void setEpsilon();
    00024     virtual void setPositiveInfinity();
    00025     virtual RTI::Boolean isPositiveInfinity();
    00026     virtual int encodedLength() const;
    00027     virtual void encode(char *) const;
    00028     virtual int getPrintableLength() const;
    00029     virtual void getPrintableString(char *);
    00030
    00031     virtual RTI::FedTime& operator+=(const RTI::FedTime &)
    00032     throw (RTI::InvalidFederationTime);
    00033
    00034     virtual RTI::FedTime& operator-=(const RTI::FedTime &)
    00035     throw (RTI::InvalidFederationTime);
    00036
    00037     virtual RTI::Boolean operator<=(const RTI::FedTime &) const
    00038     throw (RTI::InvalidFederationTime);
    00039
    00040     virtual RTI::Boolean operator<(const RTI::FedTime &) const
    00041     throw (RTI::InvalidFederationTime);
    00042
    00043     virtual RTI::Boolean operator>=(const RTI::FedTime &) const
    00044     throw (RTI::InvalidFederationTime);
    00045
    00046     virtual RTI::Boolean operator>(const RTI::FedTime &) const
    00047     throw (RTI::InvalidFederationTime);
    00048
    00049     virtual RTI::Boolean operator==(const RTI::FedTime &) const
    00050     throw (RTI::InvalidFederationTime);
    00051
    00052     virtual RTI::FedTime & operator=(const RTI::FedTime &)
    00053     throw (RTI::InvalidFederationTime);
    00054
    00055     virtual RTI::Double getTime() const;
    00056
    00057     virtual RTI::Boolean operator==(const RTI::Double &) const
    00058     throw (RTI::InvalidFederationTime);
    00059
    00060     virtual RTI::Boolean operator!=(const RTI::FedTime &) const
    00061     throw (RTI::InvalidFederationTime);
    00062
    00063     virtual RTI::Boolean operator!=(const RTI::Double &) const
    00064     throw (RTI::InvalidFederationTime);
    00065
    00066     virtual RTI::FedTime &operator=(const RTIfedTime &)
    00067     throw (RTI::InvalidFederationTime);
    00068
    00069     virtual RTI::FedTime &operator=(const RTI::Double &)
    00070     throw (RTI::InvalidFederationTime);
    00071
    00072     virtual RTI::FedTime &operator*=(const RTI::FedTime &)
    00073     throw (RTI::InvalidFederationTime);
    00074
    00075     virtual RTI::FedTime &operator/=(const RTI::FedTime &)
    00076     throw (RTI::InvalidFederationTime);
    00077
    00078     virtual RTI::FedTime &operator+=(const RTI::Double &)
    00079     throw (RTI::InvalidFederationTime);
    00080
    00081     virtual RTI::FedTime &operator-=(const RTI::Double &)
    00082     throw (RTI::InvalidFederationTime);
    00083
    00084     virtual RTI::FedTime &operator*=(const RTI::Double &)
    00085     throw (RTI::InvalidFederationTime);
    00086
    00087     virtual RTI::FedTime &operator/=(const RTI::Double &)
    00088     throw (RTI::InvalidFederationTime);
    00089
    00090     virtual RTIfedTime operator+(const RTI::FedTime &)
    00091     throw (RTI::InvalidFederationTime);
    00092
    00093     virtual RTIfedTime operator+(const RTI::Double &)
    00094     throw (RTI::InvalidFederationTime);
    00095
    00096     virtual RTIfedTime operator-(const RTI::FedTime &)
    00097     throw (RTI::InvalidFederationTime);
    00098
    00099     virtual RTIfedTime operator-(const RTI::Double &)
    00100     throw (RTI::InvalidFederationTime);
    00101
    00102     virtual RTIfedTime operator*(const RTI::FedTime &)
    00103     throw (RTI::InvalidFederationTime);
    00104
    00105     virtual RTIfedTime operator*(const RTI::Double &)
    00106     throw (RTI::InvalidFederationTime);
    00107
    00108     virtual RTIfedTime operator/(const RTI::FedTime &)
    00109     throw (RTI::InvalidFederationTime);
    00110
    00111     virtual RTIfedTime operator/(const RTI::Double &)
    00112     throw (RTI::InvalidFederationTime);
    00113
    00114     friend RTI_STD::ostream FEDTIME_EXPORT &operator<<(RTI_STD::ostream&, const RTI::FedTime &);
    00115
    00116 private:
    00117     RTI::Double _fedTime ;
    00118     RTI::Double _zero ;
    00119     RTI::Double _epsilon ;
    00120     RTI::Double _positiveInfinity ;
    00121 };
    00122
    00123 RTIfedTime operator+(const RTI::Double &, const RTI::FedTime &);
    00124 RTIfedTime operator-(const RTI::Double &, const RTI::FedTime &);
    00125 RTIfedTime operator*(const RTI::Double &, const RTI::FedTime &);
    00126 RTIfedTime operator/(const RTI::Double &, const RTI::FedTime &);
    00127
    00128 #endif // HLA_FEDTIME_HH
    00129
    00130 // $Id: fedtime.hh,v 3.13 2009/04/02 19:58:11 erk Exp $