001 /** 002 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved. 003 * 004 * The contents of this file are subject to the terms of the Liferay Enterprise 005 * Subscription License ("License"). You may not use this file except in 006 * compliance with the License. You can obtain a copy of the License by 007 * contacting Liferay, Inc. See the License for the specific language governing 008 * permissions and limitations under the License, including but not limited to 009 * distribution rights of the Software. 010 * 011 * 012 * 013 */ 014 015 package com.liferay.portlet.social.service; 016 017 import com.liferay.portal.service.ServiceWrapper; 018 019 /** 020 * <p> 021 * This class is a wrapper for {@link SocialActivityLocalService}. 022 * </p> 023 * 024 * @author Brian Wing Shun Chan 025 * @see SocialActivityLocalService 026 * @generated 027 */ 028 public class SocialActivityLocalServiceWrapper 029 implements SocialActivityLocalService, 030 ServiceWrapper<SocialActivityLocalService> { 031 public SocialActivityLocalServiceWrapper( 032 SocialActivityLocalService socialActivityLocalService) { 033 _socialActivityLocalService = socialActivityLocalService; 034 } 035 036 /** 037 * Adds the social activity to the database. Also notifies the appropriate model listeners. 038 * 039 * @param socialActivity the social activity 040 * @return the social activity that was added 041 * @throws SystemException if a system exception occurred 042 */ 043 public com.liferay.portlet.social.model.SocialActivity addSocialActivity( 044 com.liferay.portlet.social.model.SocialActivity socialActivity) 045 throws com.liferay.portal.kernel.exception.SystemException { 046 return _socialActivityLocalService.addSocialActivity(socialActivity); 047 } 048 049 /** 050 * Creates a new social activity with the primary key. Does not add the social activity to the database. 051 * 052 * @param activityId the primary key for the new social activity 053 * @return the new social activity 054 */ 055 public com.liferay.portlet.social.model.SocialActivity createSocialActivity( 056 long activityId) { 057 return _socialActivityLocalService.createSocialActivity(activityId); 058 } 059 060 /** 061 * Deletes the social activity with the primary key from the database. Also notifies the appropriate model listeners. 062 * 063 * @param activityId the primary key of the social activity 064 * @throws PortalException if a social activity with the primary key could not be found 065 * @throws SystemException if a system exception occurred 066 */ 067 public void deleteSocialActivity(long activityId) 068 throws com.liferay.portal.kernel.exception.PortalException, 069 com.liferay.portal.kernel.exception.SystemException { 070 _socialActivityLocalService.deleteSocialActivity(activityId); 071 } 072 073 /** 074 * Deletes the social activity from the database. Also notifies the appropriate model listeners. 075 * 076 * @param socialActivity the social activity 077 * @throws SystemException if a system exception occurred 078 */ 079 public void deleteSocialActivity( 080 com.liferay.portlet.social.model.SocialActivity socialActivity) 081 throws com.liferay.portal.kernel.exception.SystemException { 082 _socialActivityLocalService.deleteSocialActivity(socialActivity); 083 } 084 085 /** 086 * Performs a dynamic query on the database and returns the matching rows. 087 * 088 * @param dynamicQuery the dynamic query 089 * @return the matching rows 090 * @throws SystemException if a system exception occurred 091 */ 092 @SuppressWarnings("rawtypes") 093 public java.util.List dynamicQuery( 094 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 095 throws com.liferay.portal.kernel.exception.SystemException { 096 return _socialActivityLocalService.dynamicQuery(dynamicQuery); 097 } 098 099 /** 100 * Performs a dynamic query on the database and returns a range of the matching rows. 101 * 102 * <p> 103 * 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. 104 * </p> 105 * 106 * @param dynamicQuery the dynamic query 107 * @param start the lower bound of the range of model instances 108 * @param end the upper bound of the range of model instances (not inclusive) 109 * @return the range of matching rows 110 * @throws SystemException if a system exception occurred 111 */ 112 @SuppressWarnings("rawtypes") 113 public java.util.List dynamicQuery( 114 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 115 int end) throws com.liferay.portal.kernel.exception.SystemException { 116 return _socialActivityLocalService.dynamicQuery(dynamicQuery, start, end); 117 } 118 119 /** 120 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 121 * 122 * <p> 123 * 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. 124 * </p> 125 * 126 * @param dynamicQuery the dynamic query 127 * @param start the lower bound of the range of model instances 128 * @param end the upper bound of the range of model instances (not inclusive) 129 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 130 * @return the ordered range of matching rows 131 * @throws SystemException if a system exception occurred 132 */ 133 @SuppressWarnings("rawtypes") 134 public java.util.List dynamicQuery( 135 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 136 int end, 137 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 138 throws com.liferay.portal.kernel.exception.SystemException { 139 return _socialActivityLocalService.dynamicQuery(dynamicQuery, start, 140 end, orderByComparator); 141 } 142 143 /** 144 * Returns the number of rows that match the dynamic query. 145 * 146 * @param dynamicQuery the dynamic query 147 * @return the number of rows that match the dynamic query 148 * @throws SystemException if a system exception occurred 149 */ 150 public long dynamicQueryCount( 151 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 152 throws com.liferay.portal.kernel.exception.SystemException { 153 return _socialActivityLocalService.dynamicQueryCount(dynamicQuery); 154 } 155 156 public com.liferay.portlet.social.model.SocialActivity fetchSocialActivity( 157 long activityId) 158 throws com.liferay.portal.kernel.exception.SystemException { 159 return _socialActivityLocalService.fetchSocialActivity(activityId); 160 } 161 162 /** 163 * Returns the social activity with the primary key. 164 * 165 * @param activityId the primary key of the social activity 166 * @return the social activity 167 * @throws PortalException if a social activity with the primary key could not be found 168 * @throws SystemException if a system exception occurred 169 */ 170 public com.liferay.portlet.social.model.SocialActivity getSocialActivity( 171 long activityId) 172 throws com.liferay.portal.kernel.exception.PortalException, 173 com.liferay.portal.kernel.exception.SystemException { 174 return _socialActivityLocalService.getSocialActivity(activityId); 175 } 176 177 public com.liferay.portal.model.PersistedModel getPersistedModel( 178 java.io.Serializable primaryKeyObj) 179 throws com.liferay.portal.kernel.exception.PortalException, 180 com.liferay.portal.kernel.exception.SystemException { 181 return _socialActivityLocalService.getPersistedModel(primaryKeyObj); 182 } 183 184 /** 185 * Returns a range of all the social activities. 186 * 187 * <p> 188 * 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. 189 * </p> 190 * 191 * @param start the lower bound of the range of social activities 192 * @param end the upper bound of the range of social activities (not inclusive) 193 * @return the range of social activities 194 * @throws SystemException if a system exception occurred 195 */ 196 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getSocialActivities( 197 int start, int end) 198 throws com.liferay.portal.kernel.exception.SystemException { 199 return _socialActivityLocalService.getSocialActivities(start, end); 200 } 201 202 /** 203 * Returns the number of social activities. 204 * 205 * @return the number of social activities 206 * @throws SystemException if a system exception occurred 207 */ 208 public int getSocialActivitiesCount() 209 throws com.liferay.portal.kernel.exception.SystemException { 210 return _socialActivityLocalService.getSocialActivitiesCount(); 211 } 212 213 /** 214 * Updates the social activity in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 215 * 216 * @param socialActivity the social activity 217 * @return the social activity that was updated 218 * @throws SystemException if a system exception occurred 219 */ 220 public com.liferay.portlet.social.model.SocialActivity updateSocialActivity( 221 com.liferay.portlet.social.model.SocialActivity socialActivity) 222 throws com.liferay.portal.kernel.exception.SystemException { 223 return _socialActivityLocalService.updateSocialActivity(socialActivity); 224 } 225 226 /** 227 * Updates the social activity in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 228 * 229 * @param socialActivity the social activity 230 * @param merge whether to merge the social activity with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation. 231 * @return the social activity that was updated 232 * @throws SystemException if a system exception occurred 233 */ 234 public com.liferay.portlet.social.model.SocialActivity updateSocialActivity( 235 com.liferay.portlet.social.model.SocialActivity socialActivity, 236 boolean merge) 237 throws com.liferay.portal.kernel.exception.SystemException { 238 return _socialActivityLocalService.updateSocialActivity(socialActivity, 239 merge); 240 } 241 242 /** 243 * Returns the Spring bean ID for this bean. 244 * 245 * @return the Spring bean ID for this bean 246 */ 247 public java.lang.String getBeanIdentifier() { 248 return _socialActivityLocalService.getBeanIdentifier(); 249 } 250 251 /** 252 * Sets the Spring bean ID for this bean. 253 * 254 * @param beanIdentifier the Spring bean ID for this bean 255 */ 256 public void setBeanIdentifier(java.lang.String beanIdentifier) { 257 _socialActivityLocalService.setBeanIdentifier(beanIdentifier); 258 } 259 260 /** 261 * Records an activity with the given time in the database. 262 * 263 * <p> 264 * This method records a social activity done on an asset, identified by 265 * its class name and class primary key, in the database. Additional 266 * information (such as the original message ID for a reply to a forum 267 * post) is passed in via the <code>extraData</code> in JSON format. For 268 * activities affecting another user, a mirror activity is generated that 269 * describes the action from the user's point of view. The target user's ID 270 * is passed in via the <code>receiverUserId</code>. 271 * </p> 272 * 273 * <p> 274 * Example for a mirrored activity:<br> When a user replies to a message 275 * boards post, the reply action is stored in the database with the 276 * <code>receiverUserId</code> being the ID of the author of the original 277 * message. The <code>extraData</code> contains the ID of the original 278 * message in JSON format. A mirror activity is generated with the values 279 * of the <code>userId</code> and the <code>receiverUserId</code> swapped. 280 * This mirror activity basically describes a "replied to" event. 281 * </p> 282 * 283 * <p> 284 * Mirror activities are most often used in relation to friend requests and 285 * activities. 286 * </p> 287 * 288 * @param userId the primary key of the acting user 289 * @param groupId the primary key of the group 290 * @param createDate the activity's date 291 * @param className the target asset's class name 292 * @param classPK the primary key of the target asset 293 * @param type the activity's type 294 * @param extraData any extra data regarding the activity 295 * @param receiverUserId the primary key of the receiving user 296 * @throws PortalException if the user or group could not be found 297 * @throws SystemException if a system exception occurred 298 */ 299 public void addActivity(long userId, long groupId, 300 java.util.Date createDate, java.lang.String className, long classPK, 301 int type, java.lang.String extraData, long receiverUserId) 302 throws com.liferay.portal.kernel.exception.PortalException, 303 com.liferay.portal.kernel.exception.SystemException { 304 _socialActivityLocalService.addActivity(userId, groupId, createDate, 305 className, classPK, type, extraData, receiverUserId); 306 } 307 308 /** 309 * Records an activity in the database, using a time based on the current 310 * time in an attempt to make the activity's time unique. 311 * 312 * @param userId the primary key of the acting user 313 * @param groupId the primary key of the group 314 * @param className the target asset's class name 315 * @param classPK the primary key of the target asset 316 * @param type the activity's type 317 * @param extraData any extra data regarding the activity 318 * @param receiverUserId the primary key of the receiving user 319 * @throws PortalException if the user or group could not be found 320 * @throws SystemException if a system exception occurred 321 */ 322 public void addActivity(long userId, long groupId, 323 java.lang.String className, long classPK, int type, 324 java.lang.String extraData, long receiverUserId) 325 throws com.liferay.portal.kernel.exception.PortalException, 326 com.liferay.portal.kernel.exception.SystemException { 327 _socialActivityLocalService.addActivity(userId, groupId, className, 328 classPK, type, extraData, receiverUserId); 329 } 330 331 public void addActivity( 332 com.liferay.portlet.social.model.SocialActivity activity, 333 com.liferay.portlet.social.model.SocialActivity mirrorActivity) 334 throws com.liferay.portal.kernel.exception.PortalException, 335 com.liferay.portal.kernel.exception.SystemException { 336 _socialActivityLocalService.addActivity(activity, mirrorActivity); 337 } 338 339 /** 340 * Records an activity in the database, but only if there isn't already an 341 * activity with the same parameters. 342 * 343 * <p> 344 * For the main functionality see {@link #addActivity(long, long, Date, 345 * String, long, int, String, long)} 346 * </p> 347 * 348 * @param userId the primary key of the acting user 349 * @param groupId the primary key of the group 350 * @param createDate the activity's date 351 * @param className the target asset's class name 352 * @param classPK the primary key of the target asset 353 * @param type the activity's type 354 * @param extraData any extra data regarding the activity 355 * @param receiverUserId the primary key of the receiving user 356 * @throws PortalException if the user or group could not be found 357 * @throws SystemException if a system exception occurred 358 */ 359 public void addUniqueActivity(long userId, long groupId, 360 java.util.Date createDate, java.lang.String className, long classPK, 361 int type, java.lang.String extraData, long receiverUserId) 362 throws com.liferay.portal.kernel.exception.PortalException, 363 com.liferay.portal.kernel.exception.SystemException { 364 _socialActivityLocalService.addUniqueActivity(userId, groupId, 365 createDate, className, classPK, type, extraData, receiverUserId); 366 } 367 368 /** 369 * Records an activity with the current time in the database, but only if 370 * there isn't one with the same parameters. 371 * 372 * <p> 373 * For the main functionality see {@link #addActivity(long, long, Date, 374 * String, long, int, String, long)} 375 * </p> 376 * 377 * @param userId the primary key of the acting user 378 * @param groupId the primary key of the group 379 * @param className the target asset's class name 380 * @param classPK the primary key of the target asset 381 * @param type the activity's type 382 * @param extraData any extra data regarding the activity 383 * @param receiverUserId the primary key of the receiving user 384 * @throws PortalException if the user or group could not be found 385 * @throws SystemException if a system exception occurred 386 */ 387 public void addUniqueActivity(long userId, long groupId, 388 java.lang.String className, long classPK, int type, 389 java.lang.String extraData, long receiverUserId) 390 throws com.liferay.portal.kernel.exception.PortalException, 391 com.liferay.portal.kernel.exception.SystemException { 392 _socialActivityLocalService.addUniqueActivity(userId, groupId, 393 className, classPK, type, extraData, receiverUserId); 394 } 395 396 /** 397 * Removes stored activities for the asset identified by the class name ID 398 * and class primary key. 399 * 400 * @throws SystemException if a system exception occurred 401 */ 402 public void deleteActivities( 403 com.liferay.portlet.asset.model.AssetEntry assetEntry) 404 throws com.liferay.portal.kernel.exception.PortalException, 405 com.liferay.portal.kernel.exception.SystemException { 406 _socialActivityLocalService.deleteActivities(assetEntry); 407 } 408 409 /** 410 * Removes stored activities for the asset identified by the class name and 411 * class primary key. 412 * 413 * @param className the target asset's class name 414 * @param classPK the primary key of the target asset 415 * @throws SystemException if a system exception occurred 416 */ 417 public void deleteActivities(java.lang.String className, long classPK) 418 throws com.liferay.portal.kernel.exception.SystemException { 419 _socialActivityLocalService.deleteActivities(className, classPK); 420 } 421 422 /** 423 * Removes the stored activity from the database. 424 * 425 * @param activityId the primary key of the stored activity 426 * @throws PortalException if the activity could not be found 427 * @throws SystemException if a system exception occurred 428 */ 429 public void deleteActivity(long activityId) 430 throws com.liferay.portal.kernel.exception.PortalException, 431 com.liferay.portal.kernel.exception.SystemException { 432 _socialActivityLocalService.deleteActivity(activityId); 433 } 434 435 /** 436 * Removes the stored activity and its mirror activity from the database. 437 * 438 * @param activity the activity to be removed 439 * @throws SystemException if a system exception occurred 440 */ 441 public void deleteActivity( 442 com.liferay.portlet.social.model.SocialActivity activity) 443 throws com.liferay.portal.kernel.exception.SystemException { 444 _socialActivityLocalService.deleteActivity(activity); 445 } 446 447 /** 448 * Removes the user's stored activities from the database. 449 * 450 * <p> 451 * This method removes all activities where the user is either the actor or 452 * the receiver. 453 * </p> 454 * 455 * @param userId the primary key of the user 456 * @throws SystemException if a system exception occurred 457 */ 458 public void deleteUserActivities(long userId) 459 throws com.liferay.portal.kernel.exception.SystemException { 460 _socialActivityLocalService.deleteUserActivities(userId); 461 } 462 463 /** 464 * Returns a range of all the activities done on assets identified by the 465 * class name ID. 466 * 467 * <p> 468 * Useful when paginating results. Returns a maximum of <code>end - 469 * start</code> instances. <code>start</code> and <code>end</code> are not 470 * primary keys, they are indexes in the result set. Thus, <code>0</code> 471 * refers to the first result in the set. Setting both <code>start</code> 472 * and <code>end</code> to {@link 473 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 474 * full result set. 475 * </p> 476 * 477 * @param classNameId the target asset's class name ID 478 * @param start the lower bound of the range of results 479 * @param end the upper bound of the range of results (not inclusive) 480 * @return the range of matching activities 481 * @throws SystemException if a system exception occurred 482 */ 483 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getActivities( 484 long classNameId, int start, int end) 485 throws com.liferay.portal.kernel.exception.SystemException { 486 return _socialActivityLocalService.getActivities(classNameId, start, end); 487 } 488 489 /** 490 * Returns a range of all the activities done on the asset identified by 491 * the class name ID and class primary key that are mirrors of the activity 492 * identified by the mirror activity ID. 493 * 494 * <p> 495 * Useful when paginating results. Returns a maximum of <code>end - 496 * start</code> instances. <code>start</code> and <code>end</code> are not 497 * primary keys, they are indexes in the result set. Thus, <code>0</code> 498 * refers to the first result in the set. Setting both <code>start</code> 499 * and <code>end</code> to {@link 500 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 501 * full result set. 502 * </p> 503 * 504 * @param mirrorActivityId the primary key of the mirror activity 505 * @param classNameId the target asset's class name ID 506 * @param classPK the primary key of the target asset 507 * @param start the lower bound of the range of results 508 * @param end the upper bound of the range of results (not inclusive) 509 * @return the range of matching activities 510 * @throws SystemException if a system exception occurred 511 */ 512 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getActivities( 513 long mirrorActivityId, long classNameId, long classPK, int start, 514 int end) throws com.liferay.portal.kernel.exception.SystemException { 515 return _socialActivityLocalService.getActivities(mirrorActivityId, 516 classNameId, classPK, start, end); 517 } 518 519 /** 520 * Returns a range of all the activities done on the asset identified by 521 * the class name and the class primary key that are mirrors of the 522 * activity identified by the mirror activity ID. 523 * 524 * <p> 525 * Useful when paginating results. Returns a maximum of <code>end - 526 * start</code> instances. <code>start</code> and <code>end</code> are not 527 * primary keys, they are indexes in the result set. Thus, <code>0</code> 528 * refers to the first result in the set. Setting both <code>start</code> 529 * and <code>end</code> to {@link 530 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 531 * full result set. 532 * </p> 533 * 534 * @param mirrorActivityId the primary key of the mirror activity 535 * @param className the target asset's class name 536 * @param classPK the primary key of the target asset 537 * @param start the lower bound of the range of results 538 * @param end the upper bound of the range of results (not inclusive) 539 * @return the range of matching activities 540 * @throws SystemException if a system exception occurred 541 */ 542 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getActivities( 543 long mirrorActivityId, java.lang.String className, long classPK, 544 int start, int end) 545 throws com.liferay.portal.kernel.exception.SystemException { 546 return _socialActivityLocalService.getActivities(mirrorActivityId, 547 className, classPK, start, end); 548 } 549 550 /** 551 * Returns a range of all the activities done on assets identified by the 552 * class name. 553 * 554 * <p> 555 * Useful when paginating results. Returns a maximum of <code>end - 556 * start</code> instances. <code>start</code> and <code>end</code> are not 557 * primary keys, they are indexes in the result set. Thus, <code>0</code> 558 * refers to the first result in the set. Setting both <code>start</code> 559 * and <code>end</code> to {@link 560 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 561 * full result set. 562 * </p> 563 * 564 * @param className the target asset's class name 565 * @param start the lower bound of the range of results 566 * @param end the upper bound of the range of results (not inclusive) 567 * @return the range of matching activities 568 * @throws SystemException if a system exception occurred 569 */ 570 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getActivities( 571 java.lang.String className, int start, int end) 572 throws com.liferay.portal.kernel.exception.SystemException { 573 return _socialActivityLocalService.getActivities(className, start, end); 574 } 575 576 /** 577 * Returns the number of activities done on assets identified by the class 578 * name ID. 579 * 580 * @param classNameId the target asset's class name ID 581 * @return the number of matching activities 582 * @throws SystemException if a system exception occurred 583 */ 584 public int getActivitiesCount(long classNameId) 585 throws com.liferay.portal.kernel.exception.SystemException { 586 return _socialActivityLocalService.getActivitiesCount(classNameId); 587 } 588 589 /** 590 * Returns the number of activities done on the asset identified by the 591 * class name ID and class primary key that are mirrors of the activity 592 * identified by the mirror activity ID. 593 * 594 * @param mirrorActivityId the primary key of the mirror activity 595 * @param classNameId the target asset's class name ID 596 * @param classPK the primary key of the target asset 597 * @return the number of matching activities 598 * @throws SystemException if a system exception occurred 599 */ 600 public int getActivitiesCount(long mirrorActivityId, long classNameId, 601 long classPK) 602 throws com.liferay.portal.kernel.exception.SystemException { 603 return _socialActivityLocalService.getActivitiesCount(mirrorActivityId, 604 classNameId, classPK); 605 } 606 607 /** 608 * Returns the number of activities done on the asset identified by the 609 * class name and class primary key that are mirrors of the activity 610 * identified by the mirror activity ID. 611 * 612 * @param mirrorActivityId the primary key of the mirror activity 613 * @param className the target asset's class name 614 * @param classPK the primary key of the target asset 615 * @return the number of matching activities 616 * @throws SystemException if a system exception occurred 617 */ 618 public int getActivitiesCount(long mirrorActivityId, 619 java.lang.String className, long classPK) 620 throws com.liferay.portal.kernel.exception.SystemException { 621 return _socialActivityLocalService.getActivitiesCount(mirrorActivityId, 622 className, classPK); 623 } 624 625 /** 626 * Returns the number of activities done on assets identified by class 627 * name. 628 * 629 * @param className the target asset's class name 630 * @return the number of matching activities 631 * @throws SystemException if a system exception occurred 632 */ 633 public int getActivitiesCount(java.lang.String className) 634 throws com.liferay.portal.kernel.exception.SystemException { 635 return _socialActivityLocalService.getActivitiesCount(className); 636 } 637 638 /** 639 * Returns the activity identified by its primary key. 640 * 641 * @param activityId the primary key of the activity 642 * @return Returns the activity 643 * @throws PortalException if the activity could not be found 644 * @throws SystemException if a system exception occurred 645 */ 646 public com.liferay.portlet.social.model.SocialActivity getActivity( 647 long activityId) 648 throws com.liferay.portal.kernel.exception.PortalException, 649 com.liferay.portal.kernel.exception.SystemException { 650 return _socialActivityLocalService.getActivity(activityId); 651 } 652 653 /** 654 * Returns a range of all the activities done in the group. 655 * 656 * <p> 657 * This method only finds activities without mirrors. 658 * </p> 659 * 660 * <p> 661 * Useful when paginating results. Returns a maximum of <code>end - 662 * start</code> instances. <code>start</code> and <code>end</code> are not 663 * primary keys, they are indexes in the result set. Thus, <code>0</code> 664 * refers to the first result in the set. Setting both <code>start</code> 665 * and <code>end</code> to {@link 666 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 667 * full result set. 668 * </p> 669 * 670 * @param groupId the primary key of the group 671 * @param start the lower bound of the range of results 672 * @param end the upper bound of the range of results (not inclusive) 673 * @return the range of matching activities 674 * @throws SystemException if a system exception occurred 675 */ 676 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getGroupActivities( 677 long groupId, int start, int end) 678 throws com.liferay.portal.kernel.exception.SystemException { 679 return _socialActivityLocalService.getGroupActivities(groupId, start, 680 end); 681 } 682 683 /** 684 * Returns the number of activities done in the group. 685 * 686 * <p> 687 * This method only counts activities without mirrors. 688 * </p> 689 * 690 * @param groupId the primary key of the group 691 * @return the number of matching activities 692 * @throws SystemException if a system exception occurred 693 */ 694 public int getGroupActivitiesCount(long groupId) 695 throws com.liferay.portal.kernel.exception.SystemException { 696 return _socialActivityLocalService.getGroupActivitiesCount(groupId); 697 } 698 699 /** 700 * Returns a range of activities done by users that are members of the 701 * group. 702 * 703 * <p> 704 * This method only finds activities without mirrors. 705 * </p> 706 * 707 * <p> 708 * Useful when paginating results. Returns a maximum of <code>end - 709 * start</code> instances. <code>start</code> and <code>end</code> are not 710 * primary keys, they are indexes in the result set. Thus, <code>0</code> 711 * refers to the first result in the set. Setting both <code>start</code> 712 * and <code>end</code> to {@link 713 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 714 * full result set. 715 * </p> 716 * 717 * @param groupId the primary key of the group 718 * @param start the lower bound of the range of results 719 * @param end the upper bound of the range of results (not inclusive) 720 * @return the range of matching activities 721 * @throws SystemException if a system exception occurred 722 */ 723 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getGroupUsersActivities( 724 long groupId, int start, int end) 725 throws com.liferay.portal.kernel.exception.SystemException { 726 return _socialActivityLocalService.getGroupUsersActivities(groupId, 727 start, end); 728 } 729 730 /** 731 * Returns the number of activities done by users that are members of the 732 * group. 733 * 734 * <p> 735 * This method only counts activities without mirrors. 736 * </p> 737 * 738 * @param groupId the primary key of the group 739 * @return the number of matching activities 740 * @throws SystemException if a system exception occurred 741 */ 742 public int getGroupUsersActivitiesCount(long groupId) 743 throws com.liferay.portal.kernel.exception.SystemException { 744 return _socialActivityLocalService.getGroupUsersActivitiesCount(groupId); 745 } 746 747 /** 748 * Returns the activity that has the mirror activity. 749 * 750 * @param mirrorActivityId the primary key of the mirror activity 751 * @return Returns the mirror activity 752 * @throws PortalException if the mirror activity could not be found 753 * @throws SystemException if a system exception occurred 754 */ 755 public com.liferay.portlet.social.model.SocialActivity getMirrorActivity( 756 long mirrorActivityId) 757 throws com.liferay.portal.kernel.exception.PortalException, 758 com.liferay.portal.kernel.exception.SystemException { 759 return _socialActivityLocalService.getMirrorActivity(mirrorActivityId); 760 } 761 762 /** 763 * Returns a range of all the activities done in the organization. This 764 * method only finds activities without mirrors. 765 * 766 * <p> 767 * Useful when paginating results. Returns a maximum of <code>end - 768 * start</code> instances. <code>start</code> and <code>end</code> are not 769 * primary keys, they are indexes in the result set. Thus, <code>0</code> 770 * refers to the first result in the set. Setting both <code>start</code> 771 * and <code>end</code> to {@link 772 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 773 * full result set. 774 * </p> 775 * 776 * @param organizationId the primary key of the organization 777 * @param start the lower bound of the range of results 778 * @param end the upper bound of the range of results (not inclusive) 779 * @return the range of matching activities 780 * @throws SystemException if a system exception occurred 781 */ 782 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getOrganizationActivities( 783 long organizationId, int start, int end) 784 throws com.liferay.portal.kernel.exception.SystemException { 785 return _socialActivityLocalService.getOrganizationActivities(organizationId, 786 start, end); 787 } 788 789 /** 790 * Returns the number of activities done in the organization. This method 791 * only counts activities without mirrors. 792 * 793 * @param organizationId the primary key of the organization 794 * @return the number of matching activities 795 * @throws SystemException if a system exception occurred 796 */ 797 public int getOrganizationActivitiesCount(long organizationId) 798 throws com.liferay.portal.kernel.exception.SystemException { 799 return _socialActivityLocalService.getOrganizationActivitiesCount(organizationId); 800 } 801 802 /** 803 * Returns a range of all the activities done by users of the organization. 804 * This method only finds activities without mirrors. 805 * 806 * <p> 807 * Useful when paginating results. Returns a maximum of <code>end - 808 * start</code> instances. <code>start</code> and <code>end</code> are not 809 * primary keys, they are indexes in the result set. Thus, <code>0</code> 810 * refers to the first result in the set. Setting both <code>start</code> 811 * and <code>end</code> to {@link 812 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 813 * full result set. 814 * </p> 815 * 816 * @param organizationId the primary key of the organization 817 * @param start the lower bound of the range of results 818 * @param end the upper bound of the range of results (not inclusive) 819 * @return the range of matching activities 820 * @throws SystemException if a system exception occurred 821 */ 822 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getOrganizationUsersActivities( 823 long organizationId, int start, int end) 824 throws com.liferay.portal.kernel.exception.SystemException { 825 return _socialActivityLocalService.getOrganizationUsersActivities(organizationId, 826 start, end); 827 } 828 829 /** 830 * Returns the number of activities done by users of the organization. This 831 * method only counts activities without mirrors. 832 * 833 * @param organizationId the primary key of the organization 834 * @return the number of matching activities 835 * @throws SystemException if a system exception occurred 836 */ 837 public int getOrganizationUsersActivitiesCount(long organizationId) 838 throws com.liferay.portal.kernel.exception.SystemException { 839 return _socialActivityLocalService.getOrganizationUsersActivitiesCount(organizationId); 840 } 841 842 /** 843 * Returns a range of all the activities done by users in a relationship 844 * with the user identified by the user ID. 845 * 846 * <p> 847 * Useful when paginating results. Returns a maximum of <code>end - 848 * start</code> instances. <code>start</code> and <code>end</code> are not 849 * primary keys, they are indexes in the result set. Thus, <>0</code> 850 * refers to the first result in the set. Setting both <code>start</code> 851 * and <code>end</code> to {@link 852 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 853 * full result set. 854 * </p> 855 * 856 * @param userId the primary key of the user 857 * @param start the lower bound of the range of results 858 * @param end the upper bound of the range of results (not inclusive) 859 * @return the range of matching activities 860 * @throws SystemException if a system exception occurred 861 */ 862 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getRelationActivities( 863 long userId, int start, int end) 864 throws com.liferay.portal.kernel.exception.SystemException { 865 return _socialActivityLocalService.getRelationActivities(userId, start, 866 end); 867 } 868 869 /** 870 * Returns a range of all the activities done by users in a relationship of 871 * type <code>type</code> with the user identified by <code>userId</code>. 872 * This method only finds activities without mirrors. 873 * 874 * <p> 875 * Useful when paginating results. Returns a maximum of <code>end - 876 * start</code> instances. <code>start</code> and <code>end</code> are not 877 * primary keys, they are indexes in the result set. Thus, <code>0</code> 878 * refers to the first result in the set. Setting both <code>start</code> 879 * and <code>end</code> to {@link 880 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 881 * full result set. 882 * </p> 883 * 884 * @param userId the primary key of the user 885 * @param type the relationship type 886 * @param start the lower bound of the range of results 887 * @param end the upper bound of the range of results (not inclusive) 888 * @return the range of matching activities 889 * @throws SystemException if a system exception occurred 890 */ 891 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getRelationActivities( 892 long userId, int type, int start, int end) 893 throws com.liferay.portal.kernel.exception.SystemException { 894 return _socialActivityLocalService.getRelationActivities(userId, type, 895 start, end); 896 } 897 898 /** 899 * Returns the number of activities done by users in a relationship with 900 * the user identified by userId. 901 * 902 * @param userId the primary key of the user 903 * @return the number of matching activities 904 * @throws SystemException if a system exception occurred 905 */ 906 public int getRelationActivitiesCount(long userId) 907 throws com.liferay.portal.kernel.exception.SystemException { 908 return _socialActivityLocalService.getRelationActivitiesCount(userId); 909 } 910 911 /** 912 * Returns the number of activities done by users in a relationship of type 913 * <code>type</code> with the user identified by <code>userId</code>. This 914 * method only counts activities without mirrors. 915 * 916 * @param userId the primary key of the user 917 * @param type the relationship type 918 * @return the number of matching activities 919 * @throws SystemException if a system exception occurred 920 */ 921 public int getRelationActivitiesCount(long userId, int type) 922 throws com.liferay.portal.kernel.exception.SystemException { 923 return _socialActivityLocalService.getRelationActivitiesCount(userId, 924 type); 925 } 926 927 /** 928 * Returns a range of all the activities done by the user. 929 * 930 * <p> 931 * Useful when paginating results. Returns a maximum of <code>end - 932 * start</code> instances. <code>start</code> and <code>end</code> are not 933 * primary keys, they are indexes in the result set. Thus, <code>0</code> 934 * refers to the first result in the set. Setting both <code>start</code> 935 * and <code>end</code> to {@link 936 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 937 * full result set. 938 * </p> 939 * 940 * @param userId the primary key of the user 941 * @param start the lower bound of the range of results 942 * @param end the upper bound of the range of results (not inclusive) 943 * @return the range of matching activities 944 * @throws SystemException if a system exception occurred 945 */ 946 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getUserActivities( 947 long userId, int start, int end) 948 throws com.liferay.portal.kernel.exception.SystemException { 949 return _socialActivityLocalService.getUserActivities(userId, start, end); 950 } 951 952 /** 953 * Returns the number of activities done by the user. 954 * 955 * @param userId the primary key of the user 956 * @return the number of matching activities 957 * @throws SystemException if a system exception occurred 958 */ 959 public int getUserActivitiesCount(long userId) 960 throws com.liferay.portal.kernel.exception.SystemException { 961 return _socialActivityLocalService.getUserActivitiesCount(userId); 962 } 963 964 /** 965 * Returns a range of all the activities done in the user's groups. This 966 * method only finds activities without mirrors. 967 * 968 * <p> 969 * Useful when paginating results. Returns a maximum of <code>end - 970 * start</code> instances. <code>start</code> and <code>end</code> are not 971 * primary keys, they are indexes in the result set. Thus, <code>0</code> 972 * refers to the first result in the set. Setting both <code>start</code> 973 * and <code>end</code> to {@link 974 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 975 * full result set. 976 * </p> 977 * 978 * @param userId the primary key of the user 979 * @param start the lower bound of the range of results 980 * @param end the upper bound of the range of results (not inclusive) 981 * @return the range of matching activities 982 * @throws SystemException if a system exception occurred 983 */ 984 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getUserGroupsActivities( 985 long userId, int start, int end) 986 throws com.liferay.portal.kernel.exception.SystemException { 987 return _socialActivityLocalService.getUserGroupsActivities(userId, 988 start, end); 989 } 990 991 /** 992 * Returns the number of activities done in user's groups. This method only 993 * counts activities without mirrors. 994 * 995 * @param userId the primary key of the user 996 * @return the number of matching activities 997 * @throws SystemException if a system exception occurred 998 */ 999 public int getUserGroupsActivitiesCount(long userId) 1000 throws com.liferay.portal.kernel.exception.SystemException { 1001 return _socialActivityLocalService.getUserGroupsActivitiesCount(userId); 1002 } 1003 1004 /** 1005 * Returns a range of all the activities done in the user's groups and 1006 * organizations. This method only finds activities without mirrors. 1007 * 1008 * <p> 1009 * Useful when paginating results. Returns a maximum of <code>end - 1010 * start</code> instances. <code>start</code> and <code>end</code> are not 1011 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1012 * refers to the first result in the set. Setting both <code>start</code> 1013 * and <code>end</code> to {@link 1014 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 1015 * full result set. 1016 * </p> 1017 * 1018 * @param userId the primary key of the user 1019 * @param start the lower bound of the range of results 1020 * @param end the upper bound of the range of results (not inclusive) 1021 * @return the range of matching activities 1022 * @throws SystemException if a system exception occurred 1023 */ 1024 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getUserGroupsAndOrganizationsActivities( 1025 long userId, int start, int end) 1026 throws com.liferay.portal.kernel.exception.SystemException { 1027 return _socialActivityLocalService.getUserGroupsAndOrganizationsActivities(userId, 1028 start, end); 1029 } 1030 1031 /** 1032 * Returns the number of activities done in user's groups and 1033 * organizations. This method only counts activities without mirrors. 1034 * 1035 * @param userId the primary key of the user 1036 * @return the number of matching activities 1037 * @throws SystemException if a system exception occurred 1038 */ 1039 public int getUserGroupsAndOrganizationsActivitiesCount(long userId) 1040 throws com.liferay.portal.kernel.exception.SystemException { 1041 return _socialActivityLocalService.getUserGroupsAndOrganizationsActivitiesCount(userId); 1042 } 1043 1044 /** 1045 * Returns a range of all activities done in the user's organizations. This 1046 * method only finds activities without mirrors. 1047 * 1048 * <p> 1049 * Useful when paginating results. Returns a maximum of <code>end - 1050 * start</code> instances. <code>start</code> and <code>end</code> are not 1051 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1052 * refers to the first result in the set. Setting both <code>start</code> 1053 * and <code>end</code> to {@link 1054 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the 1055 * full result set. 1056 * </p> 1057 * 1058 * @param userId the primary key of the user 1059 * @param start the lower bound of the range of results 1060 * @param end the upper bound of the range of results (not inclusive) 1061 * @return the range of matching activities 1062 * @throws SystemException if a system exception occurred 1063 */ 1064 public java.util.List<com.liferay.portlet.social.model.SocialActivity> getUserOrganizationsActivities( 1065 long userId, int start, int end) 1066 throws com.liferay.portal.kernel.exception.SystemException { 1067 return _socialActivityLocalService.getUserOrganizationsActivities(userId, 1068 start, end); 1069 } 1070 1071 /** 1072 * Returns the number of activities done in the user's organizations. This 1073 * method only counts activities without mirrors. 1074 * 1075 * @param userId the primary key of the user 1076 * @return the number of matching activities 1077 * @throws SystemException if a system exception occurred 1078 */ 1079 public int getUserOrganizationsActivitiesCount(long userId) 1080 throws com.liferay.portal.kernel.exception.SystemException { 1081 return _socialActivityLocalService.getUserOrganizationsActivitiesCount(userId); 1082 } 1083 1084 /** 1085 * @deprecated Renamed to {@link #getWrappedService} 1086 */ 1087 public SocialActivityLocalService getWrappedSocialActivityLocalService() { 1088 return _socialActivityLocalService; 1089 } 1090 1091 /** 1092 * @deprecated Renamed to {@link #setWrappedService} 1093 */ 1094 public void setWrappedSocialActivityLocalService( 1095 SocialActivityLocalService socialActivityLocalService) { 1096 _socialActivityLocalService = socialActivityLocalService; 1097 } 1098 1099 public SocialActivityLocalService getWrappedService() { 1100 return _socialActivityLocalService; 1101 } 1102 1103 public void setWrappedService( 1104 SocialActivityLocalService socialActivityLocalService) { 1105 _socialActivityLocalService = socialActivityLocalService; 1106 } 1107 1108 private SocialActivityLocalService _socialActivityLocalService; 1109 }