1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
17   * SOFTWARE.
18   */
19  
20  package com.liferay.portal.model;
21  
22  import java.io.Serializable;
23  
24  import java.util.ArrayList;
25  import java.util.List;
26  
27  /**
28   * <a href="GroupSoap.java.html"><b><i>View Source</i></b></a>
29   *
30   * <p>
31   * ServiceBuilder generated this class. Modifications in this class will be
32   * overwritten the next time is generated.
33   * </p>
34   *
35   * <p>
36   * This class is used by
37   * <code>com.liferay.portal.service.http.GroupServiceSoap</code>.
38   * </p>
39   *
40   * @author Brian Wing Shun Chan
41   *
42   * @see com.liferay.portal.service.http.GroupServiceSoap
43   *
44   */
45  public class GroupSoap implements Serializable {
46      public static GroupSoap toSoapModel(Group model) {
47          GroupSoap soapModel = new GroupSoap();
48  
49          soapModel.setGroupId(model.getGroupId());
50          soapModel.setCompanyId(model.getCompanyId());
51          soapModel.setCreatorUserId(model.getCreatorUserId());
52          soapModel.setClassNameId(model.getClassNameId());
53          soapModel.setClassPK(model.getClassPK());
54          soapModel.setParentGroupId(model.getParentGroupId());
55          soapModel.setLiveGroupId(model.getLiveGroupId());
56          soapModel.setName(model.getName());
57          soapModel.setDescription(model.getDescription());
58          soapModel.setType(model.getType());
59          soapModel.setTypeSettings(model.getTypeSettings());
60          soapModel.setFriendlyURL(model.getFriendlyURL());
61          soapModel.setActive(model.getActive());
62  
63          return soapModel;
64      }
65  
66      public static GroupSoap[] toSoapModels(Group[] models) {
67          GroupSoap[] soapModels = new GroupSoap[models.length];
68  
69          for (int i = 0; i < models.length; i++) {
70              soapModels[i] = toSoapModel(models[i]);
71          }
72  
73          return soapModels;
74      }
75  
76      public static GroupSoap[][] toSoapModels(Group[][] models) {
77          GroupSoap[][] soapModels = null;
78  
79          if (models.length > 0) {
80              soapModels = new GroupSoap[models.length][models[0].length];
81          }
82          else {
83              soapModels = new GroupSoap[0][0];
84          }
85  
86          for (int i = 0; i < models.length; i++) {
87              soapModels[i] = toSoapModels(models[i]);
88          }
89  
90          return soapModels;
91      }
92  
93      public static GroupSoap[] toSoapModels(List<Group> models) {
94          List<GroupSoap> soapModels = new ArrayList<GroupSoap>(models.size());
95  
96          for (Group model : models) {
97              soapModels.add(toSoapModel(model));
98          }
99  
100         return soapModels.toArray(new GroupSoap[soapModels.size()]);
101     }
102 
103     public GroupSoap() {
104     }
105 
106     public long getPrimaryKey() {
107         return _groupId;
108     }
109 
110     public void setPrimaryKey(long pk) {
111         setGroupId(pk);
112     }
113 
114     public long getGroupId() {
115         return _groupId;
116     }
117 
118     public void setGroupId(long groupId) {
119         _groupId = groupId;
120     }
121 
122     public long getCompanyId() {
123         return _companyId;
124     }
125 
126     public void setCompanyId(long companyId) {
127         _companyId = companyId;
128     }
129 
130     public long getCreatorUserId() {
131         return _creatorUserId;
132     }
133 
134     public void setCreatorUserId(long creatorUserId) {
135         _creatorUserId = creatorUserId;
136     }
137 
138     public long getClassNameId() {
139         return _classNameId;
140     }
141 
142     public void setClassNameId(long classNameId) {
143         _classNameId = classNameId;
144     }
145 
146     public long getClassPK() {
147         return _classPK;
148     }
149 
150     public void setClassPK(long classPK) {
151         _classPK = classPK;
152     }
153 
154     public long getParentGroupId() {
155         return _parentGroupId;
156     }
157 
158     public void setParentGroupId(long parentGroupId) {
159         _parentGroupId = parentGroupId;
160     }
161 
162     public long getLiveGroupId() {
163         return _liveGroupId;
164     }
165 
166     public void setLiveGroupId(long liveGroupId) {
167         _liveGroupId = liveGroupId;
168     }
169 
170     public String getName() {
171         return _name;
172     }
173 
174     public void setName(String name) {
175         _name = name;
176     }
177 
178     public String getDescription() {
179         return _description;
180     }
181 
182     public void setDescription(String description) {
183         _description = description;
184     }
185 
186     public int getType() {
187         return _type;
188     }
189 
190     public void setType(int type) {
191         _type = type;
192     }
193 
194     public String getTypeSettings() {
195         return _typeSettings;
196     }
197 
198     public void setTypeSettings(String typeSettings) {
199         _typeSettings = typeSettings;
200     }
201 
202     public String getFriendlyURL() {
203         return _friendlyURL;
204     }
205 
206     public void setFriendlyURL(String friendlyURL) {
207         _friendlyURL = friendlyURL;
208     }
209 
210     public boolean getActive() {
211         return _active;
212     }
213 
214     public boolean isActive() {
215         return _active;
216     }
217 
218     public void setActive(boolean active) {
219         _active = active;
220     }
221 
222     private long _groupId;
223     private long _companyId;
224     private long _creatorUserId;
225     private long _classNameId;
226     private long _classPK;
227     private long _parentGroupId;
228     private long _liveGroupId;
229     private String _name;
230     private String _description;
231     private int _type;
232     private String _typeSettings;
233     private String _friendlyURL;
234     private boolean _active;
235 }