Interface Activity

All Superinterfaces:
ActivityPubObject
All Known Implementing Classes:
ActivityDefault

public interface Activity extends ActivityPubObject
An Activity is a subtype of ActivityPubObject that describes some form of action that may happen, is currently happening, or has already happened. The Activity type itself serves as an abstract base type for all types of activities. It is important to note that the Activity type itself does not carry any specific semantics about the kind of action being taken See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-activity
  • Method Details

    • getObject

      Set<org.apache.commons.rdf.api.IRI> getObject()
      Describes an object of any kind. The Object type serves as the base type for most of the other kinds of objects defined in the Activity Vocabulary, including other Core types such as Activity, IntransitiveActivity, Collection and OrderedCollection.
      Returns:
      The object of this Activity
    • setObject

      void setObject(Set<org.apache.commons.rdf.api.IRI> object)
      Describes an ActivityPubObject of any kind.
      Parameters:
      object - (s)
    • addObject

      void addObject(ActivityPubObject activityPubObject)
      Describes an ActivityPubObject of any kind.
      Parameters:
      activityPubObject -
    • setObjects

      void setObjects(Set<ActivityPubObject> activityPubObject)
      Describes an ActivityPubObject of any kind.
      Parameters:
      activityPubObject -
    • addObject

      void addObject(org.apache.commons.rdf.api.IRI object)
      Describes an ActivityPubObject of any kind.
      Parameters:
      object -
    • resolveObject

      Set<ActivityPubObject> resolveObject()
      Describes an ActivityPubObject of any kind.
      Returns:
      The object(s)
    • getActor

      Set<org.apache.commons.rdf.api.IRI> getActor()
      Describes one or more entities that either performed or are expected to perform the activity. Any single activity can have multiple actors.
      Returns:
      The actor id(s) of this Activity. See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-actor
    • activityType

      ActivityType activityType()
      Abstraction of the type of this activity, for convenience.
      Returns:
      Abstraction of the activity type.
    • is

      boolean is(ActivityType activityType)
      Parameters:
      activityType -
      Returns:
      True, if the activity has the passed type.
    • addActor

      void addActor(org.apache.commons.rdf.api.IRI actor)
      Describes one or more entities that either performed or are expected to perform the activity. Any single activity can have multiple actors. See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-actor
      Parameters:
      actor -
    • setActor

      void setActor(Set<org.apache.commons.rdf.api.IRI> actor)
      Describes one or more entities that either performed or are expected to perform the activity. Any single activity can have multiple actors. See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-actor
      Parameters:
      actor -
    • setTarget

      void setTarget(org.apache.commons.rdf.api.IRI target)
      Describes the indirect object, or target, of the activity. The precise meaning of the target is largely dependent on the type of action being described but will often be the object of the English preposition "to". For instance, in the activity "John added a movie to his wishlist", the target of the activity is John's wishlist. An activity can have more than one target. See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-target
      Parameters:
      target -
    • getTarget

      Optional<org.apache.commons.rdf.api.IRI> getTarget()
      Describes the indirect object, or target, of the activity. The precise meaning of the target is largely dependent on the type of action being described but will often be the object of the English preposition "to". For instance, in the activity "John added a movie to his wishlist", the target of the activity is John's wishlist. An activity can have more than one target. See Also: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-target
      Returns:
      The target's id.
    • setWasAssociatedWith

      void setWasAssociatedWith(org.apache.commons.rdf.api.IRI actor)
    • getWasAssociatedWith

      Optional<org.apache.commons.rdf.api.IRI> getWasAssociatedWith()
    • unify

      void unify()
      Ensures that audience, cc, bcc, to, bto are identical in activity and objects
    • replaceSubjectsWithInternals

      void replaceSubjectsWithInternals(SubjectProvider subjectProvider)
    • replaceSubjects

      void replaceSubjects(org.apache.commons.rdf.api.IRI actorsBaseSubject, SubjectProvider subjectProvider, boolean includingObjects)
    • replaceSubjects

      void replaceSubjects(org.apache.commons.rdf.api.IRI actorsBaseSubject, SubjectProvider subjectProvider)
    • replaceObject

      void replaceObject(ActivityPubObject existing)