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.RoleServiceSoap}.
025     *
026     * @author Brian Wing Shun Chan
027     * @see com.liferay.portal.service.http.RoleServiceSoap
028     * @generated
029     */
030    public class RoleSoap implements Serializable {
031            public static RoleSoap toSoapModel(Role model) {
032                    RoleSoap soapModel = new RoleSoap();
033    
034                    soapModel.setUuid(model.getUuid());
035                    soapModel.setRoleId(model.getRoleId());
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.setName(model.getName());
044                    soapModel.setTitle(model.getTitle());
045                    soapModel.setDescription(model.getDescription());
046                    soapModel.setType(model.getType());
047                    soapModel.setSubtype(model.getSubtype());
048    
049                    return soapModel;
050            }
051    
052            public static RoleSoap[] toSoapModels(Role[] models) {
053                    RoleSoap[] soapModels = new RoleSoap[models.length];
054    
055                    for (int i = 0; i < models.length; i++) {
056                            soapModels[i] = toSoapModel(models[i]);
057                    }
058    
059                    return soapModels;
060            }
061    
062            public static RoleSoap[][] toSoapModels(Role[][] models) {
063                    RoleSoap[][] soapModels = null;
064    
065                    if (models.length > 0) {
066                            soapModels = new RoleSoap[models.length][models[0].length];
067                    }
068                    else {
069                            soapModels = new RoleSoap[0][0];
070                    }
071    
072                    for (int i = 0; i < models.length; i++) {
073                            soapModels[i] = toSoapModels(models[i]);
074                    }
075    
076                    return soapModels;
077            }
078    
079            public static RoleSoap[] toSoapModels(List<Role> models) {
080                    List<RoleSoap> soapModels = new ArrayList<RoleSoap>(models.size());
081    
082                    for (Role model : models) {
083                            soapModels.add(toSoapModel(model));
084                    }
085    
086                    return soapModels.toArray(new RoleSoap[soapModels.size()]);
087            }
088    
089            public RoleSoap() {
090            }
091    
092            public long getPrimaryKey() {
093                    return _roleId;
094            }
095    
096            public void setPrimaryKey(long pk) {
097                    setRoleId(pk);
098            }
099    
100            public String getUuid() {
101                    return _uuid;
102            }
103    
104            public void setUuid(String uuid) {
105                    _uuid = uuid;
106            }
107    
108            public long getRoleId() {
109                    return _roleId;
110            }
111    
112            public void setRoleId(long roleId) {
113                    _roleId = roleId;
114            }
115    
116            public long getCompanyId() {
117                    return _companyId;
118            }
119    
120            public void setCompanyId(long companyId) {
121                    _companyId = companyId;
122            }
123    
124            public long getUserId() {
125                    return _userId;
126            }
127    
128            public void setUserId(long userId) {
129                    _userId = userId;
130            }
131    
132            public String getUserName() {
133                    return _userName;
134            }
135    
136            public void setUserName(String userName) {
137                    _userName = userName;
138            }
139    
140            public Date getCreateDate() {
141                    return _createDate;
142            }
143    
144            public void setCreateDate(Date createDate) {
145                    _createDate = createDate;
146            }
147    
148            public Date getModifiedDate() {
149                    return _modifiedDate;
150            }
151    
152            public void setModifiedDate(Date modifiedDate) {
153                    _modifiedDate = modifiedDate;
154            }
155    
156            public long getClassNameId() {
157                    return _classNameId;
158            }
159    
160            public void setClassNameId(long classNameId) {
161                    _classNameId = classNameId;
162            }
163    
164            public long getClassPK() {
165                    return _classPK;
166            }
167    
168            public void setClassPK(long classPK) {
169                    _classPK = classPK;
170            }
171    
172            public String getName() {
173                    return _name;
174            }
175    
176            public void setName(String name) {
177                    _name = name;
178            }
179    
180            public String getTitle() {
181                    return _title;
182            }
183    
184            public void setTitle(String title) {
185                    _title = title;
186            }
187    
188            public String getDescription() {
189                    return _description;
190            }
191    
192            public void setDescription(String description) {
193                    _description = description;
194            }
195    
196            public int getType() {
197                    return _type;
198            }
199    
200            public void setType(int type) {
201                    _type = type;
202            }
203    
204            public String getSubtype() {
205                    return _subtype;
206            }
207    
208            public void setSubtype(String subtype) {
209                    _subtype = subtype;
210            }
211    
212            private String _uuid;
213            private long _roleId;
214            private long _companyId;
215            private long _userId;
216            private String _userName;
217            private Date _createDate;
218            private Date _modifiedDate;
219            private long _classNameId;
220            private long _classPK;
221            private String _name;
222            private String _title;
223            private String _description;
224            private int _type;
225            private String _subtype;
226    }