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 aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.bean.AutoEscape; 020 import com.liferay.portal.service.ServiceContext; 021 022 import com.liferay.portlet.expando.model.ExpandoBridge; 023 024 import java.io.Serializable; 025 026 /** 027 * The base model interface for the Portlet service. Represents a row in the "Portlet" database table, with each column mapped to a property of this class. 028 * 029 * <p> 030 * This interface and its corresponding implementation {@link com.liferay.portal.model.impl.PortletModelImpl} exist only as a container for the default property accessors generated by ServiceBuilder. Helper methods and all application logic should be put in {@link com.liferay.portal.model.impl.PortletImpl}. 031 * </p> 032 * 033 * @author Brian Wing Shun Chan 034 * @see Portlet 035 * @see com.liferay.portal.model.impl.PortletImpl 036 * @see com.liferay.portal.model.impl.PortletModelImpl 037 * @generated 038 */ 039 @ProviderType 040 public interface PortletModel extends BaseModel<Portlet> { 041 /* 042 * NOTE FOR DEVELOPERS: 043 * 044 * Never modify or reference this interface directly. All methods that expect a portlet model instance should use the {@link Portlet} interface instead. 045 */ 046 047 /** 048 * Returns the primary key of this portlet. 049 * 050 * @return the primary key of this portlet 051 */ 052 public long getPrimaryKey(); 053 054 /** 055 * Sets the primary key of this portlet. 056 * 057 * @param primaryKey the primary key of this portlet 058 */ 059 public void setPrimaryKey(long primaryKey); 060 061 /** 062 * Returns the ID of this portlet. 063 * 064 * @return the ID of this portlet 065 */ 066 public long getId(); 067 068 /** 069 * Sets the ID of this portlet. 070 * 071 * @param id the ID of this portlet 072 */ 073 public void setId(long id); 074 075 /** 076 * Returns the company ID of this portlet. 077 * 078 * @return the company ID of this portlet 079 */ 080 public long getCompanyId(); 081 082 /** 083 * Sets the company ID of this portlet. 084 * 085 * @param companyId the company ID of this portlet 086 */ 087 public void setCompanyId(long companyId); 088 089 /** 090 * Returns the portlet ID of this portlet. 091 * 092 * @return the portlet ID of this portlet 093 */ 094 @AutoEscape 095 public String getPortletId(); 096 097 /** 098 * Sets the portlet ID of this portlet. 099 * 100 * @param portletId the portlet ID of this portlet 101 */ 102 public void setPortletId(String portletId); 103 104 /** 105 * Returns the roles of this portlet. 106 * 107 * @return the roles of this portlet 108 */ 109 @AutoEscape 110 public String getRoles(); 111 112 /** 113 * Sets the roles of this portlet. 114 * 115 * @param roles the roles of this portlet 116 */ 117 public void setRoles(String roles); 118 119 /** 120 * Returns the active of this portlet. 121 * 122 * @return the active of this portlet 123 */ 124 public boolean getActive(); 125 126 /** 127 * Returns <code>true</code> if this portlet is active. 128 * 129 * @return <code>true</code> if this portlet is active; <code>false</code> otherwise 130 */ 131 public boolean isActive(); 132 133 /** 134 * Sets whether this portlet is active. 135 * 136 * @param active the active of this portlet 137 */ 138 public void setActive(boolean active); 139 140 @Override 141 public boolean isNew(); 142 143 @Override 144 public void setNew(boolean n); 145 146 @Override 147 public boolean isCachedModel(); 148 149 @Override 150 public void setCachedModel(boolean cachedModel); 151 152 @Override 153 public boolean isEscapedModel(); 154 155 @Override 156 public Serializable getPrimaryKeyObj(); 157 158 @Override 159 public void setPrimaryKeyObj(Serializable primaryKeyObj); 160 161 @Override 162 public ExpandoBridge getExpandoBridge(); 163 164 @Override 165 public void setExpandoBridgeAttributes(BaseModel<?> baseModel); 166 167 @Override 168 public void setExpandoBridgeAttributes(ExpandoBridge expandoBridge); 169 170 @Override 171 public void setExpandoBridgeAttributes(ServiceContext serviceContext); 172 173 @Override 174 public Object clone(); 175 176 @Override 177 public int compareTo(Portlet portlet); 178 179 @Override 180 public int hashCode(); 181 182 @Override 183 public CacheModel<Portlet> toCacheModel(); 184 185 @Override 186 public Portlet toEscapedModel(); 187 188 @Override 189 public Portlet toUnescapedModel(); 190 191 @Override 192 public String toString(); 193 194 @Override 195 public String toXmlString(); 196 }