|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.shindig.social.sample.spi.JsonDbOpensocialService
public class JsonDbOpensocialService
Implementation of supported services backed by a JSON DB.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.apache.shindig.social.opensocial.spi.MessageService |
|---|
MessageService.NotImplementedMessageService |
| Nested classes/interfaces inherited from interface org.apache.shindig.social.opensocial.spi.AlbumService |
|---|
AlbumService.NotImplementedAlbumService |
| Nested classes/interfaces inherited from interface org.apache.shindig.social.opensocial.spi.MediaItemService |
|---|
MediaItemService.NotImplementedMediaItemService |
| Field Summary |
|---|
| Fields inherited from interface org.apache.shindig.social.opensocial.spi.PersonService |
|---|
ALL_FILTER, HAS_APP_FILTER, IS_WITH_FRIENDS_FILTER, TOP_FRIENDS_FILTER, TOP_FRIENDS_SORT |
| Constructor Summary | |
|---|---|
JsonDbOpensocialService(java.lang.String jsonLocation,
BeanConverter converter,
java.lang.String contextroot)
Initializes the JsonDbOpensocialService using Guice |
|
| Method Summary | ||
|---|---|---|
java.util.concurrent.Future<java.lang.Void> |
createActivity(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
Activity activity,
SecurityToken token)
Creates the passed in activity for the passed in user and group. |
|
java.util.concurrent.Future<ActivityEntry> |
createActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
ActivityEntry activityEntry,
SecurityToken token)
Creates the passed in activity for the passed in user and group. |
|
java.util.concurrent.Future<java.lang.Void> |
createAlbum(UserId userId,
java.lang.String appId,
Album album,
SecurityToken token)
|
|
java.util.concurrent.Future<java.lang.Void> |
createMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
MediaItem mediaItem,
SecurityToken token)
|
|
java.util.concurrent.Future<java.lang.Void> |
createMessage(UserId userId,
java.lang.String appId,
java.lang.String msgCollId,
Message message,
SecurityToken token)
Posts a message to the user's specified message collection, to be sent to the set of recipients specified in the message. |
|
java.util.concurrent.Future<MessageCollection> |
createMessageCollection(UserId userId,
MessageCollection msgCollection,
SecurityToken token)
Creates a new message collection for the given arguments |
|
java.util.concurrent.Future<java.lang.Void> |
deleteActivities(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
Deletes the activity for the passed in user and group that corresponds to the activityId. |
|
java.util.concurrent.Future<java.lang.Void> |
deleteActivityEntries(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
Deletes the activity for the passed in user and group that corresponds to the activityId. |
|
java.util.concurrent.Future<java.lang.Void> |
deleteAlbum(UserId userId,
java.lang.String appId,
java.lang.String albumId,
SecurityToken token)
|
|
java.util.concurrent.Future<java.lang.Void> |
deleteMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
SecurityToken token)
|
|
java.util.concurrent.Future<java.lang.Void> |
deleteMessageCollection(UserId userId,
java.lang.String msgCollId,
SecurityToken token)
Deletes a message collection for the given arguments |
|
java.util.concurrent.Future<java.lang.Void> |
deleteMessages(UserId userId,
java.lang.String msgCollId,
java.util.List<java.lang.String> ids,
SecurityToken token)
Deletes a set of messages for a given user/message collection |
|
java.util.concurrent.Future<java.lang.Void> |
deletePersonData(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
Deletes data for the specified user and group. |
|
|
filterFields(JSONObject object,
java.util.Set<java.lang.String> fields,
java.lang.Class<T> clz)
|
|
java.util.concurrent.Future<RestfulCollection<Activity>> |
getActivities(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
Returns a list of activities that correspond to the passed in users and group. |
|
java.util.concurrent.Future<RestfulCollection<Activity>> |
getActivities(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
Returns a set of activities for the passed in user and group that corresponds to a list of activityIds. |
|
java.util.concurrent.Future<Activity> |
getActivity(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String activityId,
SecurityToken token)
Returns an activity for the passed in user and group that corresponds to a single activityId. |
|
java.util.concurrent.Future<RestfulCollection<ActivityEntry>> |
getActivityEntries(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
Returns a list of activities that correspond to the passed in users and group. |
|
java.util.concurrent.Future<RestfulCollection<ActivityEntry>> |
getActivityEntries(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
Returns a set of activities for the passed in user and group that corresponds to a list of activityIds. |
|
java.util.concurrent.Future<ActivityEntry> |
getActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String activityId,
SecurityToken token)
Returns an activity for the passed in user and group that corresponds to a single activityId. |
|
java.util.concurrent.Future<Album> |
getAlbum(UserId userId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String albumId,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<Album>> |
getAlbums(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<Album>> |
getAlbums(UserId userId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> albumIds,
SecurityToken token)
|
|
JSONObject |
getDb()
Allows access to the underlying json db. |
|
java.util.Set<java.lang.String> |
getIdSet(java.util.Set<UserId> users,
GroupId group,
SecurityToken token)
Get the set of user id's for a set of users and a group |
|
java.util.concurrent.Future<MediaItem> |
getMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<MediaItem>> |
getMediaItems(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<MediaItem>> |
getMediaItems(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<MediaItem>> |
getMediaItems(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.util.Set<java.lang.String> mediaItemIds,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
|
|
java.util.concurrent.Future<RestfulCollection<MessageCollection>> |
getMessageCollections(UserId userId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
Returns a list of message collections corresponding to the given user |
|
java.util.concurrent.Future<RestfulCollection<Message>> |
getMessages(UserId userId,
java.lang.String msgCollId,
java.util.Set<java.lang.String> fields,
java.util.List<java.lang.String> msgIds,
CollectionOptions options,
SecurityToken token)
Returns a list of messages that correspond to the passed in data |
|
java.lang.String |
getPassword(java.lang.String username)
Public methods for use with Authentication Classes |
|
java.util.concurrent.Future<RestfulCollection<Person>> |
getPeople(java.util.Set<UserId> userIds,
GroupId groupId,
CollectionOptions options,
java.util.Set<java.lang.String> fields,
SecurityToken token)
Returns a list of people that correspond to the passed in person ids. |
|
java.util.concurrent.Future<Person> |
getPerson(UserId id,
java.util.Set<java.lang.String> fields,
SecurityToken token)
Returns a person that corresponds to the passed in person id. |
|
java.util.concurrent.Future<DataCollection> |
getPersonData(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
Retrives app data for the specified user list and group. |
|
java.util.concurrent.Future<java.lang.Void> |
modifyMessage(UserId userId,
java.lang.String msgCollId,
java.lang.String messageId,
Message message,
SecurityToken token)
Modifies/Updates a specific message with new data |
|
java.util.concurrent.Future<java.lang.Void> |
modifyMessageCollection(UserId userId,
MessageCollection msgCollection,
SecurityToken token)
Modifies/Updates a message collection for the given arguments |
|
void |
setAuthority(Authority authority)
|
|
void |
setDb(JSONObject db)
override the json database |
|
java.util.concurrent.Future<ActivityEntry> |
updateActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
ActivityEntry activityEntry,
java.lang.String activityId,
SecurityToken token)
Updates the specified Activity. |
|
java.util.concurrent.Future<java.lang.Void> |
updateAlbum(UserId userId,
java.lang.String appId,
Album album,
java.lang.String albumId,
SecurityToken token)
|
|
java.util.concurrent.Future<java.lang.Void> |
updateMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
MediaItem mediaItem,
SecurityToken token)
|
|
java.util.concurrent.Future<Person> |
updatePerson(UserId id,
Person person,
SecurityToken token)
Updates person that corresponds to the passed in person id and updates him |
|
java.util.concurrent.Future<java.lang.Void> |
updatePersonData(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.util.Map<java.lang.String,java.lang.String> values,
SecurityToken token)
Updates app data for the specified user and group with the new values. |
|
protected boolean |
viewerCanUpdatePerson(java.lang.String viewer,
java.lang.String person)
Check if a viewer is allowed to update the given person record. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
@Inject
public JsonDbOpensocialService(java.lang.String jsonLocation,
BeanConverter converter,
java.lang.String contextroot)
throws java.lang.Exception
jsonLocation - location of the json data provided by the shindig.canonical.json.db parameterconverter - an injected BeanConverter
java.lang.Exception - if any| Method Detail |
|---|
public JSONObject getDb()
public void setDb(JSONObject db)
db - a JSONObject.@Inject(optional=true) public void setAuthority(Authority authority)
public java.util.concurrent.Future<RestfulCollection<Activity>> getActivities(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getActivities in interface ActivityServiceuserIds - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies alloptions - The sorting/filtering/pagination optionstoken - A valid SecurityToken
ProtocolException
public java.util.concurrent.Future<RestfulCollection<Activity>> getActivities(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
throws ProtocolException
getActivities in interface ActivityServiceuserId - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies alloptions - The sorting/filtering/pagination optionsactivityIds - The set of activity ids to fetch.token - A valid SecurityToken
ProtocolException
public java.util.concurrent.Future<Activity> getActivity(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String activityId,
SecurityToken token)
throws ProtocolException
getActivity in interface ActivityServiceuserId - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies allactivityId - The activity id to fetch.token - A valid SecurityToken
ProtocolException
public java.util.concurrent.Future<java.lang.Void> deleteActivities(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
throws ProtocolException
deleteActivities in interface ActivityServiceuserId - The user.groupId - The group.appId - The app id.activityIds - A list of activity ids to delete.token - A valid SecurityToken.
ProtocolException
public java.util.concurrent.Future<java.lang.Void> createActivity(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
Activity activity,
SecurityToken token)
throws ProtocolException
createActivity in interface ActivityServiceuserId - The id of the person to create the activity for.groupId - The group.appId - The app id.fields - The fields to return.activity - The activity to create.token - A valid SecurityToken
ProtocolException
public java.util.concurrent.Future<RestfulCollection<Person>> getPeople(java.util.Set<UserId> userIds,
GroupId groupId,
CollectionOptions options,
java.util.Set<java.lang.String> fields,
SecurityToken token)
throws ProtocolException
getPeople in interface PersonServiceuserIds - A set of usersgroupId - The groupoptions - How to filter, sort and paginate the collection being fetchedfields - The profile details to fetch. Empty set implies alltoken - The gadget token @return a list of people.
ProtocolException
public java.util.concurrent.Future<Person> getPerson(UserId id,
java.util.Set<java.lang.String> fields,
SecurityToken token)
throws ProtocolException
getPerson in interface PersonServiceid - The id of the person to fetch.fields - The fields to fetch.token - The gadget token
ProtocolException
public java.util.concurrent.Future<Person> updatePerson(UserId id,
Person person,
SecurityToken token)
throws ProtocolException
updatePerson in interface PersonServiceid - The id of the person to fetch.token - The gadget token
ProtocolException
protected boolean viewerCanUpdatePerson(java.lang.String viewer,
java.lang.String person)
public java.util.concurrent.Future<DataCollection> getPersonData(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
throws ProtocolException
getPersonData in interface AppDataServiceuserIds - A set of UserIds.groupId - The groupappId - The appfields - The fields to filter the data by. Empty set implies alltoken - The security token
ProtocolException
public java.util.concurrent.Future<java.lang.Void> deletePersonData(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
throws ProtocolException
deletePersonData in interface AppDataServiceuserId - The usergroupId - The groupappId - The appfields - The fields to delete. Empty set implies alltoken - The security token
ProtocolException
public java.util.concurrent.Future<java.lang.Void> updatePersonData(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.util.Map<java.lang.String,java.lang.String> values,
SecurityToken token)
throws ProtocolException
updatePersonData in interface AppDataServiceuserId - The usergroupId - The groupappId - The appfields - The fields to filter the data by. Empty set implies allvalues - The values to settoken - The security token
ProtocolException
public java.util.concurrent.Future<java.lang.Void> createMessage(UserId userId,
java.lang.String appId,
java.lang.String msgCollId,
Message message,
SecurityToken token)
throws ProtocolException
createMessage in interface MessageServiceuserId - The user posting the message.appId - The app idmsgCollId - The message collection Id to post to, default @outboxmessage - The message to posttoken - A valid security token @return a response item containing any errors/
ProtocolException - when invalid parameters are given
public java.util.concurrent.Future<RestfulCollection<MessageCollection>> getMessageCollections(UserId userId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getMessageCollections in interface MessageServiceuserId - The User to fetch forfields - The fields to fetch for the message collectionsoptions - Pagination, etaltoken - Given security token for this request
ProtocolException - when invalid parameters are given
public java.util.concurrent.Future<java.lang.Void> deleteMessages(UserId userId,
java.lang.String msgCollId,
java.util.List<java.lang.String> ids,
SecurityToken token)
throws ProtocolException
deleteMessages in interface MessageServiceuserId - The User to delete formsgCollId - The Message Collection ID to delete from, default @allids - List of IDs to deletetoken - Given Security Token for this request
ProtocolException
public java.util.concurrent.Future<RestfulCollection<Message>> getMessages(UserId userId,
java.lang.String msgCollId,
java.util.Set<java.lang.String> fields,
java.util.List<java.lang.String> msgIds,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getMessages in interface MessageServiceuserId - The User to fetch formsgCollId - The message Collection ID to fetch from, default @allfields - The fields to fetch for the messagesmsgIds - An explicit set of message ids to fetchoptions - Options to control the fetchtoken - Given security token for this request
ProtocolException - when invalid parameters are given
public java.util.concurrent.Future<MessageCollection> createMessageCollection(UserId userId,
MessageCollection msgCollection,
SecurityToken token)
throws ProtocolException
createMessageCollection in interface MessageServiceuserId - The userId to create the message collection formsgCollection - A message collection that is to be createdtoken - A security token for this request
ProtocolException - when invalid parameters are given or not implemented
public java.util.concurrent.Future<java.lang.Void> modifyMessage(UserId userId,
java.lang.String msgCollId,
java.lang.String messageId,
Message message,
SecurityToken token)
throws ProtocolException
modifyMessage in interface MessageServiceuserId - The User to modify formsgCollId - The Message Collection ID to modify from, default @allmessageId - The messageId to modifymessage - The message details to modifytoken - Given Security Token for this request
ProtocolException - for invalid parameters or missing messages or users
public java.util.concurrent.Future<java.lang.Void> modifyMessageCollection(UserId userId,
MessageCollection msgCollection,
SecurityToken token)
throws ProtocolException
modifyMessageCollection in interface MessageServiceuserId - The userId to modify the message collection formsgCollection - Data for the message collection to be modifiedtoken - A security token for this request
ProtocolException - when invalid parameters are given or not implemented
public java.util.concurrent.Future<java.lang.Void> deleteMessageCollection(UserId userId,
java.lang.String msgCollId,
SecurityToken token)
throws ProtocolException
deleteMessageCollection in interface MessageServiceuserId - The userId to create the message collection formsgCollId - Data for the message collection to be modifiedtoken - A security token for this request
ProtocolException - when invalid parameters are given, the message collection does not exist or not implementedpublic java.lang.String getPassword(java.lang.String username)
username - a String object.
String object.
public java.util.Set<java.lang.String> getIdSet(java.util.Set<UserId> users,
GroupId group,
SecurityToken token)
throws JSONException
users - set of UserIdsgroup - the grouptoken - a token
JSONException - if errors in Json
public java.util.concurrent.Future<Album> getAlbum(UserId userId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String albumId,
SecurityToken token)
throws ProtocolException
getAlbum in interface AlbumServiceProtocolException
public java.util.concurrent.Future<RestfulCollection<Album>> getAlbums(UserId userId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> albumIds,
SecurityToken token)
throws ProtocolException
getAlbums in interface AlbumServiceProtocolException
public java.util.concurrent.Future<RestfulCollection<Album>> getAlbums(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getAlbums in interface AlbumServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> deleteAlbum(UserId userId,
java.lang.String appId,
java.lang.String albumId,
SecurityToken token)
throws ProtocolException
deleteAlbum in interface AlbumServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> createAlbum(UserId userId,
java.lang.String appId,
Album album,
SecurityToken token)
throws ProtocolException
createAlbum in interface AlbumServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> updateAlbum(UserId userId,
java.lang.String appId,
Album album,
java.lang.String albumId,
SecurityToken token)
throws ProtocolException
updateAlbum in interface AlbumServiceProtocolException
public java.util.concurrent.Future<MediaItem> getMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
java.util.Set<java.lang.String> fields,
SecurityToken token)
throws ProtocolException
getMediaItem in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<RestfulCollection<MediaItem>> getMediaItems(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.util.Set<java.lang.String> mediaItemIds,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getMediaItems in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<RestfulCollection<MediaItem>> getMediaItems(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getMediaItems in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<RestfulCollection<MediaItem>> getMediaItems(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getMediaItems in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> deleteMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
SecurityToken token)
throws ProtocolException
deleteMediaItem in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> createMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
MediaItem mediaItem,
SecurityToken token)
throws ProtocolException
createMediaItem in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<java.lang.Void> updateMediaItem(UserId userId,
java.lang.String appId,
java.lang.String albumId,
java.lang.String mediaItemId,
MediaItem mediaItem,
SecurityToken token)
throws ProtocolException
updateMediaItem in interface MediaItemServiceProtocolException
public java.util.concurrent.Future<ActivityEntry> updateActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
ActivityEntry activityEntry,
java.lang.String activityId,
SecurityToken token)
throws ProtocolException
updateActivityEntry in interface ActivityStreamServiceuserId - The id of the person to update the activity forgroupId - The groupappId - The app idfields - The fields to returnactivityEntry - The updated activityactivityId - The id of the existing activity to updatetoken - A valid SecurityToken
ProtocolException - if any
public java.util.concurrent.Future<ActivityEntry> createActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
ActivityEntry activityEntry,
SecurityToken token)
throws ProtocolException
createActivityEntry in interface ActivityStreamServiceuserId - The id of the person to create the activity for.groupId - The group.appId - The app id.fields - The fields to return.activityEntry - The activity to create.token - A valid SecurityToken
ProtocolException - if any.
public java.util.concurrent.Future<java.lang.Void> deleteActivityEntries(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
throws ProtocolException
deleteActivityEntries in interface ActivityStreamServiceuserId - The user.groupId - The group.appId - The app id.activityIds - A list of activity ids to delete.token - A valid SecurityToken.
ProtocolException - if any.
public java.util.concurrent.Future<ActivityEntry> getActivityEntry(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
java.lang.String activityId,
SecurityToken token)
throws ProtocolException
getActivityEntry in interface ActivityStreamServiceuserId - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies allactivityId - The activity id to fetch.token - A valid SecurityToken
ProtocolException - if any.
public java.util.concurrent.Future<RestfulCollection<ActivityEntry>> getActivityEntries(java.util.Set<UserId> userIds,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
SecurityToken token)
throws ProtocolException
getActivityEntries in interface ActivityStreamServiceuserIds - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies alloptions - The sorting/filtering/pagination optionstoken - A valid SecurityToken
ProtocolException - if any.
public java.util.concurrent.Future<RestfulCollection<ActivityEntry>> getActivityEntries(UserId userId,
GroupId groupId,
java.lang.String appId,
java.util.Set<java.lang.String> fields,
CollectionOptions options,
java.util.Set<java.lang.String> activityIds,
SecurityToken token)
throws ProtocolException
getActivityEntries in interface ActivityStreamServiceuserId - The set of ids of the people to fetch activities for.groupId - Indicates whether to fetch activities for a group.appId - The app id.fields - The fields to return. Empty set implies alloptions - The sorting/filtering/pagination optionsactivityIds - The set of activity ids to fetch.token - A valid SecurityToken
ProtocolException - if any.
public <T> T filterFields(JSONObject object,
java.util.Set<java.lang.String> fields,
java.lang.Class<T> clz)
throws JSONException
JSONException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||