001
014
015 package com.liferay.portal.model;
016
017 import java.util.HashMap;
018 import java.util.Map;
019
020
029 public class CountryWrapper implements Country, ModelWrapper<Country> {
030 public CountryWrapper(Country country) {
031 _country = country;
032 }
033
034 public Class<?> getModelClass() {
035 return Country.class;
036 }
037
038 public String getModelClassName() {
039 return Country.class.getName();
040 }
041
042 public Map<String, Object> getModelAttributes() {
043 Map<String, Object> attributes = new HashMap<String, Object>();
044
045 attributes.put("countryId", getCountryId());
046 attributes.put("name", getName());
047 attributes.put("a2", getA2());
048 attributes.put("a3", getA3());
049 attributes.put("number", getNumber());
050 attributes.put("idd", getIdd());
051 attributes.put("zipRequired", getZipRequired());
052 attributes.put("active", getActive());
053
054 return attributes;
055 }
056
057 public void setModelAttributes(Map<String, Object> attributes) {
058 Long countryId = (Long)attributes.get("countryId");
059
060 if (countryId != null) {
061 setCountryId(countryId);
062 }
063
064 String name = (String)attributes.get("name");
065
066 if (name != null) {
067 setName(name);
068 }
069
070 String a2 = (String)attributes.get("a2");
071
072 if (a2 != null) {
073 setA2(a2);
074 }
075
076 String a3 = (String)attributes.get("a3");
077
078 if (a3 != null) {
079 setA3(a3);
080 }
081
082 String number = (String)attributes.get("number");
083
084 if (number != null) {
085 setNumber(number);
086 }
087
088 String idd = (String)attributes.get("idd");
089
090 if (idd != null) {
091 setIdd(idd);
092 }
093
094 Boolean zipRequired = (Boolean)attributes.get("zipRequired");
095
096 if (zipRequired != null) {
097 setZipRequired(zipRequired);
098 }
099
100 Boolean active = (Boolean)attributes.get("active");
101
102 if (active != null) {
103 setActive(active);
104 }
105 }
106
107
112 public long getPrimaryKey() {
113 return _country.getPrimaryKey();
114 }
115
116
121 public void setPrimaryKey(long primaryKey) {
122 _country.setPrimaryKey(primaryKey);
123 }
124
125
130 public long getCountryId() {
131 return _country.getCountryId();
132 }
133
134
139 public void setCountryId(long countryId) {
140 _country.setCountryId(countryId);
141 }
142
143
148 public java.lang.String getName() {
149 return _country.getName();
150 }
151
152
157 public void setName(java.lang.String name) {
158 _country.setName(name);
159 }
160
161
166 public java.lang.String getA2() {
167 return _country.getA2();
168 }
169
170
175 public void setA2(java.lang.String a2) {
176 _country.setA2(a2);
177 }
178
179
184 public java.lang.String getA3() {
185 return _country.getA3();
186 }
187
188
193 public void setA3(java.lang.String a3) {
194 _country.setA3(a3);
195 }
196
197
202 public java.lang.String getNumber() {
203 return _country.getNumber();
204 }
205
206
211 public void setNumber(java.lang.String number) {
212 _country.setNumber(number);
213 }
214
215
220 public java.lang.String getIdd() {
221 return _country.getIdd();
222 }
223
224
229 public void setIdd(java.lang.String idd) {
230 _country.setIdd(idd);
231 }
232
233
238 public boolean getZipRequired() {
239 return _country.getZipRequired();
240 }
241
242
247 public boolean isZipRequired() {
248 return _country.isZipRequired();
249 }
250
251
256 public void setZipRequired(boolean zipRequired) {
257 _country.setZipRequired(zipRequired);
258 }
259
260
265 public boolean getActive() {
266 return _country.getActive();
267 }
268
269
274 public boolean isActive() {
275 return _country.isActive();
276 }
277
278
283 public void setActive(boolean active) {
284 _country.setActive(active);
285 }
286
287 public boolean isNew() {
288 return _country.isNew();
289 }
290
291 public void setNew(boolean n) {
292 _country.setNew(n);
293 }
294
295 public boolean isCachedModel() {
296 return _country.isCachedModel();
297 }
298
299 public void setCachedModel(boolean cachedModel) {
300 _country.setCachedModel(cachedModel);
301 }
302
303 public boolean isEscapedModel() {
304 return _country.isEscapedModel();
305 }
306
307 public java.io.Serializable getPrimaryKeyObj() {
308 return _country.getPrimaryKeyObj();
309 }
310
311 public void setPrimaryKeyObj(java.io.Serializable primaryKeyObj) {
312 _country.setPrimaryKeyObj(primaryKeyObj);
313 }
314
315 public com.liferay.portlet.expando.model.ExpandoBridge getExpandoBridge() {
316 return _country.getExpandoBridge();
317 }
318
319 public void setExpandoBridgeAttributes(
320 com.liferay.portal.model.BaseModel<?> baseModel) {
321 _country.setExpandoBridgeAttributes(baseModel);
322 }
323
324 public void setExpandoBridgeAttributes(
325 com.liferay.portlet.expando.model.ExpandoBridge expandoBridge) {
326 _country.setExpandoBridgeAttributes(expandoBridge);
327 }
328
329 public void setExpandoBridgeAttributes(
330 com.liferay.portal.service.ServiceContext serviceContext) {
331 _country.setExpandoBridgeAttributes(serviceContext);
332 }
333
334 @Override
335 public java.lang.Object clone() {
336 return new CountryWrapper((Country)_country.clone());
337 }
338
339 public int compareTo(com.liferay.portal.model.Country country) {
340 return _country.compareTo(country);
341 }
342
343 @Override
344 public int hashCode() {
345 return _country.hashCode();
346 }
347
348 public com.liferay.portal.model.CacheModel<com.liferay.portal.model.Country> toCacheModel() {
349 return _country.toCacheModel();
350 }
351
352 public com.liferay.portal.model.Country toEscapedModel() {
353 return new CountryWrapper(_country.toEscapedModel());
354 }
355
356 public com.liferay.portal.model.Country toUnescapedModel() {
357 return new CountryWrapper(_country.toUnescapedModel());
358 }
359
360 @Override
361 public java.lang.String toString() {
362 return _country.toString();
363 }
364
365 public java.lang.String toXmlString() {
366 return _country.toXmlString();
367 }
368
369 public java.lang.String getName(java.util.Locale locale) {
370 return _country.getName(locale);
371 }
372
373 public java.lang.String getNameCurrentLanguageId() {
374 return _country.getNameCurrentLanguageId();
375 }
376
377 public java.lang.String getNameCurrentValue() {
378 return _country.getNameCurrentValue();
379 }
380
381 public void setNameCurrentLanguageId(java.lang.String languageId) {
382 _country.setNameCurrentLanguageId(languageId);
383 }
384
385
388 public Country getWrappedCountry() {
389 return _country;
390 }
391
392 public Country getWrappedModel() {
393 return _country;
394 }
395
396 public void resetOriginalValues() {
397 _country.resetOriginalValues();
398 }
399
400 private Country _country;
401 }