001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.ratings.model;
016    
017    import java.io.Serializable;
018    
019    import java.util.ArrayList;
020    import java.util.Date;
021    import java.util.List;
022    
023    /**
024     * This class is used by SOAP remote services, specifically {@link com.liferay.portlet.ratings.service.http.RatingsEntryServiceSoap}.
025     *
026     * @author    Brian Wing Shun Chan
027     * @see       com.liferay.portlet.ratings.service.http.RatingsEntryServiceSoap
028     * @generated
029     */
030    public class RatingsEntrySoap implements Serializable {
031            public static RatingsEntrySoap toSoapModel(RatingsEntry model) {
032                    RatingsEntrySoap soapModel = new RatingsEntrySoap();
033    
034                    soapModel.setEntryId(model.getEntryId());
035                    soapModel.setCompanyId(model.getCompanyId());
036                    soapModel.setUserId(model.getUserId());
037                    soapModel.setUserName(model.getUserName());
038                    soapModel.setCreateDate(model.getCreateDate());
039                    soapModel.setModifiedDate(model.getModifiedDate());
040                    soapModel.setClassNameId(model.getClassNameId());
041                    soapModel.setClassPK(model.getClassPK());
042                    soapModel.setScore(model.getScore());
043    
044                    return soapModel;
045            }
046    
047            public static RatingsEntrySoap[] toSoapModels(RatingsEntry[] models) {
048                    RatingsEntrySoap[] soapModels = new RatingsEntrySoap[models.length];
049    
050                    for (int i = 0; i < models.length; i++) {
051                            soapModels[i] = toSoapModel(models[i]);
052                    }
053    
054                    return soapModels;
055            }
056    
057            public static RatingsEntrySoap[][] toSoapModels(RatingsEntry[][] models) {
058                    RatingsEntrySoap[][] soapModels = null;
059    
060                    if (models.length > 0) {
061                            soapModels = new RatingsEntrySoap[models.length][models[0].length];
062                    }
063                    else {
064                            soapModels = new RatingsEntrySoap[0][0];
065                    }
066    
067                    for (int i = 0; i < models.length; i++) {
068                            soapModels[i] = toSoapModels(models[i]);
069                    }
070    
071                    return soapModels;
072            }
073    
074            public static RatingsEntrySoap[] toSoapModels(List<RatingsEntry> models) {
075                    List<RatingsEntrySoap> soapModels = new ArrayList<RatingsEntrySoap>(models.size());
076    
077                    for (RatingsEntry model : models) {
078                            soapModels.add(toSoapModel(model));
079                    }
080    
081                    return soapModels.toArray(new RatingsEntrySoap[soapModels.size()]);
082            }
083    
084            public RatingsEntrySoap() {
085            }
086    
087            public long getPrimaryKey() {
088                    return _entryId;
089            }
090    
091            public void setPrimaryKey(long pk) {
092                    setEntryId(pk);
093            }
094    
095            public long getEntryId() {
096                    return _entryId;
097            }
098    
099            public void setEntryId(long entryId) {
100                    _entryId = entryId;
101            }
102    
103            public long getCompanyId() {
104                    return _companyId;
105            }
106    
107            public void setCompanyId(long companyId) {
108                    _companyId = companyId;
109            }
110    
111            public long getUserId() {
112                    return _userId;
113            }
114    
115            public void setUserId(long userId) {
116                    _userId = userId;
117            }
118    
119            public String getUserName() {
120                    return _userName;
121            }
122    
123            public void setUserName(String userName) {
124                    _userName = userName;
125            }
126    
127            public Date getCreateDate() {
128                    return _createDate;
129            }
130    
131            public void setCreateDate(Date createDate) {
132                    _createDate = createDate;
133            }
134    
135            public Date getModifiedDate() {
136                    return _modifiedDate;
137            }
138    
139            public void setModifiedDate(Date modifiedDate) {
140                    _modifiedDate = modifiedDate;
141            }
142    
143            public long getClassNameId() {
144                    return _classNameId;
145            }
146    
147            public void setClassNameId(long classNameId) {
148                    _classNameId = classNameId;
149            }
150    
151            public long getClassPK() {
152                    return _classPK;
153            }
154    
155            public void setClassPK(long classPK) {
156                    _classPK = classPK;
157            }
158    
159            public double getScore() {
160                    return _score;
161            }
162    
163            public void setScore(double score) {
164                    _score = score;
165            }
166    
167            private long _entryId;
168            private long _companyId;
169            private long _userId;
170            private String _userName;
171            private Date _createDate;
172            private Date _modifiedDate;
173            private long _classNameId;
174            private long _classPK;
175            private double _score;
176    }