27 #ifndef ArrayTimeInterval_CLASS
28 #define ArrayTimeInterval_CLASS
36 #include <asdmIDLTypesC.h>
67 double durationInDays);
70 int64_t durationInNanoSeconds);
159 static void toBin(
const std::vector<ArrayTimeInterval>& arrayTimeInterval,
EndianOSStream& eoss);
166 static void toBin(
const std::vector<std::vector<ArrayTimeInterval> >& arrayTimeInterval,
EndianOSStream& eoss);
173 static void toBin(
const std::vector<std::vector<std::vector<ArrayTimeInterval> > >& arrayTimeInterval,
EndianOSStream& eoss);
224 duration((int64_t) (
ArrayTime::unitsInADay * durationInDays)){}
227 int64_t durationInNanoSeconds){
228 start = startInNanoSeconds;
243 start(startInNanoSeconds) {
261 this->duration =
Interval(duration);
270 this->duration =
Interval(duration);
316 return (start2 <= start1 && end2 >= start1) ||
317 (start2 >= start1 && start2 <= end1);
327 return (start2>=start1 && end2<=end1);
335 return (time >= start1 && time < end1);
357 #endif // ArrayTimeInterval_CLASS
static bool readStartTimeDurationInXML()
Returns a boolean value whose meaning is defined as follows: true <=> the representation of ArrayTime...
The Interval class implements an interval of time in units of nanoseconds.
friend std::ostream & operator<<(std::ostream &, ArrayTimeInterval &)
void setStart(ArrayTime start)
Setters.
bool equals(ArrayTimeInterval ati)
Checkers.
ArrayTime getMidPoint() const
The ArrayTimeInterval class aggregates an instance of ArrayTime and an instance of Interval...
std::istream & operator>>(std::istream &, EntityId &)
int64_t getDurationInNanoSeconds() const
std::string toString() const
Returns a string representation of this.
static std::vector< std::vector< ArrayTimeInterval > > from2DBin(EndianIStream &eis)
Read the binary representation of a vector of vector of ArrayTimeInterval from an EndianIStream and u...
static std::vector< ArrayTimeInterval > from1DBin(EndianIStream &eis)
Read the binary representation of a vector of ArrayTimeInterval from an EndianIStream and use the rea...
ABSTRACT TOOL CLASSES A PlotTool is a higher level event handler for a PlotCanvas The idea is to take common tasks which may require multiple events and put them in one place PlotTools also provide additional functionality in that they can be active and blocking non blocking The PlotCanvas will only send events to active and will not send events to later tools or event handlers if the latest tool was blocking In this way a single tool can be used to handle ALL user interaction via the GUI at one time
ArrayTimeInterval()
Constructors.
static const int64_t MAX_VALUE
The maximum value for a int64_t.
static bool readStartTimeDurationInBin()
Returns a boolean value whose meaning is defined as follows: true <=> the representation of ArrayTime...
static bool readStartTimeDurationInBin_
ArrayTime getStart() const
Getters.
static bool readStartTimeDurationInXML_
bool operator!=(ArrayTimeInterval &)
double getStartInMJD() const
static double getMJD(double jd)
std::ostream & operator<<(std::ostream &, const EntityId &)
Friend functions.
void toBin(EndianOSStream &eoss) const
Write the binary representation of this to a EndianOSStream.
bool contains(ArrayTimeInterval ati)
static ArrayTimeInterval fromBin(EndianIStream &eis)
Read the binary representation of an ArrayTimeInterval from a EndianIStream and use the read value to...
bool overlaps(ArrayTimeInterval ati)
bool operator==(ArrayTimeInterval &)
Operators.
static const double unitsInADay
The ArrayTime class implements the concept of a point in time, implemented as an Interval of time sin...
const asdmIDLTypes::IDLArrayTimeInterval toIDLArrayTimeInterval() const
To IDL conversion.
int64_t getStartInNanoSeconds() const
Interval getDuration() const
double getDurationInDays() const
void setDuration(Interval duration)
static std::vector< std::vector< std::vector< ArrayTimeInterval > > > from3DBin(EndianIStream &eis)
Read the binary representation of a vector of vector of vector of ArrayTimeInterval from an EndianISt...
friend std::istream & operator>>(std::istream &, ArrayTimeInterval &)