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.portlet.announcements.model;
21  
22  import java.io.Serializable;
23  
24  import java.util.ArrayList;
25  import java.util.List;
26  
27  /**
28   * <a href="AnnouncementsDeliverySoap.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.portlet.announcements.service.http.AnnouncementsDeliveryServiceSoap</code>.
38   * </p>
39   *
40   * @author Brian Wing Shun Chan
41   *
42   * @see com.liferay.portlet.announcements.service.http.AnnouncementsDeliveryServiceSoap
43   *
44   */
45  public class AnnouncementsDeliverySoap implements Serializable {
46      public static AnnouncementsDeliverySoap toSoapModel(
47          AnnouncementsDelivery model) {
48          AnnouncementsDeliverySoap soapModel = new AnnouncementsDeliverySoap();
49  
50          soapModel.setDeliveryId(model.getDeliveryId());
51          soapModel.setCompanyId(model.getCompanyId());
52          soapModel.setUserId(model.getUserId());
53          soapModel.setType(model.getType());
54          soapModel.setEmail(model.getEmail());
55          soapModel.setSms(model.getSms());
56          soapModel.setWebsite(model.getWebsite());
57  
58          return soapModel;
59      }
60  
61      public static AnnouncementsDeliverySoap[] toSoapModels(
62          List<AnnouncementsDelivery> models) {
63          List<AnnouncementsDeliverySoap> soapModels = new ArrayList<AnnouncementsDeliverySoap>(models.size());
64  
65          for (AnnouncementsDelivery model : models) {
66              soapModels.add(toSoapModel(model));
67          }
68  
69          return soapModels.toArray(new AnnouncementsDeliverySoap[soapModels.size()]);
70      }
71  
72      public AnnouncementsDeliverySoap() {
73      }
74  
75      public long getPrimaryKey() {
76          return _deliveryId;
77      }
78  
79      public void setPrimaryKey(long pk) {
80          setDeliveryId(pk);
81      }
82  
83      public long getDeliveryId() {
84          return _deliveryId;
85      }
86  
87      public void setDeliveryId(long deliveryId) {
88          _deliveryId = deliveryId;
89      }
90  
91      public long getCompanyId() {
92          return _companyId;
93      }
94  
95      public void setCompanyId(long companyId) {
96          _companyId = companyId;
97      }
98  
99      public long getUserId() {
100         return _userId;
101     }
102 
103     public void setUserId(long userId) {
104         _userId = userId;
105     }
106 
107     public String getType() {
108         return _type;
109     }
110 
111     public void setType(String type) {
112         _type = type;
113     }
114 
115     public boolean getEmail() {
116         return _email;
117     }
118 
119     public boolean isEmail() {
120         return _email;
121     }
122 
123     public void setEmail(boolean email) {
124         _email = email;
125     }
126 
127     public boolean getSms() {
128         return _sms;
129     }
130 
131     public boolean isSms() {
132         return _sms;
133     }
134 
135     public void setSms(boolean sms) {
136         _sms = sms;
137     }
138 
139     public boolean getWebsite() {
140         return _website;
141     }
142 
143     public boolean isWebsite() {
144         return _website;
145     }
146 
147     public void setWebsite(boolean website) {
148         _website = website;
149     }
150 
151     private long _deliveryId;
152     private long _companyId;
153     private long _userId;
154     private String _type;
155     private boolean _email;
156     private boolean _sms;
157     private boolean _website;
158 }