201639f64ddd99a295d0c1461101efb192f70216
[jalviewjs.git] / site / swingjs / j2s / jssun / util / calendar / ImmutableGregorianDate.js
1 Clazz.declarePackage ("jssun.util.calendar");\r
2 Clazz.load (["jssun.util.calendar.BaseCalendar"], "jssun.util.calendar.ImmutableGregorianDate", ["java.lang.NullPointerException", "$.UnsupportedOperationException"], function () {\r
3 c$ = Clazz.decorateAsClass (function () {\r
4 this.date = null;\r
5 Clazz.instantialize (this, arguments);\r
6 }, jssun.util.calendar, "ImmutableGregorianDate", jssun.util.calendar.BaseCalendar.Date);\r
7 Clazz.makeConstructor (c$, \r
8 function (date) {\r
9 Clazz.superConstructor (this, jssun.util.calendar.ImmutableGregorianDate, []);\r
10 if (date == null) {\r
11 throw  new NullPointerException ();\r
12 }this.date = date;\r
13 }, "jssun.util.calendar.BaseCalendar.Date");\r
14 Clazz.defineMethod (c$, "getEra", \r
15 function () {\r
16 return this.date.getEra ();\r
17 });\r
18 Clazz.overrideMethod (c$, "setEra", \r
19 function (era) {\r
20 this.unsupported ();\r
21 return this;\r
22 }, "jssun.util.calendar.Era");\r
23 Clazz.defineMethod (c$, "getYear", \r
24 function () {\r
25 return this.date.getYear ();\r
26 });\r
27 Clazz.overrideMethod (c$, "setYear", \r
28 function (year) {\r
29 this.unsupported ();\r
30 return this;\r
31 }, "~N");\r
32 Clazz.overrideMethod (c$, "addYear", \r
33 function (n) {\r
34 this.unsupported ();\r
35 return this;\r
36 }, "~N");\r
37 Clazz.defineMethod (c$, "isLeapYear", \r
38 function () {\r
39 return this.date.isLeapYear ();\r
40 });\r
41 Clazz.overrideMethod (c$, "setLeapYear", \r
42 function (leapYear) {\r
43 this.unsupported ();\r
44 }, "~B");\r
45 Clazz.defineMethod (c$, "getMonth", \r
46 function () {\r
47 return this.date.getMonth ();\r
48 });\r
49 Clazz.overrideMethod (c$, "setMonth", \r
50 function (month) {\r
51 this.unsupported ();\r
52 return this;\r
53 }, "~N");\r
54 Clazz.overrideMethod (c$, "addMonth", \r
55 function (n) {\r
56 this.unsupported ();\r
57 return this;\r
58 }, "~N");\r
59 Clazz.defineMethod (c$, "getDayOfMonth", \r
60 function () {\r
61 return this.date.getDayOfMonth ();\r
62 });\r
63 Clazz.overrideMethod (c$, "setDayOfMonth", \r
64 function (date) {\r
65 this.unsupported ();\r
66 return this;\r
67 }, "~N");\r
68 Clazz.overrideMethod (c$, "addDayOfMonth", \r
69 function (n) {\r
70 this.unsupported ();\r
71 return this;\r
72 }, "~N");\r
73 Clazz.defineMethod (c$, "getDayOfWeek", \r
74 function () {\r
75 return this.date.getDayOfWeek ();\r
76 });\r
77 Clazz.defineMethod (c$, "getHours", \r
78 function () {\r
79 return this.date.getHours ();\r
80 });\r
81 Clazz.overrideMethod (c$, "setHours", \r
82 function (hours) {\r
83 this.unsupported ();\r
84 return this;\r
85 }, "~N");\r
86 Clazz.overrideMethod (c$, "addHours", \r
87 function (n) {\r
88 this.unsupported ();\r
89 return this;\r
90 }, "~N");\r
91 Clazz.defineMethod (c$, "getMinutes", \r
92 function () {\r
93 return this.date.getMinutes ();\r
94 });\r
95 Clazz.overrideMethod (c$, "setMinutes", \r
96 function (minutes) {\r
97 this.unsupported ();\r
98 return this;\r
99 }, "~N");\r
100 Clazz.overrideMethod (c$, "addMinutes", \r
101 function (n) {\r
102 this.unsupported ();\r
103 return this;\r
104 }, "~N");\r
105 Clazz.defineMethod (c$, "getSeconds", \r
106 function () {\r
107 return this.date.getSeconds ();\r
108 });\r
109 Clazz.overrideMethod (c$, "setSeconds", \r
110 function (seconds) {\r
111 this.unsupported ();\r
112 return this;\r
113 }, "~N");\r
114 Clazz.overrideMethod (c$, "addSeconds", \r
115 function (n) {\r
116 this.unsupported ();\r
117 return this;\r
118 }, "~N");\r
119 Clazz.defineMethod (c$, "getMillis", \r
120 function () {\r
121 return this.date.getMillis ();\r
122 });\r
123 Clazz.overrideMethod (c$, "setMillis", \r
124 function (millis) {\r
125 this.unsupported ();\r
126 return this;\r
127 }, "~N");\r
128 Clazz.overrideMethod (c$, "addMillis", \r
129 function (n) {\r
130 this.unsupported ();\r
131 return this;\r
132 }, "~N");\r
133 Clazz.defineMethod (c$, "getTimeOfDay", \r
134 function () {\r
135 return this.date.getTimeOfDay ();\r
136 });\r
137 Clazz.overrideMethod (c$, "setDate", \r
138 function (year, month, dayOfMonth) {\r
139 this.unsupported ();\r
140 return this;\r
141 }, "~N,~N,~N");\r
142 Clazz.overrideMethod (c$, "addDate", \r
143 function (year, month, dayOfMonth) {\r
144 this.unsupported ();\r
145 return this;\r
146 }, "~N,~N,~N");\r
147 Clazz.defineMethod (c$, "setTimeOfDay", \r
148 function (hours, minutes, seconds, millis) {\r
149 this.unsupported ();\r
150 return this;\r
151 }, "~N,~N,~N,~N");\r
152 Clazz.overrideMethod (c$, "addTimeOfDay", \r
153 function (hours, minutes, seconds, millis) {\r
154 this.unsupported ();\r
155 return this;\r
156 }, "~N,~N,~N,~N");\r
157 Clazz.defineMethod (c$, "setTimeOfDay", \r
158 function (fraction) {\r
159 this.unsupported ();\r
160 }, "~N");\r
161 Clazz.defineMethod (c$, "isNormalized", \r
162 function () {\r
163 return this.date.isNormalized ();\r
164 });\r
165 Clazz.defineMethod (c$, "isStandardTime", \r
166 function () {\r
167 return this.date.isStandardTime ();\r
168 });\r
169 Clazz.overrideMethod (c$, "setStandardTime", \r
170 function (standardTime) {\r
171 this.unsupported ();\r
172 }, "~B");\r
173 Clazz.defineMethod (c$, "isDaylightTime", \r
174 function () {\r
175 return this.date.isDaylightTime ();\r
176 });\r
177 Clazz.overrideMethod (c$, "setLocale", \r
178 function (loc) {\r
179 this.unsupported ();\r
180 }, "java.util.Locale");\r
181 Clazz.defineMethod (c$, "getZone", \r
182 function () {\r
183 return this.date.getZone ();\r
184 });\r
185 Clazz.overrideMethod (c$, "setZone", \r
186 function (zoneinfo) {\r
187 this.unsupported ();\r
188 return this;\r
189 }, "java.util.TimeZone");\r
190 Clazz.defineMethod (c$, "isSameDate", \r
191 function (date) {\r
192 return date.isSameDate (date);\r
193 }, "jssun.util.calendar.CalendarDate");\r
194 Clazz.defineMethod (c$, "equals", \r
195 function (obj) {\r
196 if (this === obj) {\r
197 return true;\r
198 }if (!(Clazz.instanceOf (obj, jssun.util.calendar.ImmutableGregorianDate))) {\r
199 return false;\r
200 }return this.date.equals ((obj).date);\r
201 }, "~O");\r
202 Clazz.defineMethod (c$, "hashCode", \r
203 function () {\r
204 return this.date.hashCode ();\r
205 });\r
206 Clazz.defineMethod (c$, "toString", \r
207 function () {\r
208 return this.date.toString ();\r
209 });\r
210 Clazz.overrideMethod (c$, "setDayOfWeek", \r
211 function (dayOfWeek) {\r
212 this.unsupported ();\r
213 }, "~N");\r
214 Clazz.overrideMethod (c$, "setNormalized", \r
215 function (normalized) {\r
216 this.unsupported ();\r
217 }, "~B");\r
218 Clazz.defineMethod (c$, "getZoneOffset", \r
219 function () {\r
220 return this.date.getZoneOffset ();\r
221 });\r
222 Clazz.overrideMethod (c$, "setZoneOffset", \r
223 function (offset) {\r
224 this.unsupported ();\r
225 }, "~N");\r
226 Clazz.defineMethod (c$, "getDaylightSaving", \r
227 function () {\r
228 return this.date.getDaylightSaving ();\r
229 });\r
230 Clazz.overrideMethod (c$, "setDaylightSaving", \r
231 function (daylightSaving) {\r
232 this.unsupported ();\r
233 }, "~N");\r
234 Clazz.defineMethod (c$, "getNormalizedYear", \r
235 function () {\r
236 return this.date.getNormalizedYear ();\r
237 });\r
238 Clazz.overrideMethod (c$, "setNormalizedYear", \r
239 function (normalizedYear) {\r
240 this.unsupported ();\r
241 }, "~N");\r
242 Clazz.defineMethod (c$, "unsupported", \r
243  function () {\r
244 throw  new UnsupportedOperationException ();\r
245 });\r
246 });\r