001    /**
002     * Copyright (c) 2000-2010 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.portal.model;
016    
017    import java.io.Serializable;
018    
019    import java.util.ArrayList;
020    import java.util.List;
021    
022    /**
023     * <p>
024     * This class is used by
025     * {@link com.liferay.portal.service.http.LayoutPrototypeServiceSoap}.
026     * </p>
027     *
028     * @author    Brian Wing Shun Chan
029     * @see       com.liferay.portal.service.http.LayoutPrototypeServiceSoap
030     * @generated
031     */
032    public class LayoutPrototypeSoap implements Serializable {
033            public static LayoutPrototypeSoap toSoapModel(LayoutPrototype model) {
034                    LayoutPrototypeSoap soapModel = new LayoutPrototypeSoap();
035    
036                    soapModel.setLayoutPrototypeId(model.getLayoutPrototypeId());
037                    soapModel.setCompanyId(model.getCompanyId());
038                    soapModel.setName(model.getName());
039                    soapModel.setDescription(model.getDescription());
040                    soapModel.setSettings(model.getSettings());
041                    soapModel.setActive(model.getActive());
042    
043                    return soapModel;
044            }
045    
046            public static LayoutPrototypeSoap[] toSoapModels(LayoutPrototype[] models) {
047                    LayoutPrototypeSoap[] soapModels = new LayoutPrototypeSoap[models.length];
048    
049                    for (int i = 0; i < models.length; i++) {
050                            soapModels[i] = toSoapModel(models[i]);
051                    }
052    
053                    return soapModels;
054            }
055    
056            public static LayoutPrototypeSoap[][] toSoapModels(
057                    LayoutPrototype[][] models) {
058                    LayoutPrototypeSoap[][] soapModels = null;
059    
060                    if (models.length > 0) {
061                            soapModels = new LayoutPrototypeSoap[models.length][models[0].length];
062                    }
063                    else {
064                            soapModels = new LayoutPrototypeSoap[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 LayoutPrototypeSoap[] toSoapModels(
075                    List<LayoutPrototype> models) {
076                    List<LayoutPrototypeSoap> soapModels = new ArrayList<LayoutPrototypeSoap>(models.size());
077    
078                    for (LayoutPrototype model : models) {
079                            soapModels.add(toSoapModel(model));
080                    }
081    
082                    return soapModels.toArray(new LayoutPrototypeSoap[soapModels.size()]);
083            }
084    
085            public LayoutPrototypeSoap() {
086            }
087    
088            public long getPrimaryKey() {
089                    return _layoutPrototypeId;
090            }
091    
092            public void setPrimaryKey(long pk) {
093                    setLayoutPrototypeId(pk);
094            }
095    
096            public long getLayoutPrototypeId() {
097                    return _layoutPrototypeId;
098            }
099    
100            public void setLayoutPrototypeId(long layoutPrototypeId) {
101                    _layoutPrototypeId = layoutPrototypeId;
102            }
103    
104            public long getCompanyId() {
105                    return _companyId;
106            }
107    
108            public void setCompanyId(long companyId) {
109                    _companyId = companyId;
110            }
111    
112            public String getName() {
113                    return _name;
114            }
115    
116            public void setName(String name) {
117                    _name = name;
118            }
119    
120            public String getDescription() {
121                    return _description;
122            }
123    
124            public void setDescription(String description) {
125                    _description = description;
126            }
127    
128            public String getSettings() {
129                    return _settings;
130            }
131    
132            public void setSettings(String settings) {
133                    _settings = settings;
134            }
135    
136            public boolean getActive() {
137                    return _active;
138            }
139    
140            public boolean isActive() {
141                    return _active;
142            }
143    
144            public void setActive(boolean active) {
145                    _active = active;
146            }
147    
148            private long _layoutPrototypeId;
149            private long _companyId;
150            private String _name;
151            private String _description;
152            private String _settings;
153            private boolean _active;
154    }