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