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.journal.service; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.exception.PortalException; 020 import com.liferay.portal.kernel.exception.SystemException; 021 import com.liferay.portal.kernel.search.IndexableType; 022 import com.liferay.portal.kernel.transaction.Isolation; 023 import com.liferay.portal.kernel.transaction.Propagation; 024 import com.liferay.portal.kernel.transaction.Transactional; 025 import com.liferay.portal.model.SystemEventConstants; 026 import com.liferay.portal.service.BaseLocalService; 027 import com.liferay.portal.service.PersistedModelLocalService; 028 029 /** 030 * Provides the local service interface for JournalArticle. Methods of this 031 * service will not have security checks based on the propagated JAAS 032 * credentials because this service can only be accessed from within the same 033 * VM. 034 * 035 * @author Brian Wing Shun Chan 036 * @see JournalArticleLocalServiceUtil 037 * @see com.liferay.portlet.journal.service.base.JournalArticleLocalServiceBaseImpl 038 * @see com.liferay.portlet.journal.service.impl.JournalArticleLocalServiceImpl 039 * @generated 040 */ 041 @ProviderType 042 @Transactional(isolation = Isolation.PORTAL, rollbackFor = { 043 PortalException.class, SystemException.class}) 044 public interface JournalArticleLocalService extends BaseLocalService, 045 PersistedModelLocalService { 046 /* 047 * NOTE FOR DEVELOPERS: 048 * 049 * Never modify or reference this interface directly. Always use {@link JournalArticleLocalServiceUtil} to access the journal article local service. Add custom service methods to {@link com.liferay.portlet.journal.service.impl.JournalArticleLocalServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface. 050 */ 051 052 /** 053 * Adds the journal article to the database. Also notifies the appropriate model listeners. 054 * 055 * @param journalArticle the journal article 056 * @return the journal article that was added 057 * @throws SystemException if a system exception occurred 058 */ 059 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 060 public com.liferay.portlet.journal.model.JournalArticle addJournalArticle( 061 com.liferay.portlet.journal.model.JournalArticle journalArticle) 062 throws com.liferay.portal.kernel.exception.SystemException; 063 064 /** 065 * Creates a new journal article with the primary key. Does not add the journal article to the database. 066 * 067 * @param id the primary key for the new journal article 068 * @return the new journal article 069 */ 070 public com.liferay.portlet.journal.model.JournalArticle createJournalArticle( 071 long id); 072 073 /** 074 * Deletes the journal article with the primary key from the database. Also notifies the appropriate model listeners. 075 * 076 * @param id the primary key of the journal article 077 * @return the journal article that was removed 078 * @throws PortalException if a journal article with the primary key could not be found 079 * @throws SystemException if a system exception occurred 080 */ 081 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 082 public com.liferay.portlet.journal.model.JournalArticle deleteJournalArticle( 083 long id) 084 throws com.liferay.portal.kernel.exception.PortalException, 085 com.liferay.portal.kernel.exception.SystemException; 086 087 /** 088 * Deletes the journal article from the database. Also notifies the appropriate model listeners. 089 * 090 * @param journalArticle the journal article 091 * @return the journal article that was removed 092 * @throws SystemException if a system exception occurred 093 */ 094 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 095 public com.liferay.portlet.journal.model.JournalArticle deleteJournalArticle( 096 com.liferay.portlet.journal.model.JournalArticle journalArticle) 097 throws com.liferay.portal.kernel.exception.SystemException; 098 099 public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery(); 100 101 /** 102 * Performs a dynamic query on the database and returns the matching rows. 103 * 104 * @param dynamicQuery the dynamic query 105 * @return the matching rows 106 * @throws SystemException if a system exception occurred 107 */ 108 @SuppressWarnings("rawtypes") 109 public java.util.List dynamicQuery( 110 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 111 throws com.liferay.portal.kernel.exception.SystemException; 112 113 /** 114 * Performs a dynamic query on the database and returns a range of the matching rows. 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.journal.model.impl.JournalArticleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 118 * </p> 119 * 120 * @param dynamicQuery the dynamic query 121 * @param start the lower bound of the range of model instances 122 * @param end the upper bound of the range of model instances (not inclusive) 123 * @return the range of matching rows 124 * @throws SystemException if a system exception occurred 125 */ 126 @SuppressWarnings("rawtypes") 127 public java.util.List dynamicQuery( 128 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 129 int end) throws com.liferay.portal.kernel.exception.SystemException; 130 131 /** 132 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 133 * 134 * <p> 135 * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.journal.model.impl.JournalArticleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 136 * </p> 137 * 138 * @param dynamicQuery the dynamic query 139 * @param start the lower bound of the range of model instances 140 * @param end the upper bound of the range of model instances (not inclusive) 141 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 142 * @return the ordered range of matching rows 143 * @throws SystemException if a system exception occurred 144 */ 145 @SuppressWarnings("rawtypes") 146 public java.util.List dynamicQuery( 147 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 148 int end, 149 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 150 throws com.liferay.portal.kernel.exception.SystemException; 151 152 /** 153 * Returns the number of rows that match the dynamic query. 154 * 155 * @param dynamicQuery the dynamic query 156 * @return the number of rows that match the dynamic query 157 * @throws SystemException if a system exception occurred 158 */ 159 public long dynamicQueryCount( 160 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 161 throws com.liferay.portal.kernel.exception.SystemException; 162 163 /** 164 * Returns the number of rows that match the dynamic query. 165 * 166 * @param dynamicQuery the dynamic query 167 * @param projection the projection to apply to the query 168 * @return the number of rows that match the dynamic query 169 * @throws SystemException if a system exception occurred 170 */ 171 public long dynamicQueryCount( 172 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, 173 com.liferay.portal.kernel.dao.orm.Projection projection) 174 throws com.liferay.portal.kernel.exception.SystemException; 175 176 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 177 public com.liferay.portlet.journal.model.JournalArticle fetchJournalArticle( 178 long id) throws com.liferay.portal.kernel.exception.SystemException; 179 180 /** 181 * Returns the journal article with the matching UUID and company. 182 * 183 * @param uuid the journal article's UUID 184 * @param companyId the primary key of the company 185 * @return the matching journal article, or <code>null</code> if a matching journal article could not be found 186 * @throws SystemException if a system exception occurred 187 */ 188 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 189 public com.liferay.portlet.journal.model.JournalArticle fetchJournalArticleByUuidAndCompanyId( 190 java.lang.String uuid, long companyId) 191 throws com.liferay.portal.kernel.exception.SystemException; 192 193 /** 194 * Returns the journal article matching the UUID and group. 195 * 196 * @param uuid the journal article's UUID 197 * @param groupId the primary key of the group 198 * @return the matching journal article, or <code>null</code> if a matching journal article could not be found 199 * @throws SystemException if a system exception occurred 200 */ 201 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 202 public com.liferay.portlet.journal.model.JournalArticle fetchJournalArticleByUuidAndGroupId( 203 java.lang.String uuid, long groupId) 204 throws com.liferay.portal.kernel.exception.SystemException; 205 206 /** 207 * Returns the journal article with the primary key. 208 * 209 * @param id the primary key of the journal article 210 * @return the journal article 211 * @throws PortalException if a journal article with the primary key could not be found 212 * @throws SystemException if a system exception occurred 213 */ 214 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 215 public com.liferay.portlet.journal.model.JournalArticle getJournalArticle( 216 long id) 217 throws com.liferay.portal.kernel.exception.PortalException, 218 com.liferay.portal.kernel.exception.SystemException; 219 220 @Override 221 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 222 public com.liferay.portal.model.PersistedModel getPersistedModel( 223 java.io.Serializable primaryKeyObj) 224 throws com.liferay.portal.kernel.exception.PortalException, 225 com.liferay.portal.kernel.exception.SystemException; 226 227 /** 228 * Returns the journal article with the matching UUID and company. 229 * 230 * @param uuid the journal article's UUID 231 * @param companyId the primary key of the company 232 * @return the matching journal article 233 * @throws PortalException if a matching journal article could not be found 234 * @throws SystemException if a system exception occurred 235 */ 236 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 237 public com.liferay.portlet.journal.model.JournalArticle getJournalArticleByUuidAndCompanyId( 238 java.lang.String uuid, long companyId) 239 throws com.liferay.portal.kernel.exception.PortalException, 240 com.liferay.portal.kernel.exception.SystemException; 241 242 /** 243 * Returns the journal article matching the UUID and group. 244 * 245 * @param uuid the journal article's UUID 246 * @param groupId the primary key of the group 247 * @return the matching journal article 248 * @throws PortalException if a matching journal article could not be found 249 * @throws SystemException if a system exception occurred 250 */ 251 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 252 public com.liferay.portlet.journal.model.JournalArticle getJournalArticleByUuidAndGroupId( 253 java.lang.String uuid, long groupId) 254 throws com.liferay.portal.kernel.exception.PortalException, 255 com.liferay.portal.kernel.exception.SystemException; 256 257 /** 258 * Returns a range of all the journal articles. 259 * 260 * <p> 261 * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.journal.model.impl.JournalArticleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 262 * </p> 263 * 264 * @param start the lower bound of the range of journal articles 265 * @param end the upper bound of the range of journal articles (not inclusive) 266 * @return the range of journal articles 267 * @throws SystemException if a system exception occurred 268 */ 269 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 270 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getJournalArticles( 271 int start, int end) 272 throws com.liferay.portal.kernel.exception.SystemException; 273 274 /** 275 * Returns the number of journal articles. 276 * 277 * @return the number of journal articles 278 * @throws SystemException if a system exception occurred 279 */ 280 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 281 public int getJournalArticlesCount() 282 throws com.liferay.portal.kernel.exception.SystemException; 283 284 /** 285 * Updates the journal article in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 286 * 287 * @param journalArticle the journal article 288 * @return the journal article that was updated 289 * @throws SystemException if a system exception occurred 290 */ 291 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 292 public com.liferay.portlet.journal.model.JournalArticle updateJournalArticle( 293 com.liferay.portlet.journal.model.JournalArticle journalArticle) 294 throws com.liferay.portal.kernel.exception.SystemException; 295 296 /** 297 * Returns the Spring bean ID for this bean. 298 * 299 * @return the Spring bean ID for this bean 300 */ 301 public java.lang.String getBeanIdentifier(); 302 303 /** 304 * Sets the Spring bean ID for this bean. 305 * 306 * @param beanIdentifier the Spring bean ID for this bean 307 */ 308 public void setBeanIdentifier(java.lang.String beanIdentifier); 309 310 /** 311 * Adds a web content article with additional parameters. 312 * 313 * @param userId the primary key of the web content article's creator/owner 314 * @param groupId the primary key of the web content article's group 315 * @param folderId the primary key of the web content article folder 316 * @param classNameId the primary key of the DDMStructure class if the web 317 content article is related to a DDM structure, the primary key of 318 the class name associated with the article, or {@link 319 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 320 * @param classPK the primary key of the DDM structure, if the primary key 321 of the DDMStructure class is given as the 322 <code>classNameId</code> parameter, the primary key of the class 323 associated with the web content article, or <code>0</code> 324 otherwise 325 * @param articleId the primary key of the web content article 326 * @param autoArticleId whether to auto generate the web content article ID 327 * @param version the web content article's version 328 * @param titleMap the web content article's locales and localized titles 329 * @param descriptionMap the web content article's locales and localized 330 descriptions 331 * @param content the HTML content wrapped in XML. For more information, 332 see the content example in the class description for {@link 333 JournalArticleLocalServiceImpl}. 334 * @param type the structure's type, if the web content article is related 335 to a DDM structure. For more information, see {@link 336 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 337 * @param ddmStructureKey the primary key of the web content article's DDM 338 structure, if the article is related to a DDM structure, or 339 <code>null</code> otherwise 340 * @param ddmTemplateKey the primary key of the web content article's DDM 341 template (optionally <code>null</code>). If the article is 342 related to a DDM structure, the template's structure must match 343 it. 344 * @param layoutUuid the unique string identifying the web content 345 article's display page 346 * @param displayDateMonth the month the web content article is set to 347 display 348 * @param displayDateDay the calendar day the web content article is set to 349 display 350 * @param displayDateYear the year the web content article is set to 351 display 352 * @param displayDateHour the hour the web content article is set to 353 display 354 * @param displayDateMinute the minute the web content article is set to 355 display 356 * @param expirationDateMonth the month the web content article is set to 357 expire 358 * @param expirationDateDay the calendar day the web content article is set 359 to expire 360 * @param expirationDateYear the year the web content article is set to 361 expire 362 * @param expirationDateHour the hour the web content article is set to 363 expire 364 * @param expirationDateMinute the minute the web content article is set to 365 expire 366 * @param neverExpire whether the web content article is not set to auto 367 expire 368 * @param reviewDateMonth the month the web content article is set for 369 review 370 * @param reviewDateDay the calendar day the web content article is set for 371 review 372 * @param reviewDateYear the year the web content article is set for review 373 * @param reviewDateHour the hour the web content article is set for review 374 * @param reviewDateMinute the minute the web content article is set for 375 review 376 * @param neverReview whether the web content article is not set for review 377 * @param indexable whether the web content article is searchable 378 * @param smallImage whether the web content article has a small image 379 * @param smallImageURL the web content article's small image URL 380 * @param smallImageFile the web content article's small image file 381 * @param images the web content's images 382 * @param articleURL the web content article's accessible URL 383 * @param serviceContext the service context to be applied. Can set the 384 UUID, creation date, modification date, expando bridge 385 attributes, guest permissions, group permissions, asset category 386 IDs, asset tag names, asset link entry IDs, the "urlTitle" 387 attribute, and workflow actions for the web content article. Can 388 also set whether to add the default guest and group permissions. 389 * @return the web content article 390 * @throws PortalException if a portal exception occurred 391 * @throws SystemException if a system exception occurred 392 */ 393 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 394 public com.liferay.portlet.journal.model.JournalArticle addArticle( 395 long userId, long groupId, long folderId, long classNameId, 396 long classPK, java.lang.String articleId, boolean autoArticleId, 397 double version, 398 java.util.Map<java.util.Locale, java.lang.String> titleMap, 399 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 400 java.lang.String content, java.lang.String type, 401 java.lang.String ddmStructureKey, java.lang.String ddmTemplateKey, 402 java.lang.String layoutUuid, int displayDateMonth, int displayDateDay, 403 int displayDateYear, int displayDateHour, int displayDateMinute, 404 int expirationDateMonth, int expirationDateDay, int expirationDateYear, 405 int expirationDateHour, int expirationDateMinute, boolean neverExpire, 406 int reviewDateMonth, int reviewDateDay, int reviewDateYear, 407 int reviewDateHour, int reviewDateMinute, boolean neverReview, 408 boolean indexable, boolean smallImage, java.lang.String smallImageURL, 409 java.io.File smallImageFile, 410 java.util.Map<java.lang.String, byte[]> images, 411 java.lang.String articleURL, 412 com.liferay.portal.service.ServiceContext serviceContext) 413 throws com.liferay.portal.kernel.exception.PortalException, 414 com.liferay.portal.kernel.exception.SystemException; 415 416 /** 417 * Adds a web content article. 418 * 419 * @param userId the primary key of the web content article's creator/owner 420 * @param groupId the primary key of the web content article's group 421 * @param folderId the primary key of the web content article folder 422 * @param titleMap the web content article's locales and localized titles 423 * @param descriptionMap the web content article's locales and localized 424 descriptions 425 * @param content the HTML content wrapped in XML. For more information, 426 see the content example in the class description for {@link 427 JournalArticleLocalServiceImpl}. 428 * @param ddmStructureKey the primary key of the web content article's DDM 429 structure, if the article is related to a DDM structure, or 430 <code>null</code> otherwise 431 * @param ddmTemplateKey the primary key of the web content article's DDM 432 template (optionally <code>null</code>). If the article is 433 related to a DDM structure, the template's structure must match 434 it. 435 * @param serviceContext the service context to be applied. Can set the 436 UUID, creation date, modification date, expando bridge 437 attributes, guest permissions, group permissions, asset category 438 IDs, asset tag names, asset link entry IDs, the "urlTitle" 439 attribute, and workflow actions for the web content article. Can 440 also set whether to add the default guest and group permissions. 441 * @return the web content article 442 * @throws PortalException if a portal exception occurred 443 * @throws SystemException if a system exception occurred 444 */ 445 public com.liferay.portlet.journal.model.JournalArticle addArticle( 446 long userId, long groupId, long folderId, 447 java.util.Map<java.util.Locale, java.lang.String> titleMap, 448 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 449 java.lang.String content, java.lang.String ddmStructureKey, 450 java.lang.String ddmTemplateKey, 451 com.liferay.portal.service.ServiceContext serviceContext) 452 throws com.liferay.portal.kernel.exception.PortalException, 453 com.liferay.portal.kernel.exception.SystemException; 454 455 /** 456 * Adds the resources to the web content article. 457 * 458 * @param article the web content article 459 * @param addGroupPermissions whether to add group permissions 460 * @param addGuestPermissions whether to add guest permissions 461 * @throws PortalException if no portal actions could be found associated 462 with the web content article or if a portal exception occurred 463 * @throws SystemException if a system exception occurred 464 */ 465 public void addArticleResources( 466 com.liferay.portlet.journal.model.JournalArticle article, 467 boolean addGroupPermissions, boolean addGuestPermissions) 468 throws com.liferay.portal.kernel.exception.PortalException, 469 com.liferay.portal.kernel.exception.SystemException; 470 471 /** 472 * Adds the model resources with the permissions to the web content article. 473 * 474 * @param article the web content article to add resources to 475 * @param groupPermissions the group permissions to be added 476 * @param guestPermissions the guest permissions to be added 477 * @throws PortalException if a portal exception occurred 478 * @throws SystemException if a system exception occurred 479 */ 480 public void addArticleResources( 481 com.liferay.portlet.journal.model.JournalArticle article, 482 java.lang.String[] groupPermissions, java.lang.String[] guestPermissions) 483 throws com.liferay.portal.kernel.exception.PortalException, 484 com.liferay.portal.kernel.exception.SystemException; 485 486 /** 487 * Adds the resources to the most recently created web content article. 488 * 489 * @param groupId the primary key of the web content article's group 490 * @param articleId the primary key of the web content article 491 * @param addGroupPermissions whether to add group permissions 492 * @param addGuestPermissions whether to add guest permissions 493 * @throws PortalException if a portal exception occurred 494 * @throws SystemException if a system exception occurred 495 */ 496 public void addArticleResources(long groupId, java.lang.String articleId, 497 boolean addGroupPermissions, boolean addGuestPermissions) 498 throws com.liferay.portal.kernel.exception.PortalException, 499 com.liferay.portal.kernel.exception.SystemException; 500 501 /** 502 * Adds the resources with the permissions to the most recently created web 503 * content article. 504 * 505 * @param groupId the primary key of the web content article's group 506 * @param articleId the primary key of the web content article 507 * @param groupPermissions the group permissions to be added 508 * @param guestPermissions the guest permissions to be added 509 * @throws PortalException if a portal exception occurred 510 * @throws SystemException if a system exception occurred 511 */ 512 public void addArticleResources(long groupId, java.lang.String articleId, 513 java.lang.String[] groupPermissions, java.lang.String[] guestPermissions) 514 throws com.liferay.portal.kernel.exception.PortalException, 515 com.liferay.portal.kernel.exception.SystemException; 516 517 /** 518 * Returns the web content article with the group, article ID, and version. 519 * This method checks for the article's resource primary key and, if not 520 * found, creates a new one. 521 * 522 * @param groupId the primary key of the web content article's group 523 * @param articleId the primary key of the web content article 524 * @param version the web content article's version 525 * @return the matching web content article 526 * @throws PortalException if a matching web content article could not be 527 found 528 * @throws SystemException if a system exception occurred 529 */ 530 public com.liferay.portlet.journal.model.JournalArticle checkArticleResourcePrimKey( 531 long groupId, java.lang.String articleId, double version) 532 throws com.liferay.portal.kernel.exception.PortalException, 533 com.liferay.portal.kernel.exception.SystemException; 534 535 /** 536 * Checks all web content articles by handling their expirations and sending 537 * review notifications based on their current workflow. 538 * 539 * @throws PortalException if a portal exception occurred 540 * @throws SystemException if a system exception occurred 541 */ 542 public void checkArticles() 543 throws com.liferay.portal.kernel.exception.PortalException, 544 com.liferay.portal.kernel.exception.SystemException; 545 546 /** 547 * Checks the web content article matching the group, article ID, and 548 * version, replacing escaped newline and return characters with non-escaped 549 * newline and return characters. 550 * 551 * @param groupId the primary key of the web content article's group 552 * @param articleId the primary key of the web content article 553 * @param version the web content article's version 554 * @throws PortalException if a matching web content article could not be 555 found 556 * @throws SystemException if a system exception occurred 557 */ 558 public void checkNewLine(long groupId, java.lang.String articleId, 559 double version) 560 throws com.liferay.portal.kernel.exception.PortalException, 561 com.liferay.portal.kernel.exception.SystemException; 562 563 /** 564 * Checks the web content article matching the group, article ID, and 565 * version for an associated structure. If no structure is associated, 566 * return; otherwise check that the article and structure match. 567 * 568 * @param groupId the primary key of the web content article's group 569 * @param articleId the primary key of the web content article 570 * @param version the web content article's version 571 * @throws PortalException if a matching web content article could not be 572 found, if the article's structure does not match it, or if a 573 portal exception occurred 574 * @throws SystemException if a system exception occurred 575 */ 576 public void checkStructure(long groupId, java.lang.String articleId, 577 double version) 578 throws com.liferay.portal.kernel.exception.PortalException, 579 com.liferay.portal.kernel.exception.SystemException; 580 581 /** 582 * Copies the web content article matching the group, article ID, and 583 * version. This method creates a new article, extracting all the values 584 * from the old one and updating its article ID. 585 * 586 * @param userId the primary key of the web content article's creator/owner 587 * @param groupId the primary key of the web content article's group 588 * @param oldArticleId the primary key of the old web content article 589 * @param newArticleId the primary key of the new web content article 590 * @param autoArticleId whether to auto-generate the web content article ID 591 * @param version the web content article's version 592 * @return the new web content article 593 * @throws PortalException if a matching web content article could not be 594 found or if a portal exception occurred 595 * @throws SystemException if a system exception occurred 596 */ 597 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 598 public com.liferay.portlet.journal.model.JournalArticle copyArticle( 599 long userId, long groupId, java.lang.String oldArticleId, 600 java.lang.String newArticleId, boolean autoArticleId, double version) 601 throws com.liferay.portal.kernel.exception.PortalException, 602 com.liferay.portal.kernel.exception.SystemException; 603 604 /** 605 * Deletes the web content article and its resources. 606 * 607 * @param article the web content article 608 * @throws PortalException if a portal exception occurred 609 * @throws SystemException if a system exception occurred 610 */ 611 @com.liferay.portal.kernel.systemevent.SystemEvent(action = SystemEventConstants.ACTION_SKIP, send = false) 612 public com.liferay.portlet.journal.model.JournalArticle deleteArticle( 613 com.liferay.portlet.journal.model.JournalArticle article) 614 throws com.liferay.portal.kernel.exception.PortalException, 615 com.liferay.portal.kernel.exception.SystemException; 616 617 /** 618 * Deletes the web content article and its resources, optionally sending 619 * email notifying denial of the article if it had not yet been approved. 620 * 621 * @param article the web content article 622 * @param articleURL the web content article's accessible URL to include in 623 email notifications (optionally <code>null</code>) 624 * @param serviceContext the service context to be applied (optionally 625 <code>null</code>). Can set the portlet preferences that include 626 email information to notify recipients of the unapproved web 627 content's denial. 628 * @throws PortalException if a portal exception occurred 629 * @throws SystemException if a system exception occurred 630 */ 631 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 632 @com.liferay.portal.kernel.systemevent.SystemEvent(action = SystemEventConstants.ACTION_SKIP, send = false) 633 public com.liferay.portlet.journal.model.JournalArticle deleteArticle( 634 com.liferay.portlet.journal.model.JournalArticle article, 635 java.lang.String articleURL, 636 com.liferay.portal.service.ServiceContext serviceContext) 637 throws com.liferay.portal.kernel.exception.PortalException, 638 com.liferay.portal.kernel.exception.SystemException; 639 640 /** 641 * Deletes the web content article and its resources matching the group, 642 * article ID, and version, optionally sending email notifying denial of the 643 * web content article if it had not yet been approved. 644 * 645 * @param groupId the primary key of the web content article's group 646 * @param articleId the primary key of the web content article 647 * @param version the web content article's version 648 * @param articleURL the web content article's accessible URL 649 * @param serviceContext the service context to be applied. Can set the 650 portlet preferences that include email information to notify 651 recipients of the unapproved web content article's denial. 652 * @throws PortalException if a matching web content article could not be 653 found or if a portal exception occurred 654 * @throws SystemException if a system exception occurred 655 */ 656 public com.liferay.portlet.journal.model.JournalArticle deleteArticle( 657 long groupId, java.lang.String articleId, double version, 658 java.lang.String articleURL, 659 com.liferay.portal.service.ServiceContext serviceContext) 660 throws com.liferay.portal.kernel.exception.PortalException, 661 com.liferay.portal.kernel.exception.SystemException; 662 663 /** 664 * Deletes all web content articles and their resources matching the group 665 * and article ID, optionally sending email notifying denial of article if 666 * it had not yet been approved. 667 * 668 * @param groupId the primary key of the web content article's group 669 * @param articleId the primary key of the web content article 670 * @param serviceContext the service context to be applied. Can set the 671 portlet preferences that include email information to notify 672 recipients of the unapproved web content article's denial. 673 * @throws PortalException if a portal exception occurred 674 * @throws SystemException if a system exception occurred 675 */ 676 public void deleteArticle(long groupId, java.lang.String articleId, 677 com.liferay.portal.service.ServiceContext serviceContext) 678 throws com.liferay.portal.kernel.exception.PortalException, 679 com.liferay.portal.kernel.exception.SystemException; 680 681 /** 682 * Deletes all the group's web content articles and resources. 683 * 684 * @param groupId the primary key of the web content article's group 685 * @throws PortalException if a portal exception occurred 686 * @throws SystemException if a system exception occurred 687 */ 688 public void deleteArticles(long groupId) 689 throws com.liferay.portal.kernel.exception.PortalException, 690 com.liferay.portal.kernel.exception.SystemException; 691 692 /** 693 * Deletes all the group's web content articles and resources in the folder, 694 * including recycled articles. 695 * 696 * @param groupId the primary key of the web content article's group 697 * @param folderId the primary key of the web content article folder 698 * @throws PortalException if a portal exception occurred 699 * @throws SystemException if a system exception occurred 700 */ 701 public void deleteArticles(long groupId, long folderId) 702 throws com.liferay.portal.kernel.exception.PortalException, 703 com.liferay.portal.kernel.exception.SystemException; 704 705 /** 706 * Deletes all the group's web content articles and resources in the folder, 707 * optionally including recycled articles. 708 * 709 * @param groupId the primary key of the web content article's group 710 * @param folderId the primary key of the web content article folder 711 * @param includeTrashedEntries whether to include recycled web content 712 articles 713 * @throws PortalException if a portal exception occurred 714 * @throws SystemException if a system exception occurred 715 */ 716 public void deleteArticles(long groupId, long folderId, 717 boolean includeTrashedEntries) 718 throws com.liferay.portal.kernel.exception.PortalException, 719 com.liferay.portal.kernel.exception.SystemException; 720 721 public void deleteArticles(long groupId, java.lang.String className, 722 long classPK) 723 throws com.liferay.portal.kernel.exception.PortalException, 724 com.liferay.portal.kernel.exception.SystemException; 725 726 /** 727 * Deletes the layout's association with the web content articles for the 728 * group. 729 * 730 * @param groupId the primary key of the web content article's group 731 * @param layoutUuid the unique string identifying the web content 732 article's display page 733 * @throws SystemException if a system exception occurred 734 */ 735 public void deleteLayoutArticleReferences(long groupId, 736 java.lang.String layoutUuid) 737 throws com.liferay.portal.kernel.exception.SystemException; 738 739 /** 740 * Expires the web content article matching the group, article ID, and 741 * version. 742 * 743 * @param userId the primary key of the user updating the web content 744 article 745 * @param groupId the primary key of the web content article's group 746 * @param articleId the primary key of the web content article 747 * @param version the web content article's version 748 * @param articleURL the web content article's accessible URL 749 * @param serviceContext the service context to be applied. Can set the 750 modification date, status date, portlet preferences, and can set 751 whether to add the default command update for the web content 752 article. With respect to social activities, by setting the 753 service context's command to {@link 754 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 755 is considered a web content update activity; otherwise it is 756 considered a web content add activity. 757 * @return the web content article 758 * @throws PortalException if a matching web content article could not be 759 found or if a portal exception occurred 760 * @throws SystemException if a system exception occurred 761 */ 762 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 763 public com.liferay.portlet.journal.model.JournalArticle expireArticle( 764 long userId, long groupId, java.lang.String articleId, double version, 765 java.lang.String articleURL, 766 com.liferay.portal.service.ServiceContext serviceContext) 767 throws com.liferay.portal.kernel.exception.PortalException, 768 com.liferay.portal.kernel.exception.SystemException; 769 770 /** 771 * Expires the web content article matching the group and article ID, 772 * expiring all of its versions if the 773 * <code>journal.article.expire.all.versions</code> portal property is 774 * <code>true</code>, otherwise expiring only its latest approved version. 775 * 776 * @param userId the primary key of the user updating the web content 777 article 778 * @param groupId the primary key of the web content article's group 779 * @param articleId the primary key of the web content article 780 * @param articleURL the web content article's accessible URL 781 * @param serviceContext the service context to be applied. Can set the 782 modification date, status date, portlet preferences, and can set 783 whether to add the default command update for the web content 784 article. With respect to social activities, by setting the 785 service context's command to {@link 786 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 787 is considered a web content update activity; otherwise it is 788 considered a web content add activity. 789 * @throws PortalException if a matching web content article could not be 790 found or if a portal exception occurred 791 * @throws SystemException if a system exception occurred 792 */ 793 public void expireArticle(long userId, long groupId, 794 java.lang.String articleId, java.lang.String articleURL, 795 com.liferay.portal.service.ServiceContext serviceContext) 796 throws com.liferay.portal.kernel.exception.PortalException, 797 com.liferay.portal.kernel.exception.SystemException; 798 799 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 800 public com.liferay.portlet.journal.model.JournalArticle fetchArticle( 801 long groupId, java.lang.String articleId) 802 throws com.liferay.portal.kernel.exception.SystemException; 803 804 /** 805 * Returns the web content article matching the group, article ID, and 806 * version. 807 * 808 * @param groupId the primary key of the web content article's group 809 * @param articleId the primary key of the web content article 810 * @param version the web content article's version 811 * @return the web content article matching the group, article ID, and 812 version, or <code>null</code> if no web content article could be 813 found 814 */ 815 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 816 public com.liferay.portlet.journal.model.JournalArticle fetchArticle( 817 long groupId, java.lang.String articleId, double version) 818 throws com.liferay.portal.kernel.exception.SystemException; 819 820 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 821 public com.liferay.portlet.journal.model.JournalArticle fetchArticleByUrlTitle( 822 long groupId, java.lang.String urlTitle) 823 throws com.liferay.portal.kernel.exception.SystemException; 824 825 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 826 public com.liferay.portlet.journal.model.JournalArticle fetchDisplayArticle( 827 long groupId, java.lang.String articleId) 828 throws com.liferay.portal.kernel.exception.SystemException; 829 830 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 831 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticle( 832 long resourcePrimKey) 833 throws com.liferay.portal.kernel.exception.SystemException; 834 835 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 836 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticle( 837 long resourcePrimKey, int status) 838 throws com.liferay.portal.kernel.exception.SystemException; 839 840 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 841 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticle( 842 long resourcePrimKey, int[] statuses) 843 throws com.liferay.portal.kernel.exception.SystemException; 844 845 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 846 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticle( 847 long resourcePrimKey, int status, boolean preferApproved) 848 throws com.liferay.portal.kernel.exception.SystemException; 849 850 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 851 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticle( 852 long groupId, java.lang.String articleId, int status) 853 throws com.liferay.portal.kernel.exception.SystemException; 854 855 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 856 public com.liferay.portlet.journal.model.JournalArticle fetchLatestArticleByUrlTitle( 857 long groupId, java.lang.String urlTitle, int status) 858 throws com.liferay.portal.kernel.exception.SystemException; 859 860 /** 861 * Returns the latest indexable web content article matching the resource 862 * primary key. 863 * 864 * @param resourcePrimKey the primary key of the resource instance 865 * @return the latest indexable web content article matching the resource 866 primary key, or <code>null</code> if no matching web content 867 article could be found 868 */ 869 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 870 public com.liferay.portlet.journal.model.JournalArticle fetchLatestIndexableArticle( 871 long resourcePrimKey) 872 throws com.liferay.portal.kernel.exception.SystemException; 873 874 /** 875 * Returns the web content article with the ID. 876 * 877 * @param id the primary key of the web content article 878 * @return the web content article with the ID 879 * @throws PortalException if a matching web content article could not be 880 found 881 * @throws SystemException if a system exception occurred 882 */ 883 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 884 public com.liferay.portlet.journal.model.JournalArticle getArticle(long id) 885 throws com.liferay.portal.kernel.exception.PortalException, 886 com.liferay.portal.kernel.exception.SystemException; 887 888 /** 889 * Returns the latest approved web content article, or the latest unapproved 890 * article if none are approved. Both approved and unapproved articles must 891 * match the group and article ID. 892 * 893 * @param groupId the primary key of the web content article's group 894 * @param articleId the primary key of the web content article 895 * @return the matching web content article 896 * @throws PortalException if a matching web content article could not be 897 found 898 * @throws SystemException if a system exception occurred 899 */ 900 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 901 public com.liferay.portlet.journal.model.JournalArticle getArticle( 902 long groupId, java.lang.String articleId) 903 throws com.liferay.portal.kernel.exception.PortalException, 904 com.liferay.portal.kernel.exception.SystemException; 905 906 /** 907 * Returns the web content article matching the group, article ID, and 908 * version. 909 * 910 * @param groupId the primary key of the web content article's group 911 * @param articleId the primary key of the web content article 912 * @param version the web content article's version 913 * @return the matching web content article 914 * @throws PortalException if a matching web content article could not be 915 found 916 * @throws SystemException if a system exception occurred 917 */ 918 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 919 public com.liferay.portlet.journal.model.JournalArticle getArticle( 920 long groupId, java.lang.String articleId, double version) 921 throws com.liferay.portal.kernel.exception.PortalException, 922 com.liferay.portal.kernel.exception.SystemException; 923 924 /** 925 * Returns the web content article matching the group, class name, and class 926 * PK. 927 * 928 * @param groupId the primary key of the web content article's group 929 * @param className the DDMStructure class name if the web content article 930 is related to a DDM structure, the primary key of the class name 931 associated with the article, or {@link 932 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 933 * @param classPK the primary key of the DDM structure, if the the 934 DDMStructure class name is given as the <code>className</code> 935 parameter, the primary key of the class associated with the web 936 content article, or <code>0</code> otherwise 937 * @return the matching web content article 938 * @throws PortalException if a matching web content article could not be 939 found 940 * @throws SystemException if a system exception occurred 941 */ 942 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 943 public com.liferay.portlet.journal.model.JournalArticle getArticle( 944 long groupId, java.lang.String className, long classPK) 945 throws com.liferay.portal.kernel.exception.PortalException, 946 com.liferay.portal.kernel.exception.SystemException; 947 948 /** 949 * Returns the latest web content article that is approved, or the latest 950 * unapproved article if none are approved. Both approved and unapproved 951 * articles must match the group and URL title. 952 * 953 * @param groupId the primary key of the web content article's group 954 * @param urlTitle the web content article's accessible URL title 955 * @return the matching web content article 956 * @throws PortalException if a portal exception occurred 957 * @throws SystemException if a system exception occurred 958 */ 959 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 960 public com.liferay.portlet.journal.model.JournalArticle getArticleByUrlTitle( 961 long groupId, java.lang.String urlTitle) 962 throws com.liferay.portal.kernel.exception.PortalException, 963 com.liferay.portal.kernel.exception.SystemException; 964 965 /** 966 * Returns the web content associated with the web content article and DDM 967 * template. 968 * 969 * @param article the web content article 970 * @param ddmTemplateKey the primary key of the web content article's DDM 971 template (optionally <code>null</code>). If the article is 972 related to a DDM structure, the template's structure must match 973 it. 974 * @param viewMode the mode in which the web content is being viewed 975 * @param languageId the primary key of the language translation to get 976 * @param themeDisplay the theme display 977 * @return the web content associated with the DDM template 978 * @throws PortalException if a matching DDM template could not be found or 979 if a portal exception occurred 980 * @throws SystemException if a system exception occurred 981 */ 982 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 983 public java.lang.String getArticleContent( 984 com.liferay.portlet.journal.model.JournalArticle article, 985 java.lang.String ddmTemplateKey, java.lang.String viewMode, 986 java.lang.String languageId, 987 com.liferay.portal.theme.ThemeDisplay themeDisplay) 988 throws com.liferay.portal.kernel.exception.PortalException, 989 com.liferay.portal.kernel.exception.SystemException; 990 991 /** 992 * Returns the web content matching the group, article ID, and version, and 993 * associated with the DDM template. 994 * 995 * @param groupId the primary key of the web content article's group 996 * @param articleId the primary key of the web content article 997 * @param version the web content article's version 998 * @param viewMode the mode in which the web content is being viewed 999 * @param ddmTemplateKey the primary key of the web content article's DDM 1000 template (optionally <code>null</code>). If the article is 1001 related to a DDM structure, the template's structure must match 1002 it. 1003 * @param languageId the primary key of the language translation to get 1004 * @param themeDisplay the theme display 1005 * @return the matching web content 1006 * @throws PortalException if a matching web content article or DDM template 1007 could not be found, or if a portal exception occurred 1008 * @throws SystemException if a system exception occurred 1009 */ 1010 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1011 public java.lang.String getArticleContent(long groupId, 1012 java.lang.String articleId, double version, java.lang.String viewMode, 1013 java.lang.String ddmTemplateKey, java.lang.String languageId, 1014 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1015 throws com.liferay.portal.kernel.exception.PortalException, 1016 com.liferay.portal.kernel.exception.SystemException; 1017 1018 /** 1019 * Returns the web content matching the group, article ID, and version. 1020 * 1021 * @param groupId the primary key of the web content article's group 1022 * @param articleId the primary key of the web content article 1023 * @param version the web content article's version 1024 * @param viewMode the mode in which the web content is being viewed 1025 * @param languageId the primary key of the language translation to get 1026 * @param themeDisplay the theme display 1027 * @return the matching web content 1028 * @throws PortalException if a matching web content article or DDM template 1029 could not be found, or if a portal exception occurred 1030 * @throws SystemException if a system exception occurred 1031 */ 1032 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1033 public java.lang.String getArticleContent(long groupId, 1034 java.lang.String articleId, double version, java.lang.String viewMode, 1035 java.lang.String languageId, 1036 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1037 throws com.liferay.portal.kernel.exception.PortalException, 1038 com.liferay.portal.kernel.exception.SystemException; 1039 1040 /** 1041 * Returns the latest web content matching the group and article ID, and 1042 * associated with DDM template key. 1043 * 1044 * @param groupId the primary key of the web content article's group 1045 * @param articleId the primary key of the web content article 1046 * @param viewMode the mode in which the web content is being viewed 1047 * @param ddmTemplateKey the primary key of the web content article's DDM 1048 template (optionally <code>null</code>). If the article is 1049 related to a DDM structure, the template's structure must match 1050 it. 1051 * @param languageId the primary key of the language translation to get 1052 * @param themeDisplay the theme display 1053 * @return the matching web content 1054 * @throws PortalException if a matching web content article or DDM template 1055 could not be found, or if a portal exception occurred 1056 * @throws SystemException if a system exception occurred 1057 */ 1058 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1059 public java.lang.String getArticleContent(long groupId, 1060 java.lang.String articleId, java.lang.String viewMode, 1061 java.lang.String ddmTemplateKey, java.lang.String languageId, 1062 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1063 throws com.liferay.portal.kernel.exception.PortalException, 1064 com.liferay.portal.kernel.exception.SystemException; 1065 1066 /** 1067 * Returns the latest web content matching the group and article ID. 1068 * 1069 * @param groupId the primary key of the web content article's group 1070 * @param articleId the primary key of the web content article 1071 * @param viewMode the mode in which the web content is being viewed 1072 * @param languageId the primary key of the language translation to get 1073 * @param themeDisplay the theme display 1074 * @return the matching web content 1075 * @throws PortalException if a matching web content article or DDM template 1076 could not be found, or if a portal exception occurred 1077 * @throws SystemException if a system exception occurred 1078 */ 1079 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1080 public java.lang.String getArticleContent(long groupId, 1081 java.lang.String articleId, java.lang.String viewMode, 1082 java.lang.String languageId, 1083 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1084 throws com.liferay.portal.kernel.exception.PortalException, 1085 com.liferay.portal.kernel.exception.SystemException; 1086 1087 /** 1088 * Returns a web content article display for the specified page of the 1089 * latest version of the web content article, optionally based on the DDM 1090 * template if the article is template driven. If the article is template 1091 * driven, web content transformation tokens are added from the theme 1092 * display (if not <code>null</code>) or the XML request otherwise. 1093 * 1094 * @param article the web content article 1095 * @param ddmTemplateKey the primary key of the web content article's DDM 1096 template (optionally <code>null</code>). If the article is 1097 related to a DDM structure, the template's structure must match 1098 it. 1099 * @param viewMode the mode in which the web content is being viewed 1100 * @param languageId the primary key of the language translation to get 1101 * @param page the web content's page number. Page numbers start at 1102 <code>1</code>. 1103 * @param xmlRequest the request that serializes the web content into a 1104 hierarchical hash map (optionally <code>null</code>) 1105 * @param themeDisplay the theme display 1106 * @return the web content article display 1107 * @throws PortalException if a matching DDM template could not be found or 1108 if a portal exception occurred 1109 * @throws SystemException if a system exception occurred 1110 */ 1111 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1112 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1113 com.liferay.portlet.journal.model.JournalArticle article, 1114 java.lang.String ddmTemplateKey, java.lang.String viewMode, 1115 java.lang.String languageId, int page, java.lang.String xmlRequest, 1116 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1117 throws com.liferay.portal.kernel.exception.PortalException, 1118 com.liferay.portal.kernel.exception.SystemException; 1119 1120 /** 1121 * Returns a web content article display for the first page of the specified 1122 * version of the web content article, optionally based on the DDM template 1123 * if the article is template driven. If the article is template driven, web 1124 * content transformation tokens are added from the theme display (if not 1125 * <code>null</code>) or the XML request otherwise. 1126 * 1127 * @param groupId the primary key of the web content article's group 1128 * @param articleId the primary key of the web content article 1129 * @param version the web content article's version 1130 * @param ddmTemplateKey the primary key of the web content article's DDM 1131 template (optionally <code>null</code>). If the article is 1132 related to a DDM structure, the template's structure must match 1133 it. 1134 * @param viewMode the mode in which the web content is being viewed 1135 * @param languageId the primary key of the language translation to get 1136 * @param page the web content's page number 1137 * @param xmlRequest the request that serializes the web content into a 1138 hierarchical hash map 1139 * @param themeDisplay the theme display 1140 * @return the web content article display, or <code>null</code> if the 1141 article has expired or if article's display date/time is after 1142 the current date/time 1143 * @throws PortalException if a matching web content article or DDM template 1144 could not be found, or if a portal exception occurred 1145 * @throws SystemException if a system exception occurred 1146 */ 1147 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1148 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1149 long groupId, java.lang.String articleId, double version, 1150 java.lang.String ddmTemplateKey, java.lang.String viewMode, 1151 java.lang.String languageId, int page, java.lang.String xmlRequest, 1152 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1153 throws com.liferay.portal.kernel.exception.PortalException, 1154 com.liferay.portal.kernel.exception.SystemException; 1155 1156 /** 1157 * Returns a web content article display for the first page of the specified 1158 * version of the web content article matching the group and article ID, 1159 * optionally based on the DDM template if the article is template driven. 1160 * If the article is template driven, web content transformation tokens are 1161 * added from the theme display (if not <code>null</code>). 1162 * 1163 * @param groupId the primary key of the web content article's group 1164 * @param articleId the primary key of the web content article 1165 * @param version the web content article's version 1166 * @param ddmTemplateKey the primary key of the web content article's DDM 1167 template (optionally <code>null</code>). If the article is 1168 related to a DDM structure, the template's structure must match 1169 it. 1170 * @param viewMode the mode in which the web content is being viewed 1171 * @param languageId the primary key of the language translation to get 1172 * @param themeDisplay the theme display 1173 * @return the web content article display, or <code>null</code> if the 1174 article has expired or if article's display date/time is after 1175 the current date/time 1176 * @throws PortalException if a matching web content article or DDM template 1177 could not be found, or if a portal exception occurred 1178 * @throws SystemException if a system exception occurred 1179 */ 1180 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1181 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1182 long groupId, java.lang.String articleId, double version, 1183 java.lang.String ddmTemplateKey, java.lang.String viewMode, 1184 java.lang.String languageId, 1185 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1186 throws com.liferay.portal.kernel.exception.PortalException, 1187 com.liferay.portal.kernel.exception.SystemException; 1188 1189 /** 1190 * Returns a web content article display for the first page of the latest 1191 * version of the web content article matching the group and article ID. If 1192 * the article is template driven, web content transformation tokens are 1193 * added from the theme display (if not <code>null</code>) or the XML 1194 * request otherwise. 1195 * 1196 * @param groupId the primary key of the web content article's group 1197 * @param articleId the primary key of the web content article 1198 * @param viewMode the mode in which the web content is being viewed 1199 * @param languageId the primary key of the language translation to get 1200 * @param page the web content's page number 1201 * @param xmlRequest the request that serializes the web content into a 1202 hierarchical hash map 1203 * @param themeDisplay the theme display 1204 * @return the web content article display, or <code>null</code> if the 1205 article has expired or if article's display date/time is after 1206 the current date/time 1207 * @throws PortalException if a matching web content article or DDM template 1208 could not be found, or if a portal exception occurred 1209 * @throws SystemException if a system exception occurred 1210 */ 1211 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1212 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1213 long groupId, java.lang.String articleId, java.lang.String viewMode, 1214 java.lang.String languageId, int page, java.lang.String xmlRequest, 1215 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1216 throws com.liferay.portal.kernel.exception.PortalException, 1217 com.liferay.portal.kernel.exception.SystemException; 1218 1219 /** 1220 * Returns a web content article display for the specified page of the 1221 * latest version of the web content article matching the group and article 1222 * ID, optionally based on the DDM template if the article is template 1223 * driven. If the article is template driven, web content transformation 1224 * tokens are added from the theme display (if not <code>null</code>) or the 1225 * XML request otherwise. 1226 * 1227 * @param groupId the primary key of the web content article's group 1228 * @param articleId the primary key of the web content article 1229 * @param ddmTemplateKey the primary key of the web content article's DDM 1230 template (optionally <code>null</code>). If the article is 1231 related to a DDM structure, the template's structure must match 1232 it. 1233 * @param viewMode the mode in which the web content is being viewed 1234 * @param languageId the primary key of the language translation to get 1235 * @param page the web content's page number 1236 * @param xmlRequest the request that serializes the web content into a 1237 hierarchical hash map 1238 * @param themeDisplay the theme display 1239 * @return the web content article display, or <code>null</code> if the 1240 article has expired or if article's display date/time is after 1241 the current date/time 1242 * @throws PortalException if a matching web content article or DDM template 1243 could not be found, or if a portal exception occurred 1244 * @throws SystemException if a system exception occurred 1245 */ 1246 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1247 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1248 long groupId, java.lang.String articleId, 1249 java.lang.String ddmTemplateKey, java.lang.String viewMode, 1250 java.lang.String languageId, int page, java.lang.String xmlRequest, 1251 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1252 throws com.liferay.portal.kernel.exception.PortalException, 1253 com.liferay.portal.kernel.exception.SystemException; 1254 1255 /** 1256 * Returns a web content article display for the first page of the latest 1257 * version of the web content article matching the group and article ID, 1258 * optionally based on the DDM template if the article is template driven. 1259 * If the article is template driven, web content transformation tokens are 1260 * added from the theme display (if not <code>null</code>). 1261 * 1262 * @param groupId the primary key of the web content article's group 1263 * @param articleId the primary key of the web content article 1264 * @param ddmTemplateKey the primary key of the web content article's DDM 1265 template (optionally <code>null</code>). If the article is 1266 related to a DDM structure, the template's structure must match 1267 it. 1268 * @param viewMode the mode in which the web content is being viewed 1269 * @param languageId the primary key of the language translation to get 1270 * @param themeDisplay the theme display 1271 * @return the web content article display, or <code>null</code> if the 1272 article has expired or if article's display date/time is after 1273 the current date/time 1274 * @throws PortalException if a matching web content article or DDM template 1275 could not be found, or if a portal exception occurred 1276 * @throws SystemException if a system exception occurred 1277 */ 1278 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1279 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1280 long groupId, java.lang.String articleId, 1281 java.lang.String ddmTemplateKey, java.lang.String viewMode, 1282 java.lang.String languageId, 1283 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1284 throws com.liferay.portal.kernel.exception.PortalException, 1285 com.liferay.portal.kernel.exception.SystemException; 1286 1287 /** 1288 * Returns a web content article display for the first page of the latest 1289 * version of the web content article matching the group and article ID. If 1290 * the article is template driven, web content transformation tokens are 1291 * added from the theme display (if not <code>null</code>). 1292 * 1293 * @param groupId the primary key of the web content article's group 1294 * @param articleId the primary key of the web content article 1295 * @param viewMode the mode in which the web content is being viewed 1296 * @param languageId the primary key of the language translation to get 1297 * @param themeDisplay the theme display 1298 * @return the web content article display, or <code>null</code> if the 1299 article has expired or if article's display date/time is after 1300 the current date/time 1301 * @throws PortalException if a matching web content article or DDM template 1302 could not be found, or if a portal exception occurred 1303 * @throws SystemException if a system exception occurred 1304 */ 1305 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1306 public com.liferay.portlet.journal.model.JournalArticleDisplay getArticleDisplay( 1307 long groupId, java.lang.String articleId, java.lang.String viewMode, 1308 java.lang.String languageId, 1309 com.liferay.portal.theme.ThemeDisplay themeDisplay) 1310 throws com.liferay.portal.kernel.exception.PortalException, 1311 com.liferay.portal.kernel.exception.SystemException; 1312 1313 /** 1314 * Returns all the web content articles present in the system. 1315 * 1316 * @return the web content articles present in the system 1317 * @throws SystemException if a system exception occurred 1318 */ 1319 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1320 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles() 1321 throws com.liferay.portal.kernel.exception.SystemException; 1322 1323 /** 1324 * Returns all the web content articles belonging to the group. 1325 * 1326 * @param groupId the primary key of the web content article's group 1327 * @return the web content articles belonging to the group 1328 * @throws SystemException if a system exception occurred 1329 */ 1330 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1331 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1332 long groupId) 1333 throws com.liferay.portal.kernel.exception.SystemException; 1334 1335 /** 1336 * Returns a range of all the web content articles belonging to the group. 1337 * 1338 * <p> 1339 * Useful when paginating results. Returns a maximum of <code>end - 1340 * start</code> instances. <code>start</code> and <code>end</code> are not 1341 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1342 * refers to the first result in the set. Setting both <code>start</code> 1343 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1344 * result set. 1345 * </p> 1346 * 1347 * @param groupId the primary key of the web content article's group 1348 * @param start the lower bound of the range of web content articles to 1349 return 1350 * @param end the upper bound of the range of web content articles to 1351 return (not inclusive) 1352 * @return the range of matching web content articles 1353 * @throws SystemException if a system exception occurred 1354 */ 1355 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1356 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1357 long groupId, int start, int end) 1358 throws com.liferay.portal.kernel.exception.SystemException; 1359 1360 /** 1361 * Returns an ordered range of all the web content articles belonging to the 1362 * group. 1363 * 1364 * <p> 1365 * Useful when paginating results. Returns a maximum of <code>end - 1366 * start</code> instances. <code>start</code> and <code>end</code> are not 1367 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1368 * refers to the first result in the set. Setting both <code>start</code> 1369 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1370 * result set. 1371 * </p> 1372 * 1373 * @param groupId the primary key of the web content article's group 1374 * @param start the lower bound of the range of web content articles to 1375 return 1376 * @param end the upper bound of the range of web content articles to 1377 return (not inclusive) 1378 * @param obc the comparator to order the web content articles 1379 * @return the range of matching web content articles ordered by the 1380 comparator 1381 * @throws SystemException if a system exception occurred 1382 */ 1383 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1384 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1385 long groupId, int start, int end, 1386 com.liferay.portal.kernel.util.OrderByComparator obc) 1387 throws com.liferay.portal.kernel.exception.SystemException; 1388 1389 /** 1390 * Returns all the web content articles matching the group and folder. 1391 * 1392 * @param groupId the primary key of the web content article's group 1393 * @param folderId the primary key of the web content article folder 1394 * @return the matching web content articles 1395 * @throws SystemException if a system exception occurred 1396 */ 1397 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1398 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1399 long groupId, long folderId) 1400 throws com.liferay.portal.kernel.exception.SystemException; 1401 1402 /** 1403 * Returns a range of all the web content articles matching the group and 1404 * folder. 1405 * 1406 * <p> 1407 * Useful when paginating results. Returns a maximum of <code>end - 1408 * start</code> instances. <code>start</code> and <code>end</code> are not 1409 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1410 * refers to the first result in the set. Setting both <code>start</code> 1411 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1412 * result set. 1413 * </p> 1414 * 1415 * @param groupId the primary key of the web content article's group 1416 * @param folderId the primary key of the web content article's folder 1417 * @param start the lower bound of the range of web content articles to 1418 return 1419 * @param end the upper bound of the range of web content articles to 1420 return (not inclusive) 1421 * @return the range of matching web content articles 1422 * @throws SystemException if a system exception occurred 1423 */ 1424 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1425 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1426 long groupId, long folderId, int start, int end) 1427 throws com.liferay.portal.kernel.exception.SystemException; 1428 1429 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1430 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1431 long groupId, long folderId, int status, int start, int end) 1432 throws com.liferay.portal.kernel.exception.SystemException; 1433 1434 /** 1435 * Returns an ordered range of all the web content articles matching the 1436 * group and folder. 1437 * 1438 * <p> 1439 * Useful when paginating results. Returns a maximum of <code>end - 1440 * start</code> instances. <code>start</code> and <code>end</code> are not 1441 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1442 * refers to the first result in the set. Setting both <code>start</code> 1443 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1444 * result set. 1445 * </p> 1446 * 1447 * @param groupId the primary key of the web content article's group 1448 * @param folderId the primary key of the web content article's folder 1449 * @param start the lower bound of the range of web content articles to 1450 return 1451 * @param end the upper bound of the range of web content articles to 1452 return (not inclusive) 1453 * @param orderByComparator the comparator to order the web content 1454 articles 1455 * @return the range of matching web content articles ordered by the 1456 comparator 1457 * @throws SystemException if a system exception occurred 1458 */ 1459 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1460 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1461 long groupId, long folderId, int start, int end, 1462 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 1463 throws com.liferay.portal.kernel.exception.SystemException; 1464 1465 /** 1466 * Returns all the web content articles matching the group and article ID. 1467 * 1468 * @param groupId the primary key of the web content article's group 1469 * @param articleId the primary key of the web content article 1470 * @return the matching web content articles 1471 * @throws SystemException if a system exception occurred 1472 */ 1473 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1474 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticles( 1475 long groupId, java.lang.String articleId) 1476 throws com.liferay.portal.kernel.exception.SystemException; 1477 1478 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1479 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticlesByResourcePrimKey( 1480 long resourcePrimKey) 1481 throws com.liferay.portal.kernel.exception.SystemException; 1482 1483 /** 1484 * Returns all the web content articles matching the small image ID. 1485 * 1486 * @param smallImageId the primary key of the web content article's small 1487 image 1488 * @return the web content articles matching the small image ID 1489 * @throws SystemException if a system exception occurred 1490 */ 1491 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1492 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getArticlesBySmallImageId( 1493 long smallImageId) 1494 throws com.liferay.portal.kernel.exception.SystemException; 1495 1496 /** 1497 * Returns the number of web content articles belonging to the group. 1498 * 1499 * @param groupId the primary key of the web content article's group 1500 * @return the number of web content articles belonging to the group 1501 * @throws SystemException if a system exception occurred 1502 */ 1503 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1504 public int getArticlesCount(long groupId) 1505 throws com.liferay.portal.kernel.exception.SystemException; 1506 1507 /** 1508 * Returns the number of web content articles matching the group and folder. 1509 * 1510 * @param groupId the primary key of the web content article's group 1511 * @param folderId the primary key of the web content article's folder 1512 * @return the number of matching web content articles 1513 * @throws SystemException if a system exception occurred 1514 */ 1515 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1516 public int getArticlesCount(long groupId, long folderId) 1517 throws com.liferay.portal.kernel.exception.SystemException; 1518 1519 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1520 public int getArticlesCount(long groupId, long folderId, int status) 1521 throws com.liferay.portal.kernel.exception.SystemException; 1522 1523 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1524 public int getArticlesCount(long groupId, java.lang.String articleId) 1525 throws com.liferay.portal.kernel.exception.SystemException; 1526 1527 /** 1528 * Returns an ordered range of all the web content articles matching the 1529 * company, version, and workflow status. 1530 * 1531 * <p> 1532 * Useful when paginating results. Returns a maximum of <code>end - 1533 * start</code> instances. <code>start</code> and <code>end</code> are not 1534 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1535 * refers to the first result in the set. Setting both <code>start</code> 1536 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1537 * result set. 1538 * </p> 1539 * 1540 * @param companyId the primary key of the web content article's company 1541 * @param version the web content article's version 1542 * @param status the web content article's workflow status. For more 1543 information see {@link WorkflowConstants} for constants starting 1544 with the "STATUS_" prefix. 1545 * @param start the lower bound of the range of web content articles to 1546 return 1547 * @param end the upper bound of the range of web content articles to 1548 return (not inclusive) 1549 * @return the range of matching web content articles ordered by article ID 1550 * @throws SystemException if a system exception occurred 1551 */ 1552 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1553 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getCompanyArticles( 1554 long companyId, double version, int status, int start, int end) 1555 throws com.liferay.portal.kernel.exception.SystemException; 1556 1557 /** 1558 * Returns an ordered range of all the web content articles matching the 1559 * company and workflow status. 1560 * 1561 * <p> 1562 * Useful when paginating results. Returns a maximum of <code>end - 1563 * start</code> instances. <code>start</code> and <code>end</code> are not 1564 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1565 * refers to the first result in the set. Setting both <code>start</code> 1566 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1567 * result set. 1568 * </p> 1569 * 1570 * @param companyId the primary key of the web content article's company 1571 * @param status the web content article's workflow status. For more 1572 information see {@link WorkflowConstants} for constants starting 1573 with the "STATUS_" prefix. 1574 * @param start the lower bound of the range of web content articles to 1575 return 1576 * @param end the upper bound of the range of web content articles to 1577 return (not inclusive) 1578 * @return the range of matching web content articles ordered by article ID 1579 * @throws SystemException if a system exception occurred 1580 */ 1581 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1582 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getCompanyArticles( 1583 long companyId, int status, int start, int end) 1584 throws com.liferay.portal.kernel.exception.SystemException; 1585 1586 /** 1587 * Returns the number of web content articles matching the company, version, 1588 * and workflow status. 1589 * 1590 * <p> 1591 * Useful when paginating results. Returns a maximum of <code>end - 1592 * start</code> instances. <code>start</code> and <code>end</code> are not 1593 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1594 * refers to the first result in the set. Setting both <code>start</code> 1595 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1596 * result set. 1597 * </p> 1598 * 1599 * @param companyId the primary key of the web content article's company 1600 * @param version the web content article's version 1601 * @param status the web content article's workflow status. For more 1602 information see {@link WorkflowConstants} for constants starting 1603 with the "STATUS_" prefix. 1604 * @param start the lower bound of the range of web content articles to 1605 return 1606 * @param end the upper bound of the range of web content articles to 1607 return (not inclusive) 1608 * @return the number of matching web content articles 1609 * @throws SystemException if a system exception occurred 1610 */ 1611 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1612 public int getCompanyArticlesCount(long companyId, double version, 1613 int status, int start, int end) 1614 throws com.liferay.portal.kernel.exception.SystemException; 1615 1616 /** 1617 * Returns the number of web content articles matching the company and 1618 * workflow status. 1619 * 1620 * @param companyId the primary key of the web content article's company 1621 * @param status the web content article's workflow status. For more 1622 information see {@link WorkflowConstants} for constants starting 1623 with the "STATUS_" prefix. 1624 * @return the number of matching web content articles 1625 * @throws SystemException if a system exception occurred 1626 */ 1627 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1628 public int getCompanyArticlesCount(long companyId, int status) 1629 throws com.liferay.portal.kernel.exception.SystemException; 1630 1631 /** 1632 * Returns the matching web content article currently displayed or next to 1633 * be displayed if no article is currently displayed. 1634 * 1635 * @param groupId the primary key of the web content article's group 1636 * @param articleId the primary key of the web content article 1637 * @return the matching web content article currently displayed, or the next 1638 one to be displayed if no version of the article is currently 1639 displayed 1640 * @throws PortalException if no approved matching web content articles 1641 could be found 1642 * @throws SystemException if a system exception occurred 1643 */ 1644 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1645 public com.liferay.portlet.journal.model.JournalArticle getDisplayArticle( 1646 long groupId, java.lang.String articleId) 1647 throws com.liferay.portal.kernel.exception.PortalException, 1648 com.liferay.portal.kernel.exception.SystemException; 1649 1650 /** 1651 * Returns the web content article matching the URL title that is currently 1652 * displayed or next to be displayed if no article is currently displayed. 1653 * 1654 * @param groupId the primary key of the web content article's group 1655 * @param urlTitle the web content article's accessible URL title 1656 * @return the web content article matching the URL title that is currently 1657 displayed, or next one to be displayed if no version of the 1658 article is currently displayed 1659 * @throws PortalException if no approved matching web content articles 1660 could be found 1661 * @throws SystemException if a system exception occurred 1662 */ 1663 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1664 public com.liferay.portlet.journal.model.JournalArticle getDisplayArticleByUrlTitle( 1665 long groupId, java.lang.String urlTitle) 1666 throws com.liferay.portal.kernel.exception.PortalException, 1667 com.liferay.portal.kernel.exception.SystemException; 1668 1669 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1670 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getIndexableArticlesByDDMStructureKey( 1671 java.lang.String[] ddmStructureKeys) 1672 throws com.liferay.portal.kernel.exception.SystemException; 1673 1674 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1675 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getIndexableArticlesByResourcePrimKey( 1676 long resourcePrimKey) 1677 throws com.liferay.portal.kernel.exception.SystemException; 1678 1679 /** 1680 * Returns the latest web content article matching the resource primary key, 1681 * preferring articles with approved workflow status. 1682 * 1683 * @param resourcePrimKey the primary key of the resource instance 1684 * @return the latest web content article matching the resource primary key, 1685 preferring articles with approved workflow status 1686 * @throws PortalException if a matching web content article could not be 1687 found 1688 * @throws SystemException if a system exception occurred 1689 */ 1690 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1691 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1692 long resourcePrimKey) 1693 throws com.liferay.portal.kernel.exception.PortalException, 1694 com.liferay.portal.kernel.exception.SystemException; 1695 1696 /** 1697 * Returns the latest web content article matching the resource primary key 1698 * and workflow status, preferring articles with approved workflow status. 1699 * 1700 * @param resourcePrimKey the primary key of the resource instance 1701 * @param status the web content article's workflow status. For more 1702 information see {@link WorkflowConstants} for constants starting 1703 with the "STATUS_" prefix. 1704 * @return the latest web content article matching the resource primary key 1705 and workflow status, preferring articles with approved workflow 1706 status 1707 * @throws PortalException if a matching web content article could not be 1708 found 1709 * @throws SystemException if a system exception occurred 1710 */ 1711 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1712 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1713 long resourcePrimKey, int status) 1714 throws com.liferay.portal.kernel.exception.PortalException, 1715 com.liferay.portal.kernel.exception.SystemException; 1716 1717 /** 1718 * Returns the latest web content article matching the resource primary key 1719 * and workflow status, optionally preferring articles with approved 1720 * workflow status. 1721 * 1722 * @param resourcePrimKey the primary key of the resource instance 1723 * @param status the web content article's workflow status. For more 1724 information see {@link WorkflowConstants} for constants starting 1725 with the "STATUS_" prefix. 1726 * @param preferApproved whether to prefer returning the latest matching 1727 article that has workflow status {@link 1728 WorkflowConstants#STATUS_APPROVED} over returning one that has a 1729 different status 1730 * @return the latest web content article matching the resource primary key 1731 and workflow status, optionally preferring articles with approved 1732 workflow status 1733 * @throws PortalException if a matching web content article could not be 1734 found 1735 * @throws SystemException if a system exception occurred 1736 */ 1737 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1738 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1739 long resourcePrimKey, int status, boolean preferApproved) 1740 throws com.liferay.portal.kernel.exception.PortalException, 1741 com.liferay.portal.kernel.exception.SystemException; 1742 1743 /** 1744 * Returns the latest web content article with the group and article ID. 1745 * 1746 * @param groupId the primary key of the web content article's group 1747 * @param articleId the primary key of the web content article 1748 * @return the latest matching web content article 1749 * @throws PortalException if a matching web content article could not be 1750 found 1751 * @throws SystemException if a system exception occurred 1752 */ 1753 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1754 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1755 long groupId, java.lang.String articleId) 1756 throws com.liferay.portal.kernel.exception.PortalException, 1757 com.liferay.portal.kernel.exception.SystemException; 1758 1759 /** 1760 * Returns the latest web content article matching the group, article ID, 1761 * and workflow status. 1762 * 1763 * @param groupId the primary key of the web content article's group 1764 * @param articleId the primary key of the web content article 1765 * @param status the web content article's workflow status. For more 1766 information see {@link WorkflowConstants} for constants starting 1767 with the "STATUS_" prefix. 1768 * @return the latest matching web content article 1769 * @throws PortalException if a matching web content article could not be 1770 found 1771 * @throws SystemException if a system exception occurred 1772 */ 1773 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1774 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1775 long groupId, java.lang.String articleId, int status) 1776 throws com.liferay.portal.kernel.exception.PortalException, 1777 com.liferay.portal.kernel.exception.SystemException; 1778 1779 /** 1780 * Returns the latest web content article matching the group, class name ID, 1781 * and class PK. 1782 * 1783 * @param groupId the primary key of the web content article's group 1784 * @param className the DDMStructure class name if the web content article 1785 is related to a DDM structure, the class name associated with the 1786 article, or {@link JournalArticleConstants#CLASSNAME_ID_DEFAULT} 1787 otherwise 1788 * @param classPK the primary key of the DDM structure, if the DDMStructure 1789 class name is given as the <code>className</code> parameter, the 1790 primary key of the class associated with the web content article, 1791 or <code>0</code> otherwise 1792 * @return the latest matching web content article 1793 * @throws PortalException if a matching web content article could not be 1794 found 1795 * @throws SystemException if a system exception occurred 1796 */ 1797 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1798 public com.liferay.portlet.journal.model.JournalArticle getLatestArticle( 1799 long groupId, java.lang.String className, long classPK) 1800 throws com.liferay.portal.kernel.exception.PortalException, 1801 com.liferay.portal.kernel.exception.SystemException; 1802 1803 /** 1804 * Returns the latest web content article matching the group, URL title, and 1805 * workflow status. 1806 * 1807 * @param groupId the primary key of the web content article's group 1808 * @param urlTitle the web content article's accessible URL title 1809 * @param status the web content article's workflow status. For more 1810 information see {@link WorkflowConstants} for constants starting 1811 with the "STATUS_" prefix. 1812 * @return the latest matching web content article 1813 * @throws PortalException if a matching web content article could not be 1814 found 1815 * @throws SystemException if a system exception occurred 1816 */ 1817 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1818 public com.liferay.portlet.journal.model.JournalArticle getLatestArticleByUrlTitle( 1819 long groupId, java.lang.String urlTitle, int status) 1820 throws com.liferay.portal.kernel.exception.PortalException, 1821 com.liferay.portal.kernel.exception.SystemException; 1822 1823 /** 1824 * Returns the latest version number of the web content with the group and 1825 * article ID. 1826 * 1827 * @param groupId the primary key of the web content article's group 1828 * @param articleId the primary key of the web content article 1829 * @return the latest version number of the matching web content 1830 * @throws PortalException if a matching web content article could not be 1831 found 1832 * @throws SystemException if a system exception occurred 1833 */ 1834 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1835 public double getLatestVersion(long groupId, java.lang.String articleId) 1836 throws com.liferay.portal.kernel.exception.PortalException, 1837 com.liferay.portal.kernel.exception.SystemException; 1838 1839 /** 1840 * Returns the latest version number of the web content with the group, 1841 * article ID, and workflow status. 1842 * 1843 * @param groupId the primary key of the web content article's group 1844 * @param articleId the primary key of the web content article 1845 * @param status the web content article's workflow status. For more 1846 information see {@link WorkflowConstants} for constants starting 1847 with the "STATUS_" prefix. 1848 * @return the latest version number of the matching web content 1849 * @throws PortalException if a matching web content article could not be 1850 found 1851 * @throws SystemException if a system exception occurred 1852 */ 1853 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1854 public double getLatestVersion(long groupId, java.lang.String articleId, 1855 int status) 1856 throws com.liferay.portal.kernel.exception.PortalException, 1857 com.liferay.portal.kernel.exception.SystemException; 1858 1859 /** 1860 * Returns the number of web content articles that are not recycled. 1861 * 1862 * @param groupId the primary key of the web content article's group 1863 * @param folderId the primary key of the web content article folder 1864 * @return the number of web content articles that are not recycled 1865 * @throws SystemException if a system exception occurred 1866 */ 1867 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1868 public int getNotInTrashArticlesCount(long groupId, long folderId) 1869 throws com.liferay.portal.kernel.exception.SystemException; 1870 1871 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1872 public com.liferay.portlet.journal.model.JournalArticle getOldestArticle( 1873 long groupId, java.lang.String articleId) 1874 throws com.liferay.portal.kernel.exception.PortalException, 1875 com.liferay.portal.kernel.exception.SystemException; 1876 1877 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1878 public com.liferay.portlet.journal.model.JournalArticle getOldestArticle( 1879 long groupId, java.lang.String articleId, int status) 1880 throws com.liferay.portal.kernel.exception.PortalException, 1881 com.liferay.portal.kernel.exception.SystemException; 1882 1883 /** 1884 * Returns the web content articles matching the group and DDM structure 1885 * key. 1886 * 1887 * @param groupId the primary key of the web content article's group 1888 * @param ddmStructureKey the primary key of the web content article's DDM 1889 structure 1890 * @return the matching web content articles 1891 * @throws SystemException if a system exception occurred 1892 */ 1893 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1894 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getStructureArticles( 1895 long groupId, java.lang.String ddmStructureKey) 1896 throws com.liferay.portal.kernel.exception.SystemException; 1897 1898 /** 1899 * Returns an ordered range of all the web content articles matching the 1900 * group and DDM structure key. 1901 * 1902 * <p> 1903 * Useful when paginating results. Returns a maximum of <code>end - 1904 * start</code> instances. <code>start</code> and <code>end</code> are not 1905 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1906 * refers to the first result in the set. Setting both <code>start</code> 1907 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1908 * result set. 1909 * </p> 1910 * 1911 * @param groupId the primary key of the web content article's group 1912 * @param ddmStructureKey the primary key of the web content article's DDM 1913 structure 1914 * @param start the lower bound of the range of web content articles to 1915 return 1916 * @param end the upper bound of the range of web content articles to 1917 return (not inclusive) 1918 * @param obc the comparator to order the web content articles 1919 * @return the range of matching web content articles ordered by the 1920 comparator 1921 * @throws SystemException if a system exception occurred 1922 */ 1923 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1924 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getStructureArticles( 1925 long groupId, java.lang.String ddmStructureKey, int start, int end, 1926 com.liferay.portal.kernel.util.OrderByComparator obc) 1927 throws com.liferay.portal.kernel.exception.SystemException; 1928 1929 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1930 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getStructureArticles( 1931 java.lang.String[] ddmStructureKeys) 1932 throws com.liferay.portal.kernel.exception.SystemException; 1933 1934 /** 1935 * Returns the number of web content articles matching the group and DDM 1936 * structure key. 1937 * 1938 * @param groupId the primary key of the web content article's group 1939 * @param ddmStructureKey the primary key of the web content article's DDM 1940 structure 1941 * @return the number of matching web content articles 1942 * @throws SystemException if a system exception occurred 1943 */ 1944 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1945 public int getStructureArticlesCount(long groupId, 1946 java.lang.String ddmStructureKey) 1947 throws com.liferay.portal.kernel.exception.SystemException; 1948 1949 /** 1950 * Returns the web content articles matching the group and DDM template key. 1951 * 1952 * @param groupId the primary key of the web content article's group 1953 * @param ddmTemplateKey the primary key of the web content article's DDM 1954 template (optionally <code>null</code>). If the article is 1955 related to a DDM structure, the template's structure must match 1956 it. 1957 * @return the matching web content articles 1958 * @throws SystemException if a system exception occurred 1959 */ 1960 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1961 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getTemplateArticles( 1962 long groupId, java.lang.String ddmTemplateKey) 1963 throws com.liferay.portal.kernel.exception.SystemException; 1964 1965 /** 1966 * Returns an ordered range of all the web content articles matching the 1967 * group and DDM template key. 1968 * 1969 * <p> 1970 * Useful when paginating results. Returns a maximum of <code>end - 1971 * start</code> instances. <code>start</code> and <code>end</code> are not 1972 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1973 * refers to the first result in the set. Setting both <code>start</code> 1974 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 1975 * result set. 1976 * </p> 1977 * 1978 * @param groupId the primary key of the web content article's group 1979 * @param ddmTemplateKey the primary key of the web content article's DDM 1980 template (optionally <code>null</code>). If the article is 1981 related to a DDM structure, the template's structure must match 1982 it. 1983 * @param start the lower bound of the range of web content articles to 1984 return 1985 * @param end the upper bound of the range of web content articles to 1986 return (not inclusive) 1987 * @param obc the comparator to order the web content articles 1988 * @return the range of matching web content articles ordered by the 1989 comparator 1990 * @throws SystemException if a system exception occurred 1991 */ 1992 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1993 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> getTemplateArticles( 1994 long groupId, java.lang.String ddmTemplateKey, int start, int end, 1995 com.liferay.portal.kernel.util.OrderByComparator obc) 1996 throws com.liferay.portal.kernel.exception.SystemException; 1997 1998 /** 1999 * Returns the number of web content articles matching the group and DDM 2000 * template key. 2001 * 2002 * @param groupId the primary key of the web content article's group 2003 * @param ddmTemplateKey the primary key of the web content article's DDM 2004 template (optionally <code>null</code>). If the article is 2005 related to a DDM structure, the template's structure must match 2006 it. 2007 * @return the number of matching web content articles 2008 * @throws SystemException if a system exception occurred 2009 */ 2010 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2011 public int getTemplateArticlesCount(long groupId, 2012 java.lang.String ddmTemplateKey) 2013 throws com.liferay.portal.kernel.exception.SystemException; 2014 2015 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2016 public java.lang.String getUniqueUrlTitle(long groupId, 2017 java.lang.String articleId, java.lang.String urlTitle) 2018 throws com.liferay.portal.kernel.exception.PortalException, 2019 com.liferay.portal.kernel.exception.SystemException; 2020 2021 /** 2022 * Returns <code>true</code> if the specified web content article exists. 2023 * 2024 * @param groupId the primary key of the group 2025 * @param articleId the primary key of the web content article 2026 * @return <code>true</code> if the specified web content article exists; 2027 <code>false</code> otherwise 2028 * @throws SystemException if a system exception occurred 2029 */ 2030 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2031 public boolean hasArticle(long groupId, java.lang.String articleId) 2032 throws com.liferay.portal.kernel.exception.SystemException; 2033 2034 /** 2035 * Returns <code>true</code> if the web content article, specified by group 2036 * and article ID, is the latest version. 2037 * 2038 * @param groupId the primary key of the web content article's group 2039 * @param articleId the primary key of the web content article 2040 * @param version the web content article's version 2041 * @return <code>true</code> if the specified web content article is the 2042 latest version; <code>false</code> otherwise 2043 * @throws PortalException if a matching web content article could not be 2044 found 2045 * @throws SystemException if a system exception occurred 2046 */ 2047 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2048 public boolean isLatestVersion(long groupId, java.lang.String articleId, 2049 double version) 2050 throws com.liferay.portal.kernel.exception.PortalException, 2051 com.liferay.portal.kernel.exception.SystemException; 2052 2053 /** 2054 * Returns <code>true</code> if the web content article, specified by group, 2055 * article ID, and workflow status, is the latest version. 2056 * 2057 * @param groupId the primary key of the web content article's group 2058 * @param articleId the primary key of the web content article 2059 * @param version the web content article's version 2060 * @param status the web content article's workflow status. For more 2061 information see {@link WorkflowConstants} for constants starting 2062 with the "STATUS_" prefix. 2063 * @return <code>true</code> if the specified web content article is the 2064 latest version; <code>false</code> otherwise 2065 * @throws PortalException if a matching web content article could not be 2066 found 2067 * @throws SystemException if a system exception occurred 2068 */ 2069 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2070 public boolean isLatestVersion(long groupId, java.lang.String articleId, 2071 double version, int status) 2072 throws com.liferay.portal.kernel.exception.PortalException, 2073 com.liferay.portal.kernel.exception.SystemException; 2074 2075 /** 2076 * Moves the web content article matching the group and article ID to a new 2077 * folder. 2078 * 2079 * @param groupId the primary key of the web content article's group 2080 * @param articleId the primary key of the web content article 2081 * @param newFolderId the primary key of the web content article's new 2082 folder 2083 * @return the updated web content article, which was moved to a new folder 2084 * @throws PortalException if a matching web content article could not be 2085 found 2086 * @throws SystemException if a system exception occurred 2087 */ 2088 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2089 public com.liferay.portlet.journal.model.JournalArticle moveArticle( 2090 long groupId, java.lang.String articleId, long newFolderId) 2091 throws com.liferay.portal.kernel.exception.PortalException, 2092 com.liferay.portal.kernel.exception.SystemException; 2093 2094 /** 2095 * Moves the web content article from the Recycle Bin to a new folder. 2096 * 2097 * @param userId the primary key of the user updating the web content 2098 article 2099 * @param groupId the primary key of the web content article's group 2100 * @param article the web content article 2101 * @param newFolderId the primary key of the web content article's new 2102 folder 2103 * @param serviceContext the service context to be applied. Can set the 2104 modification date, portlet preferences, and can set whether to 2105 add the default command update for the web content article. With 2106 respect to social activities, by setting the service context's 2107 command to {@link 2108 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 2109 is considered a web content update activity; otherwise it is 2110 considered a web content add activity. 2111 * @return the updated web content article, which was moved from the Recycle 2112 Bin to a new folder 2113 * @throws PortalException if a trashed web content article with the primary 2114 key could not be found or if a portal exception occurred 2115 * @throws SystemException if a system exception occurred 2116 */ 2117 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2118 public com.liferay.portlet.journal.model.JournalArticle moveArticleFromTrash( 2119 long userId, long groupId, 2120 com.liferay.portlet.journal.model.JournalArticle article, 2121 long newFolderId, 2122 com.liferay.portal.service.ServiceContext serviceContext) 2123 throws com.liferay.portal.kernel.exception.PortalException, 2124 com.liferay.portal.kernel.exception.SystemException; 2125 2126 /** 2127 * Moves the latest version of the web content article matching the group 2128 * and article ID to the recycle bin. 2129 * 2130 * @param userId the primary key of the user updating the web content 2131 article 2132 * @param article the web content article 2133 * @return the updated web content article, which was moved to the Recycle 2134 Bin 2135 * @throws PortalException if the user did not have permission to move the 2136 article to the Recycle Bin or if a portal exception occurred 2137 * @throws SystemException if a system exception occurred 2138 */ 2139 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2140 public com.liferay.portlet.journal.model.JournalArticle moveArticleToTrash( 2141 long userId, com.liferay.portlet.journal.model.JournalArticle article) 2142 throws com.liferay.portal.kernel.exception.PortalException, 2143 com.liferay.portal.kernel.exception.SystemException; 2144 2145 /** 2146 * Moves the latest version of the web content article matching the group 2147 * and article ID to the recycle bin. 2148 * 2149 * @param userId the primary key of the user updating the web content 2150 article 2151 * @param groupId the primary key of the web content article's group 2152 * @param articleId the primary key of the web content article 2153 * @return the moved web content article or <code>null</code> if no matching 2154 article was found 2155 * @throws PortalException if the user did not have permission to move the 2156 article to the Recycle Bin or if a portal exception occurred 2157 * @throws SystemException if a system exception occurred 2158 */ 2159 public com.liferay.portlet.journal.model.JournalArticle moveArticleToTrash( 2160 long userId, long groupId, java.lang.String articleId) 2161 throws com.liferay.portal.kernel.exception.PortalException, 2162 com.liferay.portal.kernel.exception.SystemException; 2163 2164 public void rebuildTree(long companyId) 2165 throws com.liferay.portal.kernel.exception.PortalException, 2166 com.liferay.portal.kernel.exception.SystemException; 2167 2168 /** 2169 * Removes the web content of the web content article matching the group, 2170 * article ID, and version, and language. 2171 * 2172 * @param groupId the primary key of the web content article's group 2173 * @param articleId the primary key of the web content article 2174 * @param version the web content article's version 2175 * @param languageId the primary key of the language locale to remove 2176 * @return the updated web content article with the locale removed 2177 * @throws PortalException if a matching web content article could not be 2178 found 2179 * @throws SystemException if a system exception occurred 2180 */ 2181 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2182 public com.liferay.portlet.journal.model.JournalArticle removeArticleLocale( 2183 long groupId, java.lang.String articleId, double version, 2184 java.lang.String languageId) 2185 throws com.liferay.portal.kernel.exception.PortalException, 2186 com.liferay.portal.kernel.exception.SystemException; 2187 2188 /** 2189 * Restores the web content article from the Recycle Bin. 2190 * 2191 * @param userId the primary key of the user restoring the web content 2192 article 2193 * @param article the web content article 2194 * @throws PortalException if the web content article with the primary key 2195 could not be found in the Recycle Bin, if the user did not have 2196 permission to restore the article, or if a portal exception 2197 occurred 2198 * @throws SystemException if a system exception occurred 2199 */ 2200 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2201 public com.liferay.portlet.journal.model.JournalArticle restoreArticleFromTrash( 2202 long userId, com.liferay.portlet.journal.model.JournalArticle article) 2203 throws com.liferay.portal.kernel.exception.PortalException, 2204 com.liferay.portal.kernel.exception.SystemException; 2205 2206 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2207 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> search( 2208 long groupId, java.util.List<java.lang.Long> folderIds, int status, 2209 int start, int end) 2210 throws com.liferay.portal.kernel.exception.SystemException; 2211 2212 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2213 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> search( 2214 long groupId, long folderId, int status, int start, int end) 2215 throws com.liferay.portal.kernel.exception.SystemException; 2216 2217 /** 2218 * Returns an ordered range of all the web content articles matching the 2219 * parameters without using the indexer, including a keywords parameter for 2220 * matching with the article's ID, title, description, and content, a DDM 2221 * structure key parameter, and a DDM template key parameter. It is 2222 * preferable to use the indexed version {@link #search(long, long, List, 2223 * long, String, String, String, LinkedHashMap, int, int, Sort)} instead of 2224 * this method wherever possible for performance reasons. 2225 * 2226 * <p> 2227 * Useful when paginating results. Returns a maximum of <code>end - 2228 * start</code> instances. <code>start</code> and <code>end</code> are not 2229 * primary keys, they are indexes in the result set. Thus, <code>0</code> 2230 * refers to the first result in the set. Setting both <code>start</code> 2231 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 2232 * result set. 2233 * </p> 2234 * 2235 * @param companyId the primary key of the web content article's company 2236 * @param groupId the primary key of the group (optionally <code>0</code>) 2237 * @param folderIds the primary keys of the web content article folders 2238 (optionally {@link java.util.Collections#EMPTY_LIST}) 2239 * @param classNameId the primary key of the DDMStructure class if the web 2240 content article is related to a DDM structure, the primary key of 2241 the class name associated with the article, or {@link 2242 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2243 * @param keywords the keywords (space separated), which may occur in the 2244 web content article ID, title, description, or content 2245 (optionally <code>null</code>). If the keywords value is not 2246 <code>null</code>, the search uses the OR operator in connecting 2247 query criteria; otherwise it uses the AND operator. 2248 * @param version the web content article's version (optionally 2249 <code>null</code>) 2250 * @param type the web content article's type (optionally 2251 <code>null</code>) 2252 * @param ddmStructureKey the primary key of the web content article's DDM 2253 structure, if the article is related to a DDM structure, or 2254 <code>null</code> otherwise 2255 * @param ddmTemplateKey the primary key of the web content article's DDM 2256 template (optionally <code>null</code>). If the article is 2257 related to a DDM structure, the template's structure must match 2258 it. 2259 * @param displayDateGT the date after which a matching web content 2260 article's display date must be after (optionally 2261 <code>null</code>) 2262 * @param displayDateLT the date before which a matching web content 2263 article's display date must be before (optionally 2264 <code>null</code>) 2265 * @param status the web content article's workflow status. For more 2266 information see {@link WorkflowConstants} for constants starting 2267 with the "STATUS_" prefix. 2268 * @param reviewDate the web content article's scheduled review date 2269 (optionally <code>null</code>) 2270 * @param start the lower bound of the range of web content articles to 2271 return 2272 * @param end the upper bound of the range of web content articles to 2273 return (not inclusive) 2274 * @param obc the comparator to order the web content articles 2275 * @return the range of matching web content articles ordered by the 2276 comparator 2277 * @throws SystemException if a system exception occurred 2278 */ 2279 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2280 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> search( 2281 long companyId, long groupId, java.util.List<java.lang.Long> folderIds, 2282 long classNameId, java.lang.String keywords, java.lang.Double version, 2283 java.lang.String type, java.lang.String ddmStructureKey, 2284 java.lang.String ddmTemplateKey, java.util.Date displayDateGT, 2285 java.util.Date displayDateLT, int status, java.util.Date reviewDate, 2286 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc) 2287 throws com.liferay.portal.kernel.exception.SystemException; 2288 2289 /** 2290 * Returns an ordered range of all the web content articles matching the 2291 * parameters without using the indexer, including keyword parameters for 2292 * article ID, title, description, and content, a DDM structure key 2293 * parameter, a DDM template key parameter, and an AND operator switch. It 2294 * is preferable to use the indexed version {@link #search(long, long, List, 2295 * long, String, String, String, String, String, String, String, String, 2296 * LinkedHashMap, boolean, int, int, Sort)} instead of this method wherever 2297 * possible for performance reasons. 2298 * 2299 * <p> 2300 * Useful when paginating results. Returns a maximum of <code>end - 2301 * start</code> instances. <code>start</code> and <code>end</code> are not 2302 * primary keys, they are indexes in the result set. Thus, <code>0</code> 2303 * refers to the first result in the set. Setting both <code>start</code> 2304 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 2305 * result set. 2306 * </p> 2307 * 2308 * @param companyId the primary key of the web content article's company 2309 * @param groupId the primary key of the group (optionally <code>0</code>) 2310 * @param folderIds the primary keys of the web content article folders 2311 (optionally {@link java.util.Collections#EMPTY_LIST}) 2312 * @param classNameId the primary key of the DDMStructure class if the web 2313 content article is related to a DDM structure, the primary key of 2314 the class name associated with the article, or {@link 2315 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2316 * @param articleId the article ID keywords (space separated, optionally 2317 <code>null</code>) 2318 * @param version the web content article's version (optionally 2319 <code>null</code>) 2320 * @param title the title keywords (space separated, optionally 2321 <code>null</code>) 2322 * @param description the description keywords (space separated, optionally 2323 <code>null</code>) 2324 * @param content the content keywords (space separated, optionally 2325 <code>null</code>) 2326 * @param type the web content article's type (optionally 2327 <code>null</code>) 2328 * @param ddmStructureKey the primary key of the web content article's DDM 2329 structure, if the article is related to a DDM structure, or 2330 <code>null</code> otherwise 2331 * @param ddmTemplateKey the primary key of the web content article's DDM 2332 template (optionally <code>null</code>). If the article is 2333 related to a DDM structure, the template's structure must match 2334 it. 2335 * @param displayDateGT the date after which a matching web content 2336 article's display date must be after (optionally 2337 <code>null</code>) 2338 * @param displayDateLT the date before which a matching web content 2339 article's display date must be before (optionally 2340 <code>null</code>) 2341 * @param status the web content article's workflow status. For more 2342 information see {@link WorkflowConstants} for constants starting 2343 with the "STATUS_" prefix. 2344 * @param reviewDate the web content article's scheduled review date 2345 (optionally <code>null</code>) 2346 * @param andOperator whether every field must match its value or keywords, 2347 or just one field must match. Company, group, folder IDs, class 2348 name ID, and status must all match their values. 2349 * @param start the lower bound of the range of web content articles to 2350 return 2351 * @param end the upper bound of the range of web content articles to 2352 return (not inclusive) 2353 * @param obc the comparator to order the web content articles 2354 * @return the range of matching web content articles ordered by the 2355 comparator 2356 * @throws SystemException if a system exception occurred 2357 */ 2358 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2359 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> search( 2360 long companyId, long groupId, java.util.List<java.lang.Long> folderIds, 2361 long classNameId, java.lang.String articleId, java.lang.Double version, 2362 java.lang.String title, java.lang.String description, 2363 java.lang.String content, java.lang.String type, 2364 java.lang.String ddmStructureKey, java.lang.String ddmTemplateKey, 2365 java.util.Date displayDateGT, java.util.Date displayDateLT, int status, 2366 java.util.Date reviewDate, boolean andOperator, int start, int end, 2367 com.liferay.portal.kernel.util.OrderByComparator obc) 2368 throws com.liferay.portal.kernel.exception.SystemException; 2369 2370 /** 2371 * Returns an ordered range of all the web content articles matching the 2372 * parameters without using the indexer, including keyword parameters for 2373 * article ID, title, description, and content, a DDM structure keys 2374 * (plural) parameter, a DDM template keys (plural) parameter, and an AND 2375 * operator switch. 2376 * 2377 * <p> 2378 * Useful when paginating results. Returns a maximum of <code>end - 2379 * start</code> instances. <code>start</code> and <code>end</code> are not 2380 * primary keys, they are indexes in the result set. Thus, <code>0</code> 2381 * refers to the first result in the set. Setting both <code>start</code> 2382 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 2383 * result set. 2384 * </p> 2385 * 2386 * @param companyId the primary key of the web content article's company 2387 * @param groupId the primary key of the group (optionally <code>0</code>) 2388 * @param folderIds the primary keys of the web content article folders 2389 (optionally {@link java.util.Collections#EMPTY_LIST}) 2390 * @param classNameId the primary key of the DDMStructure class if the web 2391 content article is related to a DDM structure, the primary key of 2392 the class name associated with the article, or {@link 2393 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2394 * @param articleId the article ID keywords (space separated, optionally 2395 <code>null</code>) 2396 * @param version the web content article's version (optionally 2397 <code>null</code>) 2398 * @param title the title keywords (space separated, optionally 2399 <code>null</code>) 2400 * @param description the description keywords (space separated, optionally 2401 <code>null</code>) 2402 * @param content the content keywords (space separated, optionally 2403 <code>null</code>) 2404 * @param type the web content article's type (optionally 2405 <code>null</code>) 2406 * @param ddmStructureKeys the primary keys of the web content article's 2407 DDM structures, if the article is related to a DDM structure, or 2408 <code>null</code> otherwise 2409 * @param ddmTemplateKeys the primary keys of the web content article's DDM 2410 templates (originally <code>null</code>). If the articles are 2411 related to a DDM structure, the template's structure must match 2412 it. 2413 * @param displayDateGT the date after which a matching web content 2414 article's display date must be after (optionally 2415 <code>null</code>) 2416 * @param displayDateLT the date before which a matching web content 2417 article's display date must be before (optionally 2418 <code>null</code>) 2419 * @param status the web content article's workflow status. For more 2420 information see {@link WorkflowConstants} for constants starting 2421 with the "STATUS_" prefix. 2422 * @param reviewDate the web content article's scheduled review date 2423 (optionally <code>null</code>) 2424 * @param andOperator whether every field must match its value or keywords, 2425 or just one field must match. Company, group, folder IDs, class 2426 name ID, and status must all match their values. 2427 * @param start the lower bound of the range of web content articles to 2428 return 2429 * @param end the upper bound of the range of web content articles to 2430 return (not inclusive) 2431 * @param obc the comparator to order the web content articles 2432 * @return the range of matching web content articles ordered by the 2433 comparator 2434 * @throws SystemException if a system exception occurred 2435 */ 2436 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2437 public java.util.List<com.liferay.portlet.journal.model.JournalArticle> search( 2438 long companyId, long groupId, java.util.List<java.lang.Long> folderIds, 2439 long classNameId, java.lang.String articleId, java.lang.Double version, 2440 java.lang.String title, java.lang.String description, 2441 java.lang.String content, java.lang.String type, 2442 java.lang.String[] ddmStructureKeys, 2443 java.lang.String[] ddmTemplateKeys, java.util.Date displayDateGT, 2444 java.util.Date displayDateLT, int status, java.util.Date reviewDate, 2445 boolean andOperator, int start, int end, 2446 com.liferay.portal.kernel.util.OrderByComparator obc) 2447 throws com.liferay.portal.kernel.exception.SystemException; 2448 2449 /** 2450 * Returns an ordered range of all the web content articles matching the 2451 * parameters using the indexer, including a keywords parameter for matching 2452 * an article's ID, title, description, or content, a DDM structure key 2453 * parameter, a DDM template key parameter, and a finder hash map parameter. 2454 * It is preferable to use this method instead of the non-indexed version 2455 * whenever possible for performance reasons. 2456 * 2457 * <p> 2458 * Useful when paginating results. Returns a maximum of <code>end - 2459 * start</code> instances. <code>start</code> and <code>end</code> are not 2460 * primary keys, they are indexes in the result set. Thus, <code>0</code> 2461 * refers to the first result in the set. Setting both <code>start</code> 2462 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 2463 * result set. 2464 * </p> 2465 * 2466 * @param companyId the primary key of the web content article's company 2467 * @param groupId the primary key of the group (optionally <code>0</code>) 2468 * @param folderIds the primary keys of the web content article folders 2469 (optionally {@link java.util.Collections#EMPTY_LIST}) 2470 * @param classNameId the primary key of the DDMStructure class if the web 2471 content article is related to a DDM structure, the primary key of 2472 the class name associated with the article, or {@link 2473 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2474 * @param ddmStructureKey the primary key of the web content article's DDM 2475 structure, if the article is related to a DDM structure, or 2476 <code>null</code> otherwise 2477 * @param ddmTemplateKey the primary key of the web content article's DDM 2478 template (optionally <code>null</code>). If the article is 2479 related to a DDM structure, the template's structure must match 2480 it. 2481 * @param keywords the keywords (space separated), which may occur in the 2482 web content article ID, title, description, or content 2483 (optionally <code>null</code>). If the keywords value is not 2484 <code>null</code>, the search uses the OR operator in connecting 2485 query criteria; otherwise it uses the AND operator. 2486 * @param params the finder parameters (optionally <code>null</code>) 2487 * @param start the lower bound of the range of web content articles to 2488 return 2489 * @param end the upper bound of the range of web content articles to 2490 return (not inclusive) 2491 * @param sort the field, type, and direction by which to sort (optionally 2492 <code>null</code>) 2493 * @return the matching web content articles ordered by <code>sort</code> 2494 * @throws SystemException if a system exception occurred 2495 */ 2496 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2497 public com.liferay.portal.kernel.search.Hits search(long companyId, 2498 long groupId, java.util.List<java.lang.Long> folderIds, 2499 long classNameId, java.lang.String ddmStructureKey, 2500 java.lang.String ddmTemplateKey, java.lang.String keywords, 2501 java.util.LinkedHashMap<java.lang.String, java.lang.Object> params, 2502 int start, int end, com.liferay.portal.kernel.search.Sort sort) 2503 throws com.liferay.portal.kernel.exception.SystemException; 2504 2505 /** 2506 * Returns an ordered range of all the web content articles matching the 2507 * parameters using the indexer, including a keywords parameter for matching 2508 * an article's ID, title, description, or content, a DDM structure key 2509 * parameter, a DDM template key parameter, an AND operator switch, and 2510 * parameters for type, status, a finder hash map. It is preferable to use 2511 * this method instead of the non-indexed version whenever possible for 2512 * performance reasons. 2513 * 2514 * <p> 2515 * Useful when paginating results. Returns a maximum of <code>end - 2516 * start</code> instances. <code>start</code> and <code>end</code> are not 2517 * primary keys, they are indexes in the result set. Thus, <code>0</code> 2518 * refers to the first result in the set. Setting both <code>start</code> 2519 * and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full 2520 * result set. 2521 * </p> 2522 * 2523 * @param companyId the primary key of the web content article's company 2524 * @param groupId the primary key of the group (optionally <code>0</code>) 2525 * @param folderIds the primary keys of the web content article folders 2526 (optionally {@link java.util.Collections#EMPTY_LIST}) 2527 * @param classNameId the primary key of the DDMStructure class if the web 2528 content article is related to a DDM structure, the primary key of 2529 the class name associated with the article, or {@link 2530 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2531 * @param articleId the article ID keywords (space separated, optionally 2532 <code>null</code>) 2533 * @param title the title keywords (space separated, optionally 2534 <code>null</code>) 2535 * @param description the description keywords (space separated, optionally 2536 <code>null</code>) 2537 * @param content the content keywords (space separated, optionally 2538 <code>null</code>) 2539 * @param type the web content article's type (optionally 2540 <code>null</code>) 2541 * @param status the web content article's workflow status. For more 2542 information see {@link WorkflowConstants} for constants starting 2543 with the "STATUS_" prefix. 2544 * @param ddmStructureKey the primary key of the web content article's DDM 2545 structure, if the article is related to a DDM structure, or 2546 <code>null</code> otherwise 2547 * @param ddmTemplateKey the primary key of the web content article's DDM 2548 template (optionally <code>null</code>). If the article is 2549 related to a DDM structure, the template's structure must match 2550 it. 2551 * @param params the finder parameters (optionally <code>null</code>). Can 2552 set parameter <code>"includeDiscussions"</code> to 2553 <code>true</code> to search for the keywords in the web content 2554 article discussions. 2555 * @param andSearch whether every field must match its value or keywords, 2556 or just one field must match 2557 * @param start the lower bound of the range of web content articles to 2558 return 2559 * @param end the upper bound of the range of web content articles to 2560 return (not inclusive) 2561 * @param sort the field, type, and direction by which to sort (optionally 2562 <code>null</code>) 2563 * @return the matching web content articles ordered by <code>sort</code> 2564 * @throws SystemException if a system exception occurred 2565 */ 2566 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2567 public com.liferay.portal.kernel.search.Hits search(long companyId, 2568 long groupId, java.util.List<java.lang.Long> folderIds, 2569 long classNameId, java.lang.String articleId, java.lang.String title, 2570 java.lang.String description, java.lang.String content, 2571 java.lang.String type, java.lang.String status, 2572 java.lang.String ddmStructureKey, java.lang.String ddmTemplateKey, 2573 java.util.LinkedHashMap<java.lang.String, java.lang.Object> params, 2574 boolean andSearch, int start, int end, 2575 com.liferay.portal.kernel.search.Sort sort) 2576 throws com.liferay.portal.kernel.exception.SystemException; 2577 2578 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2579 public com.liferay.portal.kernel.search.Hits search(long groupId, 2580 long userId, long creatorUserId, int status, int start, int end) 2581 throws com.liferay.portal.kernel.exception.PortalException, 2582 com.liferay.portal.kernel.exception.SystemException; 2583 2584 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2585 public int searchCount(long groupId, 2586 java.util.List<java.lang.Long> folderIds, int status) 2587 throws com.liferay.portal.kernel.exception.SystemException; 2588 2589 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2590 public int searchCount(long groupId, long folderId, int status) 2591 throws com.liferay.portal.kernel.exception.SystemException; 2592 2593 /** 2594 * Returns the number of web content articles matching the parameters, 2595 * including a keywords parameter for matching with the article's ID, title, 2596 * description, and content, a DDM structure key parameter, and a DDM 2597 * template key parameter. 2598 * 2599 * @param companyId the primary key of the web content article's company 2600 * @param groupId the primary key of the group (optionally <code>0</code>) 2601 * @param folderIds the primary keys of the web content article folders 2602 (optionally {@link java.util.Collections#EMPTY_LIST}) 2603 * @param classNameId the primary key of the DDMStructure class if the web 2604 content article is related to a DDM structure, the primary key of 2605 the class name associated with the article, or {@link 2606 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2607 * @param keywords the keywords (space separated), which may occur in the 2608 web content article ID, title, description, or content 2609 (optionally <code>null</code>). If the keywords value is not 2610 <code>null</code>, the search uses the OR operator in connecting 2611 query criteria; otherwise it uses the AND operator. 2612 * @param version the web content article's version (optionally 2613 <code>null</code>) 2614 * @param type the web content article's type (optionally 2615 <code>null</code>) 2616 * @param ddmStructureKey the primary key of the web content article's DDM 2617 structure, if the article is related to a DDM structure, or 2618 <code>null</code> otherwise 2619 * @param ddmTemplateKey the primary key of the web content article's DDM 2620 template (optionally <code>null</code>). If the article is 2621 related to a DDM structure, the template's structure must match 2622 it. 2623 * @param displayDateGT the date after which a matching web content 2624 article's display date must be after (optionally 2625 <code>null</code>) 2626 * @param displayDateLT the date before which a matching web content 2627 article's display date must be before (optionally 2628 <code>null</code>) 2629 * @param status the web content article's workflow status. For more 2630 information see {@link WorkflowConstants} for constants starting 2631 with the "STATUS_" prefix. 2632 * @param reviewDate the web content article's scheduled review date 2633 (optionally <code>null</code>) 2634 * @return the number of matching web content articles 2635 * @throws SystemException if a system exception occurred 2636 */ 2637 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2638 public int searchCount(long companyId, long groupId, 2639 java.util.List<java.lang.Long> folderIds, long classNameId, 2640 java.lang.String keywords, java.lang.Double version, 2641 java.lang.String type, java.lang.String ddmStructureKey, 2642 java.lang.String ddmTemplateKey, java.util.Date displayDateGT, 2643 java.util.Date displayDateLT, int status, java.util.Date reviewDate) 2644 throws com.liferay.portal.kernel.exception.SystemException; 2645 2646 /** 2647 * Returns the number of web content articles matching the parameters, 2648 * including keyword parameters for article ID, title, description, and 2649 * content, a DDM structure key parameter, a DDM template key parameter, and 2650 * an AND operator switch. 2651 * 2652 * @param companyId the primary key of the web content article's company 2653 * @param groupId the primary key of the group (optionally <code>0</code>) 2654 * @param folderIds the primary keys of the web content article folders 2655 (optionally {@link java.util.Collections#EMPTY_LIST}) 2656 * @param classNameId the primary key of the DDMStructure class if the web 2657 content article is related to a DDM structure, the primary key of 2658 the class name associated with the article, or {@link 2659 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2660 * @param articleId the article ID keywords (space separated, optionally 2661 <code>null</code>) 2662 * @param version the web content article's version (optionally 2663 <code>null</code>) 2664 * @param title the title keywords (space separated, optionally 2665 <code>null</code>) 2666 * @param description the description keywords (space separated, optionally 2667 <code>null</code>) 2668 * @param content the content keywords (space separated, optionally 2669 <code>null</code>) 2670 * @param type the web content article's type (optionally 2671 <code>null</code>) 2672 * @param ddmStructureKey the primary key of the web content article's DDM 2673 structure, if the article is related to a DDM structure, or 2674 <code>null</code> otherwise 2675 * @param ddmTemplateKey the primary key of the web content article's DDM 2676 template (optionally <code>null</code>). If the article is 2677 related to a DDM structure, the template's structure must match 2678 it. 2679 * @param displayDateGT the date after which a matching web content 2680 article's display date must be after (optionally 2681 <code>null</code>) 2682 * @param displayDateLT the date before which a matching web content 2683 article's display date must be before (optionally 2684 <code>null</code>) 2685 * @param status the web content article's workflow status. For more 2686 information see {@link WorkflowConstants} for constants starting 2687 with the "STATUS_" prefix. 2688 * @param reviewDate the web content article's scheduled review date 2689 (optionally <code>null</code>) 2690 * @param andOperator whether every field must match its value or keywords, 2691 or just one field must match. Group, folder IDs, class name ID, 2692 and status must all match their values. 2693 * @return the number of matching web content articles 2694 * @throws SystemException if a system exception occurred 2695 */ 2696 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2697 public int searchCount(long companyId, long groupId, 2698 java.util.List<java.lang.Long> folderIds, long classNameId, 2699 java.lang.String articleId, java.lang.Double version, 2700 java.lang.String title, java.lang.String description, 2701 java.lang.String content, java.lang.String type, 2702 java.lang.String ddmStructureKey, java.lang.String ddmTemplateKey, 2703 java.util.Date displayDateGT, java.util.Date displayDateLT, int status, 2704 java.util.Date reviewDate, boolean andOperator) 2705 throws com.liferay.portal.kernel.exception.SystemException; 2706 2707 /** 2708 * Returns the number of web content articles matching the parameters, 2709 * including keyword parameters for article ID, title, description, and 2710 * content, a DDM structure keys (plural) parameter, a DDM template keys 2711 * (plural) parameter, and an AND operator switch. 2712 * 2713 * @param companyId the primary key of the web content article's company 2714 * @param groupId the primary key of the group (optionally <code>0</code>) 2715 * @param folderIds the primary keys of the web content article folders 2716 (optionally {@link java.util.Collections#EMPTY_LIST}) 2717 * @param classNameId the primary key of the DDMStructure class if the web 2718 content article is related to a DDM structure, the primary key of 2719 the class name associated with the article, or {@link 2720 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 2721 * @param articleId the article ID keywords (space separated, optionally 2722 <code>null</code>) 2723 * @param version the web content article's version (optionally 2724 <code>null</code>) 2725 * @param title the title keywords (space separated, optionally 2726 <code>null</code>) 2727 * @param description the description keywords (space separated, optionally 2728 <code>null</code>) 2729 * @param content the content keywords (space separated, optionally 2730 <code>null</code>) 2731 * @param type the web content article's type (optionally 2732 <code>null</code>) 2733 * @param ddmStructureKeys the primary keys of the web content article's 2734 DDM structures, if the article is related to a DDM structure, or 2735 <code>null</code> otherwise 2736 * @param ddmTemplateKeys the primary keys of the web content article's DDM 2737 templates (originally <code>null</code>). If the articles are 2738 related to a DDM structure, the template's structure must match 2739 it. 2740 * @param displayDateGT the date after which a matching web content 2741 article's display date must be after (optionally 2742 <code>null</code>) 2743 * @param displayDateLT the date before which a matching web content 2744 article's display date must be before (optionally 2745 <code>null</code>) 2746 * @param status the web content article's workflow status. For more 2747 information see {@link WorkflowConstants} for constants starting 2748 with the "STATUS_" prefix. 2749 * @param reviewDate the web content article's scheduled review date 2750 (optionally <code>null</code>) 2751 * @param andOperator whether every field must match its value or keywords, 2752 or just one field must match. Group, folder IDs, class name ID, 2753 and status must all match their values. 2754 * @return the number of matching web content articles 2755 * @throws SystemException if a system exception occurred 2756 */ 2757 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 2758 public int searchCount(long companyId, long groupId, 2759 java.util.List<java.lang.Long> folderIds, long classNameId, 2760 java.lang.String articleId, java.lang.Double version, 2761 java.lang.String title, java.lang.String description, 2762 java.lang.String content, java.lang.String type, 2763 java.lang.String[] ddmStructureKeys, 2764 java.lang.String[] ddmTemplateKeys, java.util.Date displayDateGT, 2765 java.util.Date displayDateLT, int status, java.util.Date reviewDate, 2766 boolean andOperator) 2767 throws com.liferay.portal.kernel.exception.SystemException; 2768 2769 public void setTreePaths(long folderId, java.lang.String treePath, 2770 boolean reindex) 2771 throws com.liferay.portal.kernel.exception.PortalException, 2772 com.liferay.portal.kernel.exception.SystemException; 2773 2774 /** 2775 * Subscribes the user to notifications for the web content article matching 2776 * the group, notifying him the instant versions of the article are created, 2777 * deleted, or modified. 2778 * 2779 * @param userId the primary key of the user to subscribe 2780 * @param groupId the primary key of the group 2781 * @throws PortalException if a matching user or group could not be found 2782 * @throws SystemException if a system exception occurred 2783 */ 2784 public void subscribe(long userId, long groupId) 2785 throws com.liferay.portal.kernel.exception.PortalException, 2786 com.liferay.portal.kernel.exception.SystemException; 2787 2788 /** 2789 * Unsubscribes the user from notifications for the web content article 2790 * matching the group. 2791 * 2792 * @param userId the primary key of the user to unsubscribe 2793 * @param groupId the primary key of the group 2794 * @throws PortalException if a matching user or subscription could not be 2795 found 2796 * @throws SystemException if a system exception occurred 2797 */ 2798 public void unsubscribe(long userId, long groupId) 2799 throws com.liferay.portal.kernel.exception.PortalException, 2800 com.liferay.portal.kernel.exception.SystemException; 2801 2802 /** 2803 * Updates the web content article matching the version, replacing its 2804 * folder, title, description, content, and layout UUID. 2805 * 2806 * @param userId the primary key of the user updating the web content 2807 article 2808 * @param groupId the primary key of the web content article's group 2809 * @param folderId the primary key of the web content article folder 2810 * @param articleId the primary key of the web content article 2811 * @param version the web content article's version 2812 * @param titleMap the web content article's locales and localized titles 2813 * @param descriptionMap the web content article's locales and localized 2814 descriptions 2815 * @param content the HTML content wrapped in XML. For more information, 2816 see the content example in the class description for {@link 2817 JournalArticleLocalServiceImpl}. 2818 * @param layoutUuid the unique string identifying the web content 2819 article's display page 2820 * @param serviceContext the service context to be applied. Can set the 2821 modification date, expando bridge attributes, asset category IDs, 2822 asset tag names, asset link entry IDs, workflow actions, the 2823 "defaultLanguageId" and "urlTitle" attributes, and can set 2824 whether to add the default command update for the web content 2825 article. With respect to social activities, by setting the 2826 service context's command to {@link 2827 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 2828 is considered a web content update activity; otherwise it is 2829 considered a web content add activity. 2830 * @return the updated web content article 2831 * @throws PortalException if a user with the primary key or a matching web 2832 content article could not be found, or if a portal exception 2833 occurred 2834 * @throws SystemException if a system exception occurred 2835 */ 2836 public com.liferay.portlet.journal.model.JournalArticle updateArticle( 2837 long userId, long groupId, long folderId, java.lang.String articleId, 2838 double version, 2839 java.util.Map<java.util.Locale, java.lang.String> titleMap, 2840 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 2841 java.lang.String content, java.lang.String layoutUuid, 2842 com.liferay.portal.service.ServiceContext serviceContext) 2843 throws com.liferay.portal.kernel.exception.PortalException, 2844 com.liferay.portal.kernel.exception.SystemException; 2845 2846 /** 2847 * Updates the web content article with additional parameters. 2848 * 2849 * @param userId the primary key of the user updating the web content 2850 article 2851 * @param groupId the primary key of the web content article's group 2852 * @param folderId the primary key of the web content article folder 2853 * @param articleId the primary key of the web content article 2854 * @param version the web content article's version 2855 * @param titleMap the web content article's locales and localized titles 2856 * @param descriptionMap the web content article's locales and localized 2857 descriptions 2858 * @param content the HTML content wrapped in XML. For more information, 2859 see the content example in the class description for {@link 2860 JournalArticleLocalServiceImpl}. 2861 * @param type the structure's type, if the web content article is related 2862 to a DDM structure. For more information, see {@link 2863 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 2864 * @param ddmStructureKey the primary key of the web content article's DDM 2865 structure, if the article is related to a DDM structure, or 2866 <code>null</code> otherwise 2867 * @param ddmTemplateKey the primary key of the web content article's DDM 2868 template (optionally <code>null</code>). If the article is 2869 related to a DDM structure, the template's structure must match 2870 it. 2871 * @param layoutUuid the unique string identifying the web content 2872 article's display page 2873 * @param displayDateMonth the month the web content article is set to 2874 display 2875 * @param displayDateDay the calendar day the web content article is set to 2876 display 2877 * @param displayDateYear the year the web content article is set to 2878 display 2879 * @param displayDateHour the hour the web content article is set to 2880 display 2881 * @param displayDateMinute the minute the web content article is set to 2882 display 2883 * @param expirationDateMonth the month the web content article is set to 2884 expire 2885 * @param expirationDateDay the calendar day the web content article is set 2886 to expire 2887 * @param expirationDateYear the year the web content article is set to 2888 expire 2889 * @param expirationDateHour the hour the web content article is set to 2890 expire 2891 * @param expirationDateMinute the minute the web content article is set to 2892 expire 2893 * @param neverExpire whether the web content article is not set to auto 2894 expire 2895 * @param reviewDateMonth the month the web content article is set for 2896 review 2897 * @param reviewDateDay the calendar day the web content article is set for 2898 review 2899 * @param reviewDateYear the year the web content article is set for review 2900 * @param reviewDateHour the hour the web content article is set for review 2901 * @param reviewDateMinute the minute the web content article is set for 2902 review 2903 * @param neverReview whether the web content article is not set for review 2904 * @param indexable whether the web content is searchable 2905 * @param smallImage whether to update web content article's a small image. 2906 A file must be passed in as <code>smallImageFile</code> value, 2907 otherwise the current small image is deleted. 2908 * @param smallImageURL the web content article's small image URL 2909 (optionally <code>null</code>) 2910 * @param smallImageFile the web content article's new small image file 2911 (optionally <code>null</code>). Must pass in 2912 <code>smallImage</code> value of <code>true</code> to replace the 2913 article's small image file. 2914 * @param images the web content's images (optionally <code>null</code>) 2915 * @param articleURL the web content article's accessible URL (optionally 2916 <code>null</code>) 2917 * @param serviceContext the service context to be applied. Can set the 2918 modification date, expando bridge attributes, asset category IDs, 2919 asset tag names, asset link entry IDs, workflow actions, the 2920 "defaultLanguageId" and "urlTitle" attributes, and can set 2921 whether to add the default command update for the web content 2922 article. With respect to social activities, by setting the 2923 service context's command to {@link 2924 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 2925 is considered a web content update activity; otherwise it is 2926 considered a web content add activity. 2927 * @return the updated web content article 2928 * @throws PortalException if a user with the primary key or a matching web 2929 content article could not be found, or if a portal exception 2930 occurred 2931 * @throws SystemException if a system exception occurred 2932 */ 2933 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 2934 public com.liferay.portlet.journal.model.JournalArticle updateArticle( 2935 long userId, long groupId, long folderId, java.lang.String articleId, 2936 double version, 2937 java.util.Map<java.util.Locale, java.lang.String> titleMap, 2938 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 2939 java.lang.String content, java.lang.String type, 2940 java.lang.String ddmStructureKey, java.lang.String ddmTemplateKey, 2941 java.lang.String layoutUuid, int displayDateMonth, int displayDateDay, 2942 int displayDateYear, int displayDateHour, int displayDateMinute, 2943 int expirationDateMonth, int expirationDateDay, int expirationDateYear, 2944 int expirationDateHour, int expirationDateMinute, boolean neverExpire, 2945 int reviewDateMonth, int reviewDateDay, int reviewDateYear, 2946 int reviewDateHour, int reviewDateMinute, boolean neverReview, 2947 boolean indexable, boolean smallImage, java.lang.String smallImageURL, 2948 java.io.File smallImageFile, 2949 java.util.Map<java.lang.String, byte[]> images, 2950 java.lang.String articleURL, 2951 com.liferay.portal.service.ServiceContext serviceContext) 2952 throws com.liferay.portal.kernel.exception.PortalException, 2953 com.liferay.portal.kernel.exception.SystemException; 2954 2955 /** 2956 * Updates the web content article matching the version, replacing its 2957 * folder and content. 2958 * 2959 * @param userId the primary key of the user updating the web content 2960 article 2961 * @param groupId the primary key of the web content article's group 2962 * @param folderId the primary key of the web content article folder 2963 * @param articleId the primary key of the web content article 2964 * @param version the web content article's version 2965 * @param content the HTML content wrapped in XML. For more information, 2966 see the content example in the class description for {@link 2967 JournalArticleLocalServiceImpl}. 2968 * @param serviceContext the service context to be applied. Can set the 2969 modification date, expando bridge attributes, asset category IDs, 2970 asset tag names, asset link entry IDs, workflow actions, the 2971 "defaultLanguageId" and "urlTitle" attributes, and can set 2972 whether to add the default command update for the web content 2973 article. With respect to social activities, by setting the 2974 service context's command to {@link 2975 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 2976 is considered a web content update activity; otherwise it is 2977 considered a web content add activity. 2978 * @return the updated web content article 2979 * @throws PortalException if a user with the primary key or a matching web 2980 content article could not be found, or if a portal exception 2981 occurred 2982 * @throws SystemException if a system exception occurred 2983 */ 2984 public com.liferay.portlet.journal.model.JournalArticle updateArticle( 2985 long userId, long groupId, long folderId, java.lang.String articleId, 2986 double version, java.lang.String content, 2987 com.liferay.portal.service.ServiceContext serviceContext) 2988 throws com.liferay.portal.kernel.exception.PortalException, 2989 com.liferay.portal.kernel.exception.SystemException; 2990 2991 /** 2992 * @deprecated As of 6.2.0, replaced by {@link 2993 #updateArticleTranslation(long, String, double, Locale, 2994 String, String, String, Map, ServiceContext)} 2995 */ 2996 public com.liferay.portlet.journal.model.JournalArticle updateArticleTranslation( 2997 long groupId, java.lang.String articleId, double version, 2998 java.util.Locale locale, java.lang.String title, 2999 java.lang.String description, java.lang.String content, 3000 java.util.Map<java.lang.String, byte[]> images) 3001 throws com.liferay.portal.kernel.exception.PortalException, 3002 com.liferay.portal.kernel.exception.SystemException; 3003 3004 /** 3005 * Updates the translation of the web content article. 3006 * 3007 * @param groupId the primary key of the web content article's group 3008 * @param articleId the primary key of the web content article 3009 * @param version the web content article's version 3010 * @param locale the locale of the web content article's display template 3011 * @param title the translated web content article title 3012 * @param description the translated web content article description 3013 * @param content the HTML content wrapped in XML. For more information, 3014 see the content example in the class description for {@link 3015 JournalArticleLocalServiceImpl}. 3016 * @param images the web content's images 3017 * @param serviceContext the service context to be applied. Can set the 3018 modification date and "urlTitle" attribute for the web content 3019 article. 3020 * @return the updated web content article 3021 * @throws PortalException if a user with the primary key or a matching web 3022 content article could not be found, or if a portal exception 3023 occurred 3024 * @throws SystemException if a system exception occurred 3025 */ 3026 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 3027 public com.liferay.portlet.journal.model.JournalArticle updateArticleTranslation( 3028 long groupId, java.lang.String articleId, double version, 3029 java.util.Locale locale, java.lang.String title, 3030 java.lang.String description, java.lang.String content, 3031 java.util.Map<java.lang.String, byte[]> images, 3032 com.liferay.portal.service.ServiceContext serviceContext) 3033 throws com.liferay.portal.kernel.exception.PortalException, 3034 com.liferay.portal.kernel.exception.SystemException; 3035 3036 /** 3037 * Updates the web content article's asset with the new asset categories, 3038 * tag names, and link entries, removing and adding them as necessary. 3039 * 3040 * @param userId the primary key of the user updating the web content 3041 article's asset 3042 * @param article the web content article 3043 * @param assetCategoryIds the primary keys of the new asset categories 3044 * @param assetTagNames the new asset tag names 3045 * @param assetLinkEntryIds the primary keys of the new asset link entries 3046 * @throws PortalException if a portal exception occurred 3047 * @throws SystemException if a system exception occurred 3048 */ 3049 public void updateAsset(long userId, 3050 com.liferay.portlet.journal.model.JournalArticle article, 3051 long[] assetCategoryIds, java.lang.String[] assetTagNames, 3052 long[] assetLinkEntryIds) 3053 throws com.liferay.portal.kernel.exception.PortalException, 3054 com.liferay.portal.kernel.exception.SystemException; 3055 3056 /** 3057 * Updates the web content article matching the group, article ID, and 3058 * version, replacing its content. 3059 * 3060 * @param groupId the primary key of the web content article's group 3061 * @param articleId the primary key of the web content article 3062 * @param version the web content article's version 3063 * @param content the HTML content wrapped in XML. For more information, 3064 see the content example in the class description for {@link 3065 JournalArticleLocalServiceImpl}. 3066 * @return the updated web content article 3067 * @throws PortalException if a matching web content article could not be 3068 found 3069 * @throws SystemException if a system exception occurred 3070 */ 3071 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 3072 public com.liferay.portlet.journal.model.JournalArticle updateContent( 3073 long groupId, java.lang.String articleId, double version, 3074 java.lang.String content) 3075 throws com.liferay.portal.kernel.exception.PortalException, 3076 com.liferay.portal.kernel.exception.SystemException; 3077 3078 /** 3079 * Updates the workflow status of the web content article. 3080 * 3081 * @param userId the primary key of the user updating the web content 3082 article's status 3083 * @param article the web content article 3084 * @param status the web content article's workflow status. For more 3085 information see {@link WorkflowConstants} for constants starting 3086 with the "STATUS_" prefix. 3087 * @param articleURL the web content article's accessible URL 3088 * @param workflowContext the web content article's configured workflow 3089 context 3090 * @param serviceContext the service context to be applied. Can set the 3091 modification date, status date, and portlet preferences. With 3092 respect to social activities, by setting the service context's 3093 command to {@link 3094 com.liferay.portal.kernel.util.Constants#UPDATE}, the invocation 3095 is considered a web content update activity; otherwise it is 3096 considered a web content add activity. 3097 * @return the updated web content article 3098 * @throws PortalException if a portal exception occurred 3099 * @throws SystemException if a system exception occurred 3100 */ 3101 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 3102 public com.liferay.portlet.journal.model.JournalArticle updateStatus( 3103 long userId, com.liferay.portlet.journal.model.JournalArticle article, 3104 int status, java.lang.String articleURL, 3105 java.util.Map<java.lang.String, java.io.Serializable> workflowContext, 3106 com.liferay.portal.service.ServiceContext serviceContext) 3107 throws com.liferay.portal.kernel.exception.PortalException, 3108 com.liferay.portal.kernel.exception.SystemException; 3109 3110 /** 3111 * Updates the workflow status of the web content article matching the class 3112 * PK. 3113 * 3114 * @param userId the primary key of the user updating the web content 3115 article's status 3116 * @param classPK the primary key of the DDM structure, if the web content 3117 article is related to a DDM structure, the primary key of the 3118 class associated with the article, or <code>0</code> otherwise 3119 * @param status the web content article's workflow status. For more 3120 information see {@link WorkflowConstants} for constants starting 3121 with the "STATUS_" prefix. 3122 * @param workflowContext the web content article's configured workflow 3123 * @param serviceContext the service context to be applied. Can set the 3124 modification date, portlet preferences, and can set whether to 3125 add the default command update for the web content article. 3126 * @return the updated web content article 3127 * @throws PortalException if a matching web content article could not be 3128 found or if a portal exception occurred 3129 * @throws SystemException if a system exception occurred 3130 */ 3131 public com.liferay.portlet.journal.model.JournalArticle updateStatus( 3132 long userId, long classPK, int status, 3133 java.util.Map<java.lang.String, java.io.Serializable> workflowContext, 3134 com.liferay.portal.service.ServiceContext serviceContext) 3135 throws com.liferay.portal.kernel.exception.PortalException, 3136 com.liferay.portal.kernel.exception.SystemException; 3137 3138 /** 3139 * Updates the workflow status of the web content article matching the 3140 * group, article ID, and version. 3141 * 3142 * @param userId the primary key of the user updating the web content 3143 article's status 3144 * @param groupId the primary key of the web content article's group 3145 * @param articleId the primary key of the web content article 3146 * @param version the web content article's version 3147 * @param status the web content article's workflow status. For more 3148 information see {@link WorkflowConstants} for constants starting 3149 with the "STATUS_" prefix. 3150 * @param articleURL the web content article's accessible URL 3151 * @param workflowContext the web content article's configured workflow 3152 * @param serviceContext the service context to be applied. Can set the 3153 modification date, portlet preferences, and can set whether to 3154 add the default command update for the web content article. 3155 * @return the updated web content article 3156 * @throws PortalException if a matching web content article could not be 3157 found or if a portal exception occurred 3158 * @throws SystemException if a system exception occurred 3159 */ 3160 public com.liferay.portlet.journal.model.JournalArticle updateStatus( 3161 long userId, long groupId, java.lang.String articleId, double version, 3162 int status, java.lang.String articleURL, 3163 java.util.Map<java.lang.String, java.io.Serializable> workflowContext, 3164 com.liferay.portal.service.ServiceContext serviceContext) 3165 throws com.liferay.portal.kernel.exception.PortalException, 3166 com.liferay.portal.kernel.exception.SystemException; 3167 3168 /** 3169 * Updates the web content articles matching the group, class name ID, and 3170 * DDM template key, replacing the DDM template key with a new one. 3171 * 3172 * @param groupId the primary key of the web content article's group 3173 * @param classNameId the primary key of the DDMStructure class if the web 3174 content article is related to a DDM structure, the primary key of 3175 the class name associated with the article, or {@link 3176 JournalArticleConstants#CLASSNAME_ID_DEFAULT} otherwise 3177 * @param oldDDMTemplateKey the primary key of the web content article's 3178 old DDM template 3179 * @param newDDMTemplateKey the primary key of the web content article's 3180 new DDM template 3181 * @throws SystemException if a system exception occurred 3182 */ 3183 public void updateTemplateId(long groupId, long classNameId, 3184 java.lang.String oldDDMTemplateKey, java.lang.String newDDMTemplateKey) 3185 throws com.liferay.portal.kernel.exception.SystemException; 3186 }