|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exoplatform.social.client.core.service.ServiceBase<RestActivity,ActivityService<RestActivity>>
org.exoplatform.social.client.core.service.ActivityServiceImpl
public class ActivityServiceImpl
Implementation of ActivityService.
| Field Summary |
|---|
| Fields inherited from class org.exoplatform.social.client.core.service.ServiceBase |
|---|
crudLifecycle, lifecycle, started |
| Fields inherited from interface org.exoplatform.social.client.api.event.CRUDLifecycle |
|---|
AFTER_CREATE_EVENT, AFTER_DELETE_EVENT, AFTER_UPDATE_EVENT, BEFORE_CREATE_EVENT, BEFORE_DELETE_EVENT, BEFORE_UPDATE_EVENT, CREATE_EVENT, DELETE_EVENT, UPDATE_EVENT |
| Fields inherited from interface org.exoplatform.social.client.api.event.Lifecycle |
|---|
AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, DESTROY_EVENT, START_EVENT, STOP_EVENT |
| Constructor Summary | |
|---|---|
ActivityServiceImpl()
|
|
| Method Summary | |
|---|---|
RestActivity |
create(RestActivity newInstance)
Creates a new instance. |
RestComment |
createComment(RestActivity existingRestActivity,
RestComment newRestComment)
Creates a new comment to this activity. |
RestActivity |
delete(RestActivity existingInstance)
Deletes an existing instance. |
RestComment |
deleteComment(RestComment existingRestComment)
Deletes an existing comment. |
RestActivity |
get(String uuid)
Gets an existing instance by its uuid. |
RealtimeListAccess<RestActivity> |
getActivityStream(RestIdentity restIdentity)
Gets activity stream from an owner stream identity. |
RestComment |
getComment(String commentId)
Gets an existing comment by its id. |
RealtimeListAccess<RestActivity> |
getConnectionsActivityStream(RestIdentity userRestIdentity)
Gets all connections' activities aggregated into one stream. |
RealtimeListAccess<RestActivity> |
getFeedActivityStream(RestIdentity userRestIdentity)
Gets all activities from a stream owner, his connections and spaces aggregated into one stream. |
RealtimeListAccess<RestActivity> |
getSpacesActivityStream(RestIdentity userRestIdentity)
Gets all activities from spaces which a user is a member of that space aggregated into one stream. |
RestLike |
like(RestActivity existingRestActivity)
The authenticate identity likes an existing activity. |
RestLike |
unlike(RestActivity existingRestActivity)
The authenticated identity unlikes an existing activity. |
RestActivity |
update(RestActivity existingInstance)
Updates an existing instance. |
| Methods inherited from class org.exoplatform.social.client.core.service.ServiceBase |
|---|
addCRUDLifecycleListener, addLifecycleListener, doCreate, doDelete, doUpdate, findCRUDLifecycleListeners, findLifecycleListeners, postCreate, postDelete, postUpdate, preCreate, preDelete, preUpdate, removeCRUDLifecycleListener, removeLifecycleListener, start, stop |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ActivityServiceImpl()
| Method Detail |
|---|
public RestActivity create(RestActivity newInstance)
throws AccessDeniedException,
ServiceException
create in interface Service<RestActivity>newInstance - new instance
AccessDeniedException
ServiceException
public RestActivity get(String uuid)
throws AccessDeniedException,
ServiceException
get in interface Service<RestActivity>uuid - the uuid
AccessDeniedException
ServiceException
public RestActivity update(RestActivity existingInstance)
throws AccessDeniedException,
ServiceException
update in interface Service<RestActivity>AccessDeniedException
ServiceException
public RestActivity delete(RestActivity existingInstance)
throws AccessDeniedException,
ServiceException
delete in interface Service<RestActivity>AccessDeniedException
ServiceException
public RealtimeListAccess<RestActivity> getActivityStream(RestIdentity restIdentity)
throws AccessDeniedException,
ServiceException
RestIdentity demoIdentity = identityService.get("123456789abcdef");
RealtimeListAccess activityListAccess = activityService.getActivityStream(demoIdentity);
or:
RestIdentity spaceIdentity = new RestIdentityImpl();
spaceIdentity.setProviderId("space");
spaceIdentity.setRemoteId("hello_world");
RealtimeListAccess activityListAccess = activityService.getActivitySream(spaceIdentity);
getActivityStream in interface ActivityService<RestActivity>restIdentity - the owner stream identity, could be a user or space identity.
AccessDeniedException
ServiceException
public RealtimeListAccess<RestActivity> getSpacesActivityStream(RestIdentity userRestIdentity)
throws AccessDeniedException,
ServiceException
ActivityService
getSpacesActivityStream in interface ActivityService<RestActivity>userRestIdentity - the associated user identity
AccessDeniedException
ServiceException
public RealtimeListAccess<RestActivity> getConnectionsActivityStream(RestIdentity userRestIdentity)
throws AccessDeniedException,
ServiceException
ActivityService
getConnectionsActivityStream in interface ActivityService<RestActivity>userRestIdentity - the associated user identity
AccessDeniedException
ServiceException
public RealtimeListAccess<RestActivity> getFeedActivityStream(RestIdentity userRestIdentity)
throws AccessDeniedException,
ServiceException
ActivityService
getFeedActivityStream in interface ActivityService<RestActivity>userRestIdentity - the associated user identity
AccessDeniedException
ServiceException
public RestComment createComment(RestActivity existingRestActivity,
RestComment newRestComment)
throws AccessDeniedException,
ServiceException
createComment in interface ActivityService<RestActivity>existingRestActivity - the existing activitynewRestComment - the new created comment
AccessDeniedException
ServiceException
public RestComment getComment(String commentId)
throws AccessDeniedException,
ServiceException
getComment in interface ActivityService<RestActivity>commentId - the comment id
AccessDeniedException
ServiceException
public RestComment deleteComment(RestComment existingRestComment)
throws AccessDeniedException,
ServiceException
deleteComment in interface ActivityService<RestActivity>existingRestComment - the existing comment
AccessDeniedException
ServiceException
public RestLike like(RestActivity existingRestActivity)
throws AccessDeniedException,
ServiceException
like in interface ActivityService<RestActivity>existingRestActivity - the existing activity
RestLike instance
AccessDeniedException
ServiceException
public RestLike unlike(RestActivity existingRestActivity)
throws AccessDeniedException,
ServiceException
unlike in interface ActivityService<RestActivity>existingRestActivity - the existing activity
RestLike instance.
AccessDeniedException
ServiceException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||