001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.model;
016    
017    import java.io.Serializable;
018    
019    import java.util.ArrayList;
020    import java.util.Date;
021    import java.util.List;
022    
023    /**
024     * This class is used by SOAP remote services, specifically {@link com.liferay.portal.service.http.AddressServiceSoap}.
025     *
026     * @author Brian Wing Shun Chan
027     * @see com.liferay.portal.service.http.AddressServiceSoap
028     * @generated
029     */
030    public class AddressSoap implements Serializable {
031            public static AddressSoap toSoapModel(Address model) {
032                    AddressSoap soapModel = new AddressSoap();
033    
034                    soapModel.setUuid(model.getUuid());
035                    soapModel.setAddressId(model.getAddressId());
036                    soapModel.setCompanyId(model.getCompanyId());
037                    soapModel.setUserId(model.getUserId());
038                    soapModel.setUserName(model.getUserName());
039                    soapModel.setCreateDate(model.getCreateDate());
040                    soapModel.setModifiedDate(model.getModifiedDate());
041                    soapModel.setClassNameId(model.getClassNameId());
042                    soapModel.setClassPK(model.getClassPK());
043                    soapModel.setStreet1(model.getStreet1());
044                    soapModel.setStreet2(model.getStreet2());
045                    soapModel.setStreet3(model.getStreet3());
046                    soapModel.setCity(model.getCity());
047                    soapModel.setZip(model.getZip());
048                    soapModel.setRegionId(model.getRegionId());
049                    soapModel.setCountryId(model.getCountryId());
050                    soapModel.setTypeId(model.getTypeId());
051                    soapModel.setMailing(model.getMailing());
052                    soapModel.setPrimary(model.getPrimary());
053    
054                    return soapModel;
055            }
056    
057            public static AddressSoap[] toSoapModels(Address[] models) {
058                    AddressSoap[] soapModels = new AddressSoap[models.length];
059    
060                    for (int i = 0; i < models.length; i++) {
061                            soapModels[i] = toSoapModel(models[i]);
062                    }
063    
064                    return soapModels;
065            }
066    
067            public static AddressSoap[][] toSoapModels(Address[][] models) {
068                    AddressSoap[][] soapModels = null;
069    
070                    if (models.length > 0) {
071                            soapModels = new AddressSoap[models.length][models[0].length];
072                    }
073                    else {
074                            soapModels = new AddressSoap[0][0];
075                    }
076    
077                    for (int i = 0; i < models.length; i++) {
078                            soapModels[i] = toSoapModels(models[i]);
079                    }
080    
081                    return soapModels;
082            }
083    
084            public static AddressSoap[] toSoapModels(List<Address> models) {
085                    List<AddressSoap> soapModels = new ArrayList<AddressSoap>(models.size());
086    
087                    for (Address model : models) {
088                            soapModels.add(toSoapModel(model));
089                    }
090    
091                    return soapModels.toArray(new AddressSoap[soapModels.size()]);
092            }
093    
094            public AddressSoap() {
095            }
096    
097            public long getPrimaryKey() {
098                    return _addressId;
099            }
100    
101            public void setPrimaryKey(long pk) {
102                    setAddressId(pk);
103            }
104    
105            public String getUuid() {
106                    return _uuid;
107            }
108    
109            public void setUuid(String uuid) {
110                    _uuid = uuid;
111            }
112    
113            public long getAddressId() {
114                    return _addressId;
115            }
116    
117            public void setAddressId(long addressId) {
118                    _addressId = addressId;
119            }
120    
121            public long getCompanyId() {
122                    return _companyId;
123            }
124    
125            public void setCompanyId(long companyId) {
126                    _companyId = companyId;
127            }
128    
129            public long getUserId() {
130                    return _userId;
131            }
132    
133            public void setUserId(long userId) {
134                    _userId = userId;
135            }
136    
137            public String getUserName() {
138                    return _userName;
139            }
140    
141            public void setUserName(String userName) {
142                    _userName = userName;
143            }
144    
145            public Date getCreateDate() {
146                    return _createDate;
147            }
148    
149            public void setCreateDate(Date createDate) {
150                    _createDate = createDate;
151            }
152    
153            public Date getModifiedDate() {
154                    return _modifiedDate;
155            }
156    
157            public void setModifiedDate(Date modifiedDate) {
158                    _modifiedDate = modifiedDate;
159            }
160    
161            public long getClassNameId() {
162                    return _classNameId;
163            }
164    
165            public void setClassNameId(long classNameId) {
166                    _classNameId = classNameId;
167            }
168    
169            public long getClassPK() {
170                    return _classPK;
171            }
172    
173            public void setClassPK(long classPK) {
174                    _classPK = classPK;
175            }
176    
177            public String getStreet1() {
178                    return _street1;
179            }
180    
181            public void setStreet1(String street1) {
182                    _street1 = street1;
183            }
184    
185            public String getStreet2() {
186                    return _street2;
187            }
188    
189            public void setStreet2(String street2) {
190                    _street2 = street2;
191            }
192    
193            public String getStreet3() {
194                    return _street3;
195            }
196    
197            public void setStreet3(String street3) {
198                    _street3 = street3;
199            }
200    
201            public String getCity() {
202                    return _city;
203            }
204    
205            public void setCity(String city) {
206                    _city = city;
207            }
208    
209            public String getZip() {
210                    return _zip;
211            }
212    
213            public void setZip(String zip) {
214                    _zip = zip;
215            }
216    
217            public long getRegionId() {
218                    return _regionId;
219            }
220    
221            public void setRegionId(long regionId) {
222                    _regionId = regionId;
223            }
224    
225            public long getCountryId() {
226                    return _countryId;
227            }
228    
229            public void setCountryId(long countryId) {
230                    _countryId = countryId;
231            }
232    
233            public int getTypeId() {
234                    return _typeId;
235            }
236    
237            public void setTypeId(int typeId) {
238                    _typeId = typeId;
239            }
240    
241            public boolean getMailing() {
242                    return _mailing;
243            }
244    
245            public boolean isMailing() {
246                    return _mailing;
247            }
248    
249            public void setMailing(boolean mailing) {
250                    _mailing = mailing;
251            }
252    
253            public boolean getPrimary() {
254                    return _primary;
255            }
256    
257            public boolean isPrimary() {
258                    return _primary;
259            }
260    
261            public void setPrimary(boolean primary) {
262                    _primary = primary;
263            }
264    
265            private String _uuid;
266            private long _addressId;
267            private long _companyId;
268            private long _userId;
269            private String _userName;
270            private Date _createDate;
271            private Date _modifiedDate;
272            private long _classNameId;
273            private long _classPK;
274            private String _street1;
275            private String _street2;
276            private String _street3;
277            private String _city;
278            private String _zip;
279            private long _regionId;
280            private long _countryId;
281            private int _typeId;
282            private boolean _mailing;
283            private boolean _primary;
284    }