ICU 50.1.2  50.1.2
dtintrv.h
Go to the documentation of this file.
1 /*
2 *******************************************************************************
3 * Copyright (C) 2008-2009, International Business Machines Corporation and
4 * others. All Rights Reserved.
5 *******************************************************************************
6 *
7 * File DTINTRV.H
8 *
9 *******************************************************************************
10 */
11 
12 #ifndef __DTINTRV_H__
13 #define __DTINTRV_H__
14 
15 #include "unicode/utypes.h"
16 #include "unicode/uobject.h"
17 
25 
26 
33 public:
34 
41  DateInterval(UDate fromDate, UDate toDate);
42 
47  virtual ~DateInterval();
48 
54  UDate getFromDate() const;
55 
61  UDate getToDate() const;
62 
63 
75  static UClassID U_EXPORT2 getStaticClassID(void);
76 
88  virtual UClassID getDynamicClassID(void) const;
89 
90 
95  DateInterval(const DateInterval& other);
96 
101  DateInterval& operator=(const DateInterval&);
102 
108  virtual UBool operator==(const DateInterval& other) const;
109 
115  UBool operator!=(const DateInterval& other) const;
116 
117 
124  virtual DateInterval* clone() const;
125 
126 private:
130  DateInterval();
131 
132  UDate fromDate;
133  UDate toDate;
134 
135 } ;// end class DateInterval
136 
137 
138 inline UDate
139 DateInterval::getFromDate() const {
140  return fromDate;
141 }
142 
143 
144 inline UDate
145 DateInterval::getToDate() const {
146  return toDate;
147 }
148 
149 
150 inline UBool
152  return ( !operator==(other) );
153 }
154 
155 
157 
158 #endif
double UDate
Date and Time data type.
Definition: utypes.h:201
virtual UClassID getDynamicClassID() const =0
ICU4C "poor man's RTTI", returns a UClassID for the actual ICU class.
U_EXPORT UBool operator==(const StringPiece &x, const StringPiece &y)
Global operator == for StringPiece.
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
Definition: uobject.h:96
This class represents a date interval.
Definition: dtintrv.h:32
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
Definition: uversion.h:129
UBool operator!=(const StringPiece &x, const StringPiece &y)
Global operator != for StringPiece.
Definition: stringpiece.h:218
C++ API: Common ICU base class UObject.
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
Definition: uversion.h:130
Basic definitions for ICU, for both C and C++ APIs.
#define U_COMMON_API
Set to export library symbols from inside the common library, and to import them from outside...
Definition: utypes.h:357
UObject is the common ICU "boilerplate" class.
Definition: uobject.h:229
int8_t UBool
The ICU boolean type.
Definition: umachine.h:200