1   /**
2    * Copyright (c) 2000-2010 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   *
12   *
13   */
14  
15  package com.liferay.portal.model;
16  
17  import java.io.Serializable;
18  
19  import java.util.ArrayList;
20  import java.util.List;
21  
22  /**
23   * <a href="UserGroupSoap.java.html"><b><i>View Source</i></b></a>
24   *
25   * <p>
26   * ServiceBuilder generated this class. Modifications in this class will be
27   * overwritten the next time is generated.
28   * </p>
29   *
30   * <p>
31   * This class is used by
32   * {@link com.liferay.portal.service.http.UserGroupServiceSoap}.
33   * </p>
34   *
35   * @author    Brian Wing Shun Chan
36   * @see       com.liferay.portal.service.http.UserGroupServiceSoap
37   * @generated
38   */
39  public class UserGroupSoap implements Serializable {
40      public static UserGroupSoap toSoapModel(UserGroup model) {
41          UserGroupSoap soapModel = new UserGroupSoap();
42  
43          soapModel.setUserGroupId(model.getUserGroupId());
44          soapModel.setCompanyId(model.getCompanyId());
45          soapModel.setParentUserGroupId(model.getParentUserGroupId());
46          soapModel.setName(model.getName());
47          soapModel.setDescription(model.getDescription());
48  
49          return soapModel;
50      }
51  
52      public static UserGroupSoap[] toSoapModels(UserGroup[] models) {
53          UserGroupSoap[] soapModels = new UserGroupSoap[models.length];
54  
55          for (int i = 0; i < models.length; i++) {
56              soapModels[i] = toSoapModel(models[i]);
57          }
58  
59          return soapModels;
60      }
61  
62      public static UserGroupSoap[][] toSoapModels(UserGroup[][] models) {
63          UserGroupSoap[][] soapModels = null;
64  
65          if (models.length > 0) {
66              soapModels = new UserGroupSoap[models.length][models[0].length];
67          }
68          else {
69              soapModels = new UserGroupSoap[0][0];
70          }
71  
72          for (int i = 0; i < models.length; i++) {
73              soapModels[i] = toSoapModels(models[i]);
74          }
75  
76          return soapModels;
77      }
78  
79      public static UserGroupSoap[] toSoapModels(List<UserGroup> models) {
80          List<UserGroupSoap> soapModels = new ArrayList<UserGroupSoap>(models.size());
81  
82          for (UserGroup model : models) {
83              soapModels.add(toSoapModel(model));
84          }
85  
86          return soapModels.toArray(new UserGroupSoap[soapModels.size()]);
87      }
88  
89      public UserGroupSoap() {
90      }
91  
92      public long getPrimaryKey() {
93          return _userGroupId;
94      }
95  
96      public void setPrimaryKey(long pk) {
97          setUserGroupId(pk);
98      }
99  
100     public long getUserGroupId() {
101         return _userGroupId;
102     }
103 
104     public void setUserGroupId(long userGroupId) {
105         _userGroupId = userGroupId;
106     }
107 
108     public long getCompanyId() {
109         return _companyId;
110     }
111 
112     public void setCompanyId(long companyId) {
113         _companyId = companyId;
114     }
115 
116     public long getParentUserGroupId() {
117         return _parentUserGroupId;
118     }
119 
120     public void setParentUserGroupId(long parentUserGroupId) {
121         _parentUserGroupId = parentUserGroupId;
122     }
123 
124     public String getName() {
125         return _name;
126     }
127 
128     public void setName(String name) {
129         _name = name;
130     }
131 
132     public String getDescription() {
133         return _description;
134     }
135 
136     public void setDescription(String description) {
137         _description = description;
138     }
139 
140     private long _userGroupId;
141     private long _companyId;
142     private long _parentUserGroupId;
143     private String _name;
144     private String _description;
145 }