| ImageSoap.java |
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.Date;
26 import java.util.List;
27
28 /**
29 * <a href="ImageSoap.java.html"><b><i>View Source</i></b></a>
30 *
31 * <p>
32 * ServiceBuilder generated this class. Modifications in this class will be
33 * overwritten the next time is generated.
34 * </p>
35 *
36 * <p>
37 * This class is used by
38 * <code>com.liferay.portal.service.http.ImageServiceSoap</code>.
39 * </p>
40 *
41 * @author Brian Wing Shun Chan
42 *
43 * @see com.liferay.portal.service.http.ImageServiceSoap
44 *
45 */
46 public class ImageSoap implements Serializable {
47 public static ImageSoap toSoapModel(Image model) {
48 ImageSoap soapModel = new ImageSoap();
49
50 soapModel.setImageId(model.getImageId());
51 soapModel.setModifiedDate(model.getModifiedDate());
52 soapModel.setText(model.getText());
53 soapModel.setType(model.getType());
54 soapModel.setHeight(model.getHeight());
55 soapModel.setWidth(model.getWidth());
56 soapModel.setSize(model.getSize());
57
58 return soapModel;
59 }
60
61 public static ImageSoap[] toSoapModels(List<Image> models) {
62 List<ImageSoap> soapModels = new ArrayList<ImageSoap>(models.size());
63
64 for (Image model : models) {
65 soapModels.add(toSoapModel(model));
66 }
67
68 return soapModels.toArray(new ImageSoap[soapModels.size()]);
69 }
70
71 public ImageSoap() {
72 }
73
74 public long getPrimaryKey() {
75 return _imageId;
76 }
77
78 public void setPrimaryKey(long pk) {
79 setImageId(pk);
80 }
81
82 public long getImageId() {
83 return _imageId;
84 }
85
86 public void setImageId(long imageId) {
87 _imageId = imageId;
88 }
89
90 public Date getModifiedDate() {
91 return _modifiedDate;
92 }
93
94 public void setModifiedDate(Date modifiedDate) {
95 _modifiedDate = modifiedDate;
96 }
97
98 public String getText() {
99 return _text;
100 }
101
102 public void setText(String text) {
103 _text = text;
104 }
105
106 public String getType() {
107 return _type;
108 }
109
110 public void setType(String type) {
111 _type = type;
112 }
113
114 public int getHeight() {
115 return _height;
116 }
117
118 public void setHeight(int height) {
119 _height = height;
120 }
121
122 public int getWidth() {
123 return _width;
124 }
125
126 public void setWidth(int width) {
127 _width = width;
128 }
129
130 public int getSize() {
131 return _size;
132 }
133
134 public void setSize(int size) {
135 _size = size;
136 }
137
138 private long _imageId;
139 private Date _modifiedDate;
140 private String _text;
141 private String _type;
142 private int _height;
143 private int _width;
144 private int _size;
145 }