Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
1 /*
2 *****************************************************************************
3 * Copyright (C) 2013, International Business Machines Corporation
4 * and others. All Rights Reserved.
5 *****************************************************************************
6 *
7 * File DANGICAL.H
8 *****************************************************************************
9 */
11 #ifndef DANGICAL_H
12 #define DANGICAL_H
14 #include "unicode/utypes.h"
16 #if !UCONFIG_NO_FORMATTING
18 #include "unicode/calendar.h"
19 #include "unicode/timezone.h"
20 #include "chnsecal.h"
22 U_NAMESPACE_BEGIN
24 /**
25 * <p><code>DangiCalendar</code> is a concrete subclass of {@link Calendar}
26 * that implements a traditional Korean lunisolar calendar.</p>
27 *
28 * <p>DangiCalendar usually should be instantiated using
29 * {@link com.ibm.icu.util.Calendar#getInstance(ULocale)} passing in a <code>ULocale</code>
30 * with the tag <code>"@calendar=dangi"</code>.</p>
31 *
32 * @internal
33 */
34 class DangiCalendar : public ChineseCalendar {
35 public:
36 //-------------------------------------------------------------------------
37 // Constructors...
38 //-------------------------------------------------------------------------
40 /**
41 * Constructs a DangiCalendar based on the current time in the default time zone
42 * with the given locale.
43 *
44 * @param aLocale The given locale.
45 * @param success Indicates the status of DangiCalendar object construction.
46 * Returns U_ZERO_ERROR if constructed successfully.
47 * @internal
48 */
49 DangiCalendar(const Locale& aLocale, UErrorCode &success);
51 /**
52 * Copy Constructor
53 * @internal
54 */
55 DangiCalendar(const DangiCalendar& other);
57 /**
58 * Destructor.
59 * @internal
60 */
61 virtual ~DangiCalendar();
63 /**
64 * Clone.
65 * @internal
66 */
67 virtual Calendar* clone() const;
69 //----------------------------------------------------------------------
70 // Internal methods & astronomical calculations
71 //----------------------------------------------------------------------
73 private:
75 const TimeZone* getDangiCalZoneAstroCalc(void) const;
77 // UObject stuff
78 public:
79 /**
80 * @return The class ID for this object. All objects of a given class have the
81 * same class ID. Objects of other classes have different class IDs.
82 * @internal
83 */
84 virtual UClassID getDynamicClassID(void) const;
86 /**
87 * Return the class ID for this class. This is useful only for comparing to a return
88 * value from getDynamicClassID(). For example:
89 *
90 * Base* polymorphic_pointer = createPolymorphicObject();
91 * if (polymorphic_pointer->getDynamicClassID() ==
92 * Derived::getStaticClassID()) ...
93 *
94 * @return The class ID for all objects of this class.
95 * @internal
96 */
97 U_I18N_API static UClassID U_EXPORT2 getStaticClassID(void);
99 /**
100 * return the calendar type, "dangi".
101 *
102 * @return calendar type
103 * @internal
104 */
105 const char * getType() const;
108 private:
110 DangiCalendar(); // default constructor not implemented
111 };
113 U_NAMESPACE_END
115 #endif
116 #endif