001 /** 002 * Copyright (c) 2000-2012 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.service.persistence; 016 017 import com.liferay.portal.model.PluginSetting; 018 019 /** 020 * The persistence interface for the plugin setting service. 021 * 022 * <p> 023 * Caching information and settings can be found in <code>portal.properties</code> 024 * </p> 025 * 026 * @author Brian Wing Shun Chan 027 * @see PluginSettingPersistenceImpl 028 * @see PluginSettingUtil 029 * @generated 030 */ 031 public interface PluginSettingPersistence extends BasePersistence<PluginSetting> { 032 /* 033 * NOTE FOR DEVELOPERS: 034 * 035 * Never modify or reference this interface directly. Always use {@link PluginSettingUtil} to access the plugin setting persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 036 */ 037 038 /** 039 * Caches the plugin setting in the entity cache if it is enabled. 040 * 041 * @param pluginSetting the plugin setting 042 */ 043 public void cacheResult( 044 com.liferay.portal.model.PluginSetting pluginSetting); 045 046 /** 047 * Caches the plugin settings in the entity cache if it is enabled. 048 * 049 * @param pluginSettings the plugin settings 050 */ 051 public void cacheResult( 052 java.util.List<com.liferay.portal.model.PluginSetting> pluginSettings); 053 054 /** 055 * Creates a new plugin setting with the primary key. Does not add the plugin setting to the database. 056 * 057 * @param pluginSettingId the primary key for the new plugin setting 058 * @return the new plugin setting 059 */ 060 public com.liferay.portal.model.PluginSetting create(long pluginSettingId); 061 062 /** 063 * Removes the plugin setting with the primary key from the database. Also notifies the appropriate model listeners. 064 * 065 * @param pluginSettingId the primary key of the plugin setting 066 * @return the plugin setting that was removed 067 * @throws com.liferay.portal.NoSuchPluginSettingException if a plugin setting with the primary key could not be found 068 * @throws SystemException if a system exception occurred 069 */ 070 public com.liferay.portal.model.PluginSetting remove(long pluginSettingId) 071 throws com.liferay.portal.NoSuchPluginSettingException, 072 com.liferay.portal.kernel.exception.SystemException; 073 074 public com.liferay.portal.model.PluginSetting updateImpl( 075 com.liferay.portal.model.PluginSetting pluginSetting, boolean merge) 076 throws com.liferay.portal.kernel.exception.SystemException; 077 078 /** 079 * Returns the plugin setting with the primary key or throws a {@link com.liferay.portal.NoSuchPluginSettingException} if it could not be found. 080 * 081 * @param pluginSettingId the primary key of the plugin setting 082 * @return the plugin setting 083 * @throws com.liferay.portal.NoSuchPluginSettingException if a plugin setting with the primary key could not be found 084 * @throws SystemException if a system exception occurred 085 */ 086 public com.liferay.portal.model.PluginSetting findByPrimaryKey( 087 long pluginSettingId) 088 throws com.liferay.portal.NoSuchPluginSettingException, 089 com.liferay.portal.kernel.exception.SystemException; 090 091 /** 092 * Returns the plugin setting with the primary key or returns <code>null</code> if it could not be found. 093 * 094 * @param pluginSettingId the primary key of the plugin setting 095 * @return the plugin setting, or <code>null</code> if a plugin setting with the primary key could not be found 096 * @throws SystemException if a system exception occurred 097 */ 098 public com.liferay.portal.model.PluginSetting fetchByPrimaryKey( 099 long pluginSettingId) 100 throws com.liferay.portal.kernel.exception.SystemException; 101 102 /** 103 * Returns all the plugin settings where companyId = ?. 104 * 105 * @param companyId the company ID 106 * @return the matching plugin settings 107 * @throws SystemException if a system exception occurred 108 */ 109 public java.util.List<com.liferay.portal.model.PluginSetting> findByCompanyId( 110 long companyId) 111 throws com.liferay.portal.kernel.exception.SystemException; 112 113 /** 114 * Returns a range of all the plugin settings where companyId = ?. 115 * 116 * <p> 117 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 118 * </p> 119 * 120 * @param companyId the company ID 121 * @param start the lower bound of the range of plugin settings 122 * @param end the upper bound of the range of plugin settings (not inclusive) 123 * @return the range of matching plugin settings 124 * @throws SystemException if a system exception occurred 125 */ 126 public java.util.List<com.liferay.portal.model.PluginSetting> findByCompanyId( 127 long companyId, int start, int end) 128 throws com.liferay.portal.kernel.exception.SystemException; 129 130 /** 131 * Returns an ordered range of all the plugin settings where companyId = ?. 132 * 133 * <p> 134 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 135 * </p> 136 * 137 * @param companyId the company ID 138 * @param start the lower bound of the range of plugin settings 139 * @param end the upper bound of the range of plugin settings (not inclusive) 140 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 141 * @return the ordered range of matching plugin settings 142 * @throws SystemException if a system exception occurred 143 */ 144 public java.util.List<com.liferay.portal.model.PluginSetting> findByCompanyId( 145 long companyId, int start, int end, 146 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 147 throws com.liferay.portal.kernel.exception.SystemException; 148 149 /** 150 * Returns the first plugin setting in the ordered set where companyId = ?. 151 * 152 * <p> 153 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 154 * </p> 155 * 156 * @param companyId the company ID 157 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 158 * @return the first matching plugin setting 159 * @throws com.liferay.portal.NoSuchPluginSettingException if a matching plugin setting could not be found 160 * @throws SystemException if a system exception occurred 161 */ 162 public com.liferay.portal.model.PluginSetting findByCompanyId_First( 163 long companyId, 164 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 165 throws com.liferay.portal.NoSuchPluginSettingException, 166 com.liferay.portal.kernel.exception.SystemException; 167 168 /** 169 * Returns the last plugin setting in the ordered set where companyId = ?. 170 * 171 * <p> 172 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 173 * </p> 174 * 175 * @param companyId the company ID 176 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 177 * @return the last matching plugin setting 178 * @throws com.liferay.portal.NoSuchPluginSettingException if a matching plugin setting could not be found 179 * @throws SystemException if a system exception occurred 180 */ 181 public com.liferay.portal.model.PluginSetting findByCompanyId_Last( 182 long companyId, 183 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 184 throws com.liferay.portal.NoSuchPluginSettingException, 185 com.liferay.portal.kernel.exception.SystemException; 186 187 /** 188 * Returns the plugin settings before and after the current plugin setting in the ordered set where companyId = ?. 189 * 190 * <p> 191 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 192 * </p> 193 * 194 * @param pluginSettingId the primary key of the current plugin setting 195 * @param companyId the company ID 196 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 197 * @return the previous, current, and next plugin setting 198 * @throws com.liferay.portal.NoSuchPluginSettingException if a plugin setting with the primary key could not be found 199 * @throws SystemException if a system exception occurred 200 */ 201 public com.liferay.portal.model.PluginSetting[] findByCompanyId_PrevAndNext( 202 long pluginSettingId, long companyId, 203 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 204 throws com.liferay.portal.NoSuchPluginSettingException, 205 com.liferay.portal.kernel.exception.SystemException; 206 207 /** 208 * Returns the plugin setting where companyId = ? and pluginId = ? and pluginType = ? or throws a {@link com.liferay.portal.NoSuchPluginSettingException} if it could not be found. 209 * 210 * @param companyId the company ID 211 * @param pluginId the plugin ID 212 * @param pluginType the plugin type 213 * @return the matching plugin setting 214 * @throws com.liferay.portal.NoSuchPluginSettingException if a matching plugin setting could not be found 215 * @throws SystemException if a system exception occurred 216 */ 217 public com.liferay.portal.model.PluginSetting findByC_I_T(long companyId, 218 java.lang.String pluginId, java.lang.String pluginType) 219 throws com.liferay.portal.NoSuchPluginSettingException, 220 com.liferay.portal.kernel.exception.SystemException; 221 222 /** 223 * Returns the plugin setting where companyId = ? and pluginId = ? and pluginType = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 224 * 225 * @param companyId the company ID 226 * @param pluginId the plugin ID 227 * @param pluginType the plugin type 228 * @return the matching plugin setting, or <code>null</code> if a matching plugin setting could not be found 229 * @throws SystemException if a system exception occurred 230 */ 231 public com.liferay.portal.model.PluginSetting fetchByC_I_T(long companyId, 232 java.lang.String pluginId, java.lang.String pluginType) 233 throws com.liferay.portal.kernel.exception.SystemException; 234 235 /** 236 * Returns the plugin setting where companyId = ? and pluginId = ? and pluginType = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 237 * 238 * @param companyId the company ID 239 * @param pluginId the plugin ID 240 * @param pluginType the plugin type 241 * @param retrieveFromCache whether to use the finder cache 242 * @return the matching plugin setting, or <code>null</code> if a matching plugin setting could not be found 243 * @throws SystemException if a system exception occurred 244 */ 245 public com.liferay.portal.model.PluginSetting fetchByC_I_T(long companyId, 246 java.lang.String pluginId, java.lang.String pluginType, 247 boolean retrieveFromCache) 248 throws com.liferay.portal.kernel.exception.SystemException; 249 250 /** 251 * Returns all the plugin settings. 252 * 253 * @return the plugin settings 254 * @throws SystemException if a system exception occurred 255 */ 256 public java.util.List<com.liferay.portal.model.PluginSetting> findAll() 257 throws com.liferay.portal.kernel.exception.SystemException; 258 259 /** 260 * Returns a range of all the plugin settings. 261 * 262 * <p> 263 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 264 * </p> 265 * 266 * @param start the lower bound of the range of plugin settings 267 * @param end the upper bound of the range of plugin settings (not inclusive) 268 * @return the range of plugin settings 269 * @throws SystemException if a system exception occurred 270 */ 271 public java.util.List<com.liferay.portal.model.PluginSetting> findAll( 272 int start, int end) 273 throws com.liferay.portal.kernel.exception.SystemException; 274 275 /** 276 * Returns an ordered range of all the plugin settings. 277 * 278 * <p> 279 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 280 * </p> 281 * 282 * @param start the lower bound of the range of plugin settings 283 * @param end the upper bound of the range of plugin settings (not inclusive) 284 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 285 * @return the ordered range of plugin settings 286 * @throws SystemException if a system exception occurred 287 */ 288 public java.util.List<com.liferay.portal.model.PluginSetting> findAll( 289 int start, int end, 290 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 291 throws com.liferay.portal.kernel.exception.SystemException; 292 293 /** 294 * Removes all the plugin settings where companyId = ? from the database. 295 * 296 * @param companyId the company ID 297 * @throws SystemException if a system exception occurred 298 */ 299 public void removeByCompanyId(long companyId) 300 throws com.liferay.portal.kernel.exception.SystemException; 301 302 /** 303 * Removes the plugin setting where companyId = ? and pluginId = ? and pluginType = ? from the database. 304 * 305 * @param companyId the company ID 306 * @param pluginId the plugin ID 307 * @param pluginType the plugin type 308 * @throws SystemException if a system exception occurred 309 */ 310 public void removeByC_I_T(long companyId, java.lang.String pluginId, 311 java.lang.String pluginType) 312 throws com.liferay.portal.NoSuchPluginSettingException, 313 com.liferay.portal.kernel.exception.SystemException; 314 315 /** 316 * Removes all the plugin settings from the database. 317 * 318 * @throws SystemException if a system exception occurred 319 */ 320 public void removeAll() 321 throws com.liferay.portal.kernel.exception.SystemException; 322 323 /** 324 * Returns the number of plugin settings where companyId = ?. 325 * 326 * @param companyId the company ID 327 * @return the number of matching plugin settings 328 * @throws SystemException if a system exception occurred 329 */ 330 public int countByCompanyId(long companyId) 331 throws com.liferay.portal.kernel.exception.SystemException; 332 333 /** 334 * Returns the number of plugin settings where companyId = ? and pluginId = ? and pluginType = ?. 335 * 336 * @param companyId the company ID 337 * @param pluginId the plugin ID 338 * @param pluginType the plugin type 339 * @return the number of matching plugin settings 340 * @throws SystemException if a system exception occurred 341 */ 342 public int countByC_I_T(long companyId, java.lang.String pluginId, 343 java.lang.String pluginType) 344 throws com.liferay.portal.kernel.exception.SystemException; 345 346 /** 347 * Returns the number of plugin settings. 348 * 349 * @return the number of plugin settings 350 * @throws SystemException if a system exception occurred 351 */ 352 public int countAll() 353 throws com.liferay.portal.kernel.exception.SystemException; 354 }