Interface ActivityStreamingService


@Exported public interface ActivityStreamingService
ActivityStreamingService is the main interface for the activity streaming functionality within WebCenter.
  • Method Details

    • publish

      void publish(ActivityElement activity) throws ActivityException
      Publish an activity
      Parameters:
      activity - the activity to be published
      Throws:
      ActivityException
    • publish

      void publish(List<ActivityElement> activities) throws ActivityException
      Publish list of activities
      Parameters:
      activities - the activities to be published
      Throws:
      ActivityException
    • retrieve

      List<ActivityDisplayElement> retrieve(String applicationID, QueryOptions queryOptions, FilterOptions filterOptions, DisplayOptions displayOptions) throws ActivityException
      Return activities that satisifes the passed in options
      Parameters:
      applicationID -
      queryOptions -
      filterOptions -
      displayOptions -
      Returns:
      the list of ActivityDisplayElement.
      Throws:
      ActivityException
    • retrieveSummaries

      List<ActivityDisplayElement> retrieveSummaries(String applicationID, QueryOptions queryOptions, FilterOptions filterOptions, SummaryDisplayOptions displayOptions) throws ActivityException
      Throws:
      ActivityException
    • createActor

      ActivityActor createActor(String userGUID) throws ActivityException
      Create a new Actor
      Parameters:
      userGUID - the user GUID
      Returns:
      a new Actor
      Throws:
      ActivityException
    • createActor

      ActivityActor createActor(String id, boolean isGroup) throws ActivityException
      Throws:
      ActivityException
    • createActorByName

      ActivityActor createActorByName(String userName) throws ActivityException
      Throws:
      ActivityException
    • createObject

      ActivityObject createObject(String objectID, oracle.webcenter.framework.service.ServiceObjectType objectType, String displayName) throws ActivityException
      Create a new Object
      Parameters:
      objectID - the ID of the object
      objectType - the type of the object
      Returns:
      a new Object
      Throws:
      ActivityException
    • createObject

      ActivityObject createObject(String objectID, String objectTypeID, String displayName) throws ActivityException
      Throws:
      ActivityException
    • createActivityElement

      ActivityElement createActivityElement(String applicationID, oracle.webcenter.framework.service.Scope scope, String serviceID, oracle.webcenter.framework.service.ActivityType activityType, List<? extends ActivityActor> actors, List<? extends ActivityObject> objects, ActivityPermission permission, Date activityTime) throws ActivityException
      Create a new ActivityStreamingElement
      Parameters:
      applicationID - application ID of the activity
      scope - the Scope of the activity
      serviceID - the service ID of the activity
      activityType - type of the activity
      actors - list of actors involved in the activity (there must be at least one actor in the activity)
      objects - list of objects involved in the activity (optional)
      permission - the permission of the activity
      activityTime - time when the activity happens
      Returns:
      a new ActivityElement
      Throws:
      ActivityException
    • createActivityElement

      ActivityElement createActivityElement(String applicationID, String scopeGUID, String serviceID, String activityTypeID, List<? extends ActivityActor> actors, List<? extends ActivityObject> objects, ActivityPermission permission, Date activityTime) throws ActivityException
      Throws:
      ActivityException
    • createCustAttr

      ActivityCustAttr createCustAttr(String name, String value, String url) throws ActivityException
      Create Custom Attribute
      Parameters:
      name - the name of the attribute
      value - the value of the attribute
      url - the url of the attribute
      Returns:
      a new Custom Attribute object
      Throws:
      ActivityException - if name or value is null
    • findActivityType

      oracle.webcenter.framework.service.ActivityType findActivityType(String serviceId, String typeName) throws ActivityException
      Return the definition for the specified activity type for the specified service.
      Parameters:
      serviceId - Service ID for which to look up object type
      typeName - Name of the activity type to look for
      Returns:
      The defintion for the specified activity type for the specified service, of null if none could be found.
      Throws:
      ActivityException - If any problem occurs looking up the activity type definition.
    • findObjectType

      oracle.webcenter.framework.service.ServiceObjectType findObjectType(String serviceId, String typeName) throws ActivityException
      Return the definition for the specified object type for the specified service.
      Parameters:
      serviceId - Service ID for which to look up object type
      typeName - Name of the object type to look for
      Returns:
      The defintion for the specified object type for the specified service, of null if none could be found.
      Throws:
      ActivityException - If any problem occurs looking up the object type definition.
    • getActivityServiceIds

      List<String> getActivityServiceIds()
      Return all service's IDs that have published activities to Activity Stream
      Returns:
      a list of service IDs
    • getActivityServiceIdPreferences

      List<String> getActivityServiceIdPreferences(String _strTaskflowInstanceID)
      Return all service's IDs that have are configured to be displayed in the current context.
      Parameters:
      _strTaskflowInstanceID - The ID of the current task flow. Optional.
      Returns:
      a list of service IDs. Null if there was an error.
    • createGenericActivityElement

      ActivityElement createGenericActivityElement(String applicationID, oracle.webcenter.framework.service.ActivityType activityType, List<? extends ActivityActor> actors, List<? extends ActivityObject> objects, ActivityPermission permission, Date activityTime) throws ActivityException
      Create a generic Activity Element. The service ID and scope of generic activity element will be defaulted to some constant values. NOT IMPLEMENTED YET
      Parameters:
      applicationID -
      activityType -
      actors -
      objects -
      permission -
      activityTime -
      Returns:
      the ActivityElement
      Throws:
      ActivityException
    • createQueryItem

      <T> QueryItem<T> createQueryItem(T value, List<ActivityPermission> permissions) throws ActivityException
      Create QueryItem. QueryItem is used to create QueryOptions. QueryItem is a bundle of any arbitrary value along with the associated permission.
      Type Parameters:
      T - any arbitrary type
      Parameters:
      value - the value of the QueryItem
      permissions - a list of permission
      Returns:
      the QueryItem.
      Throws:
      ActivityException
    • createEvalQueryOptions

      EvalQueryOptions createEvalQueryOptions(QueryOptions queryOptions) throws ActivityException
      Create EvalQueryOptions. This will be used by extension handler.
      Parameters:
      queryOptions -
      Returns:
      the EvalQueryOptions.
      Throws:
      ActivityException
    • createQueryOptions

      QueryOptions createQueryOptions(String profileUserGUID) throws ActivityException
      Create QueryOptions
      Parameters:
      profileUserGUID - the profile user whose activities to be displayed
      Returns:
      QueryOptions
      Throws:
      ActivityException
    • createFilterOptions

      FilterOptions createFilterOptions() throws ActivityException
      Create FilterOptions
      Returns:
      FilterOptions
      Throws:
      ActivityException
    • createServiceActivityType

      ServiceActivityType createServiceActivityType(String serviceId, oracle.webcenter.framework.service.ActivityType type) throws ActivityException
      Create ServiceActivityType
      Returns:
      ServiceActivityType
      Throws:
      ActivityException
    • createDisplayOptions

      DisplayOptions createDisplayOptions() throws ActivityException
      Create DisplayOptions
      Returns:
      the DisplayOptions
      Throws:
      ActivityException
    • createSummaryDisplayOptions

      SummaryDisplayOptions createSummaryDisplayOptions() throws ActivityException
      Create SummaryDisplayOptions
      Returns:
      the SummaryDisplayOptions
      Throws:
      ActivityException
    • publishAnalyticsEvent

      void publishAnalyticsEvent(ActivityElement activity) throws ActivityException
      Generates an analytics event for the given activity and publishes that event for collection by an analytics server.
      Parameters:
      activity - Activity Stream activity to generate analytics event for
      Throws:
      ActivityException - If any problem occurs generating an analytics event for the given activity or while publishing that event
    • teardown

      void teardown()
      Does cleanup for this service this is normally called from the app shutdown context listener.
    • getActorDetailsManager

      ActorDetailsManager getActorDetailsManager()
      Return activity stream data manager from the factory
      Returns:
      ActorDetailsManager Returns the instance of details manager
    • getObjectDetailsManager

      ObjectDetailsManager getObjectDetailsManager()
      Returns an object details manager instance for retrieving detail information about objects in WebCenter.
      Returns:
      An object details manager instance for retrieving detail information about objects in WebCenter.
    • getFollowManager

      FollowManager getFollowManager()
      Returns a follow manager instance for performing follow/unfollow on certain item and other follow-related actions
      Returns:
      A follow manager instance
    • getSecurityHandler

      SecurityHandler getSecurityHandler()
      Returns a security handler instance for checking objects security
      Returns:
      A security handler instance
    • isConfigured

      boolean isConfigured()
      Return whether activity stream service is configured
      Returns:
      whether activity stream service is configured
    • getArchiveManager

      oracle.webcenter.activitystreaming.ArchiveManager getArchiveManager()
      Return a archive manager instance for archiving/restoring acvitiy stream data
      Returns:
      a archive manager instance
    • getSettingsManager

      oracle.webcenter.activitystreaming.SettingsManager getSettingsManager()
      Return a settings manager instance for configure the activity stream admin settings
      Returns:
      a settings manager instance.
    • deleteActivities

      void deleteActivities(ActivityObject activityObject) throws ActivityException
      Mark all activites for the given object as delete
      Parameters:
      activityObject - the activity object whose activites to be marked as deleted
      Throws:
      ActivityException - If any problem occurs while remove activites.
    • deletePortalActivities

      void deletePortalActivities(String scopeGUID) throws ActivityException
      Delete all portal scoped activities for given portal scopeGUID.
      Parameters:
      scopeGUID - scopeGUID of portal for which activities has to be deleted
      Throws:
      ActivityException - If any problem occurs while deleting activites.
    • touchActivity

      void touchActivity(String activityId, Timestamp time) throws ActivityException
      Update an activity's timestamp to reflect recent activity
      Parameters:
      activityId - the id of the activity to update
      Throws:
      ActivityException - If any problem occurs
    • findActivity

      ActivityDisplayElement findActivity(QueryOptions queryOptions, String activityId) throws ActivityException
      Find and return the ActivityDisplayElement.
      Parameters:
      activityId - the id of the activity being retrieved.
      Returns:
      The ActivityDisplayElement.
      Throws:
      ActivityException - If any problem occurs.
    • getActivityScope

      oracle.webcenter.framework.service.Scope getActivityScope(ActivityObject object)
      Returns the Scope of the Activity associated with the passed activity object.
      Parameters:
      object - the Activity object
      Returns:
      Scope
    • canViewActivities

      boolean canViewActivities(oracle.webcenter.framework.service.Scope scope)
      Decides if the current user can view activities in the passed scope. If a user can view an activity, that means the user can: - See the Activity - Comment on the Activity - Get a summary of the Comments on the Activity - Like the Activity - Get a summary of the Likes on the Activity
      Parameters:
      scope - the passed Scope
      Returns:
      boolean
    • canModerateActivities

      boolean canModerateActivities(oracle.webcenter.framework.service.Scope scope)
      Decides if the current user can moderate activities in the passed scope. If a user can moderate an activity, that means the user can: - See the Activity - Comment on the Activity - Get a summary of the Comments on the Activity - Delete any Comments on the Activity - Like the Activity - Get a summary of the Likes on the Activity - Delete and Likes on the Activity
      Parameters:
      scope - the passed Scope
      Returns:
      boolean