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.softwarecatalog.model;
16  
17  import java.io.Serializable;
18  
19  import java.util.ArrayList;
20  import java.util.List;
21  
22  /**
23   * <a href="SCLicenseSoap.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.softwarecatalog.service.http.SCLicenseServiceSoap}.
33   * </p>
34   *
35   * @author    Brian Wing Shun Chan
36   * @see       com.liferay.portlet.softwarecatalog.service.http.SCLicenseServiceSoap
37   * @generated
38   */
39  public class SCLicenseSoap implements Serializable {
40      public static SCLicenseSoap toSoapModel(SCLicense model) {
41          SCLicenseSoap soapModel = new SCLicenseSoap();
42  
43          soapModel.setLicenseId(model.getLicenseId());
44          soapModel.setName(model.getName());
45          soapModel.setUrl(model.getUrl());
46          soapModel.setOpenSource(model.getOpenSource());
47          soapModel.setActive(model.getActive());
48          soapModel.setRecommended(model.getRecommended());
49  
50          return soapModel;
51      }
52  
53      public static SCLicenseSoap[] toSoapModels(SCLicense[] models) {
54          SCLicenseSoap[] soapModels = new SCLicenseSoap[models.length];
55  
56          for (int i = 0; i < models.length; i++) {
57              soapModels[i] = toSoapModel(models[i]);
58          }
59  
60          return soapModels;
61      }
62  
63      public static SCLicenseSoap[][] toSoapModels(SCLicense[][] models) {
64          SCLicenseSoap[][] soapModels = null;
65  
66          if (models.length > 0) {
67              soapModels = new SCLicenseSoap[models.length][models[0].length];
68          }
69          else {
70              soapModels = new SCLicenseSoap[0][0];
71          }
72  
73          for (int i = 0; i < models.length; i++) {
74              soapModels[i] = toSoapModels(models[i]);
75          }
76  
77          return soapModels;
78      }
79  
80      public static SCLicenseSoap[] toSoapModels(List<SCLicense> models) {
81          List<SCLicenseSoap> soapModels = new ArrayList<SCLicenseSoap>(models.size());
82  
83          for (SCLicense model : models) {
84              soapModels.add(toSoapModel(model));
85          }
86  
87          return soapModels.toArray(new SCLicenseSoap[soapModels.size()]);
88      }
89  
90      public SCLicenseSoap() {
91      }
92  
93      public long getPrimaryKey() {
94          return _licenseId;
95      }
96  
97      public void setPrimaryKey(long pk) {
98          setLicenseId(pk);
99      }
100 
101     public long getLicenseId() {
102         return _licenseId;
103     }
104 
105     public void setLicenseId(long licenseId) {
106         _licenseId = licenseId;
107     }
108 
109     public String getName() {
110         return _name;
111     }
112 
113     public void setName(String name) {
114         _name = name;
115     }
116 
117     public String getUrl() {
118         return _url;
119     }
120 
121     public void setUrl(String url) {
122         _url = url;
123     }
124 
125     public boolean getOpenSource() {
126         return _openSource;
127     }
128 
129     public boolean isOpenSource() {
130         return _openSource;
131     }
132 
133     public void setOpenSource(boolean openSource) {
134         _openSource = openSource;
135     }
136 
137     public boolean getActive() {
138         return _active;
139     }
140 
141     public boolean isActive() {
142         return _active;
143     }
144 
145     public void setActive(boolean active) {
146         _active = active;
147     }
148 
149     public boolean getRecommended() {
150         return _recommended;
151     }
152 
153     public boolean isRecommended() {
154         return _recommended;
155     }
156 
157     public void setRecommended(boolean recommended) {
158         _recommended = recommended;
159     }
160 
161     private long _licenseId;
162     private String _name;
163     private String _url;
164     private boolean _openSource;
165     private boolean _active;
166     private boolean _recommended;
167 }