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.portlet.expando.model;
16  
17  import java.io.Serializable;
18  
19  import java.util.ArrayList;
20  import java.util.List;
21  
22  /**
23   * <a href="ExpandoTableSoap.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.portlet.expando.service.http.ExpandoTableServiceSoap}.
33   * </p>
34   *
35   * @author    Brian Wing Shun Chan
36   * @see       com.liferay.portlet.expando.service.http.ExpandoTableServiceSoap
37   * @generated
38   */
39  public class ExpandoTableSoap implements Serializable {
40      public static ExpandoTableSoap toSoapModel(ExpandoTable model) {
41          ExpandoTableSoap soapModel = new ExpandoTableSoap();
42  
43          soapModel.setTableId(model.getTableId());
44          soapModel.setClassNameId(model.getClassNameId());
45          soapModel.setName(model.getName());
46  
47          return soapModel;
48      }
49  
50      public static ExpandoTableSoap[] toSoapModels(ExpandoTable[] models) {
51          ExpandoTableSoap[] soapModels = new ExpandoTableSoap[models.length];
52  
53          for (int i = 0; i < models.length; i++) {
54              soapModels[i] = toSoapModel(models[i]);
55          }
56  
57          return soapModels;
58      }
59  
60      public static ExpandoTableSoap[][] toSoapModels(ExpandoTable[][] models) {
61          ExpandoTableSoap[][] soapModels = null;
62  
63          if (models.length > 0) {
64              soapModels = new ExpandoTableSoap[models.length][models[0].length];
65          }
66          else {
67              soapModels = new ExpandoTableSoap[0][0];
68          }
69  
70          for (int i = 0; i < models.length; i++) {
71              soapModels[i] = toSoapModels(models[i]);
72          }
73  
74          return soapModels;
75      }
76  
77      public static ExpandoTableSoap[] toSoapModels(List<ExpandoTable> models) {
78          List<ExpandoTableSoap> soapModels = new ArrayList<ExpandoTableSoap>(models.size());
79  
80          for (ExpandoTable model : models) {
81              soapModels.add(toSoapModel(model));
82          }
83  
84          return soapModels.toArray(new ExpandoTableSoap[soapModels.size()]);
85      }
86  
87      public ExpandoTableSoap() {
88      }
89  
90      public long getPrimaryKey() {
91          return _tableId;
92      }
93  
94      public void setPrimaryKey(long pk) {
95          setTableId(pk);
96      }
97  
98      public long getTableId() {
99          return _tableId;
100     }
101 
102     public void setTableId(long tableId) {
103         _tableId = tableId;
104     }
105 
106     public long getClassNameId() {
107         return _classNameId;
108     }
109 
110     public void setClassNameId(long classNameId) {
111         _classNameId = classNameId;
112     }
113 
114     public String getName() {
115         return _name;
116     }
117 
118     public void setName(String name) {
119         _name = name;
120     }
121 
122     private long _tableId;
123     private long _classNameId;
124     private String _name;
125 }