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.portal.model;
016    
017    import java.io.Serializable;
018    
019    import java.util.ArrayList;
020    import java.util.List;
021    
022    /**
023     * This class is used by SOAP remote services.
024     *
025     * @author    Brian Wing Shun Chan
026     * @generated
027     */
028    public class ResourceTypePermissionSoap implements Serializable {
029            public static ResourceTypePermissionSoap toSoapModel(
030                    ResourceTypePermission model) {
031                    ResourceTypePermissionSoap soapModel = new ResourceTypePermissionSoap();
032    
033                    soapModel.setResourceTypePermissionId(model.getResourceTypePermissionId());
034                    soapModel.setCompanyId(model.getCompanyId());
035                    soapModel.setGroupId(model.getGroupId());
036                    soapModel.setName(model.getName());
037                    soapModel.setRoleId(model.getRoleId());
038                    soapModel.setActionIds(model.getActionIds());
039    
040                    return soapModel;
041            }
042    
043            public static ResourceTypePermissionSoap[] toSoapModels(
044                    ResourceTypePermission[] models) {
045                    ResourceTypePermissionSoap[] soapModels = new ResourceTypePermissionSoap[models.length];
046    
047                    for (int i = 0; i < models.length; i++) {
048                            soapModels[i] = toSoapModel(models[i]);
049                    }
050    
051                    return soapModels;
052            }
053    
054            public static ResourceTypePermissionSoap[][] toSoapModels(
055                    ResourceTypePermission[][] models) {
056                    ResourceTypePermissionSoap[][] soapModels = null;
057    
058                    if (models.length > 0) {
059                            soapModels = new ResourceTypePermissionSoap[models.length][models[0].length];
060                    }
061                    else {
062                            soapModels = new ResourceTypePermissionSoap[0][0];
063                    }
064    
065                    for (int i = 0; i < models.length; i++) {
066                            soapModels[i] = toSoapModels(models[i]);
067                    }
068    
069                    return soapModels;
070            }
071    
072            public static ResourceTypePermissionSoap[] toSoapModels(
073                    List<ResourceTypePermission> models) {
074                    List<ResourceTypePermissionSoap> soapModels = new ArrayList<ResourceTypePermissionSoap>(models.size());
075    
076                    for (ResourceTypePermission model : models) {
077                            soapModels.add(toSoapModel(model));
078                    }
079    
080                    return soapModels.toArray(new ResourceTypePermissionSoap[soapModels.size()]);
081            }
082    
083            public ResourceTypePermissionSoap() {
084            }
085    
086            public long getPrimaryKey() {
087                    return _resourceTypePermissionId;
088            }
089    
090            public void setPrimaryKey(long pk) {
091                    setResourceTypePermissionId(pk);
092            }
093    
094            public long getResourceTypePermissionId() {
095                    return _resourceTypePermissionId;
096            }
097    
098            public void setResourceTypePermissionId(long resourceTypePermissionId) {
099                    _resourceTypePermissionId = resourceTypePermissionId;
100            }
101    
102            public long getCompanyId() {
103                    return _companyId;
104            }
105    
106            public void setCompanyId(long companyId) {
107                    _companyId = companyId;
108            }
109    
110            public long getGroupId() {
111                    return _groupId;
112            }
113    
114            public void setGroupId(long groupId) {
115                    _groupId = groupId;
116            }
117    
118            public String getName() {
119                    return _name;
120            }
121    
122            public void setName(String name) {
123                    _name = name;
124            }
125    
126            public long getRoleId() {
127                    return _roleId;
128            }
129    
130            public void setRoleId(long roleId) {
131                    _roleId = roleId;
132            }
133    
134            public long getActionIds() {
135                    return _actionIds;
136            }
137    
138            public void setActionIds(long actionIds) {
139                    _actionIds = actionIds;
140            }
141    
142            private long _resourceTypePermissionId;
143            private long _companyId;
144            private long _groupId;
145            private String _name;
146            private long _roleId;
147            private long _actionIds;
148    }