Loading...
Searching...
No Matches
dtintrv.h
Go to the documentation of this file.
// © 2016 and later: Unicode, Inc. and others.
// License & terms of use: http://www.unicode.org/copyright.html
/*
*******************************************************************************
* Copyright (C) 2008-2009, International Business Machines Corporation and
* others. All Rights Reserved.
*******************************************************************************
*
* File DTINTRV.H
*
*******************************************************************************
*/
#ifndef __DTINTRV_H__
#define __DTINTRV_H__
#include "unicode/utypes.h"
#if U_SHOW_CPLUSPLUS_API
#include "unicode/uobject.h"
U_NAMESPACE_BEGIN
class U_COMMON_API DateInterval : public UObject {
public:
DateInterval(UDate fromDate, UDate toDate);
virtual ~DateInterval();
inline UDate getFromDate() const;
inline UDate getToDate() const;
static UClassID U_EXPORT2 getStaticClassID();
virtual UClassID getDynamicClassID() const override;
DateInterval(const DateInterval& other);
DateInterval& operator=(const DateInterval&);
virtual bool operator==(const DateInterval& other) const;
inline bool operator!=(const DateInterval& other) const;
virtual DateInterval* clone() const;
private:
DateInterval() = delete;
UDate fromDate;
UDate toDate;
} ;// end class DateInterval
inline UDate
DateInterval::getFromDate() const {
return fromDate;
}
inline UDate
DateInterval::getToDate() const {
return toDate;
}
inline bool
DateInterval::operator!=(const DateInterval& other) const {
return ( !operator==(other) );
}
U_NAMESPACE_END
#endif /* U_SHOW_CPLUSPLUS_API */
#endif
icu::DateInterval::getToDate
UDate getToDate() const
Get the to date.
Definition dtintrv.h:148
icu::DateInterval::~DateInterval
virtual ~DateInterval()
destructor
icu::DateInterval::operator==
virtual bool operator==(const DateInterval &other) const
Equality operator.
icu::DateInterval::operator!=
bool operator!=(const DateInterval &other) const
Non-equality operator.
Definition dtintrv.h:154
icu::DateInterval::clone
virtual DateInterval * clone() const
clone this object.
icu::DateInterval::DateInterval
DateInterval(const DateInterval &other)
Copy constructor.
icu::DateInterval::getFromDate
UDate getFromDate() const
Get the from date.
Definition dtintrv.h:142
icu::DateInterval::getStaticClassID
static UClassID getStaticClassID()
Return the class ID for this class.
icu::DateInterval::getDynamicClassID
virtual UClassID getDynamicClassID() const override
Returns a unique class ID POLYMORPHICALLY.
icu::DateInterval::operator=
DateInterval & operator=(const DateInterval &)
Default assignment operator.
icu::DateInterval::DateInterval
DateInterval(UDate fromDate, UDate toDate)
Construct a DateInterval given a from date and a to date.
icu::UObject
UObject is the common ICU "boilerplate" class.
Definition uobject.h:222
icu::operator!=
bool operator!=(const StringPiece &x, const StringPiece &y)
Global operator != for StringPiece.
Definition stringpiece.h:346
uobject.h
C++ API: Common ICU base class UObject.
UClassID
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
Definition uobject.h:96
utypes.h
Basic definitions for ICU, for both C and C++ APIs.
U_COMMON_API
#define U_COMMON_API
Set to export library symbols from inside the common library, and to import them from outside.
Definition utypes.h:315
UDate
double UDate
Date and Time data type.
Definition utypes.h:218