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