Class TeamEvent

java.lang.Object
com.dropbox.core.v2.teamlog.TeamEvent

public class TeamEvent extends Object
An audit log event.
  • Field Details

    • timestamp

      @Nonnull protected final Date timestamp
    • eventCategory

      @Nonnull protected final EventCategory eventCategory
    • actor

      @Nullable protected final ActorLogInfo actor
    • origin

      @Nullable protected final OriginLogInfo origin
    • involveNonTeamMember

      @Nullable protected final Boolean involveNonTeamMember
    • context

      @Nullable protected final ContextLogInfo context
    • participants

      @Nullable protected final List<ParticipantLogInfo> participants
    • assets

      @Nullable protected final List<AssetLogInfo> assets
    • eventType

      @Nonnull protected final EventType eventType
    • details

      @Nonnull protected final EventDetails details
  • Constructor Details

    • TeamEvent

      public TeamEvent(@Nonnull Date timestamp, @Nonnull EventCategory eventCategory, @Nonnull EventType eventType, @Nonnull EventDetails details, @Nullable ActorLogInfo actor, @Nullable OriginLogInfo origin, @Nullable Boolean involveNonTeamMember, @Nullable ContextLogInfo context, @Nullable List<ParticipantLogInfo> participants, @Nullable List<AssetLogInfo> assets)
      An audit log event.

      Use newBuilder(java.util.Date,com.dropbox.core.v2.teamlog.EventCategory,com.dropbox.core.v2.teamlog.EventType,com.dropbox.core.v2.teamlog.EventDetails) to create instances of this class without specifying values for all optional fields.

      Parameters:
      timestamp - The Dropbox timestamp representing when the action was taken. Must not be null.
      eventCategory - The category that this type of action belongs to. Must not be null.
      eventType - The particular type of action taken. Must not be null.
      details - The variable event schema applicable to this type of action, instantiated with respect to this particular action. Must not be null.
      actor - The entity who actually performed the action.
      origin - The origin from which the actor performed the action including information about host, ip address, location, session, etc. If the action was performed programmatically via the API the origin represents the API client.
      involveNonTeamMember - True if the action involved a non team member either as the actor or as one of the affected users.
      context - The user or team on whose behalf the actor performed the action.
      participants - Zero or more users and/or groups that are affected by the action. Note that this list doesn't include any actors or users in context. Must not contain a null item.
      assets - Zero or more content assets involved in the action. Currently these include Dropbox files and folders but in the future we might add other asset types such as Paper documents, folders, projects, etc. Must not contain a null item.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
    • TeamEvent

      public TeamEvent(@Nonnull Date timestamp, @Nonnull EventCategory eventCategory, @Nonnull EventType eventType, @Nonnull EventDetails details)
      An audit log event.

      The default values for unset fields will be used.

      Parameters:
      timestamp - The Dropbox timestamp representing when the action was taken. Must not be null.
      eventCategory - The category that this type of action belongs to. Must not be null.
      eventType - The particular type of action taken. Must not be null.
      details - The variable event schema applicable to this type of action, instantiated with respect to this particular action. Must not be null.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
  • Method Details

    • getTimestamp

      @Nonnull public Date getTimestamp()
      The Dropbox timestamp representing when the action was taken.
      Returns:
      value for this field, never null.
    • getEventCategory

      @Nonnull public EventCategory getEventCategory()
      The category that this type of action belongs to.
      Returns:
      value for this field, never null.
    • getEventType

      @Nonnull public EventType getEventType()
      The particular type of action taken.
      Returns:
      value for this field, never null.
    • getDetails

      @Nonnull public EventDetails getDetails()
      The variable event schema applicable to this type of action, instantiated with respect to this particular action.
      Returns:
      value for this field, never null.
    • getActor

      @Nullable public ActorLogInfo getActor()
      The entity who actually performed the action.
      Returns:
      value for this field, or null if not present.
    • getOrigin

      @Nullable public OriginLogInfo getOrigin()
      The origin from which the actor performed the action including information about host, ip address, location, session, etc. If the action was performed programmatically via the API the origin represents the API client.
      Returns:
      value for this field, or null if not present.
    • getInvolveNonTeamMember

      @Nullable public Boolean getInvolveNonTeamMember()
      True if the action involved a non team member either as the actor or as one of the affected users.
      Returns:
      value for this field, or null if not present.
    • getContext

      @Nullable public ContextLogInfo getContext()
      The user or team on whose behalf the actor performed the action.
      Returns:
      value for this field, or null if not present.
    • getParticipants

      @Nullable public List<ParticipantLogInfo> getParticipants()
      Zero or more users and/or groups that are affected by the action. Note that this list doesn't include any actors or users in context.
      Returns:
      value for this field, or null if not present.
    • getAssets

      @Nullable public List<AssetLogInfo> getAssets()
      Zero or more content assets involved in the action. Currently these include Dropbox files and folders but in the future we might add other asset types such as Paper documents, folders, projects, etc.
      Returns:
      value for this field, or null if not present.
    • newBuilder

      public static TeamEvent.Builder newBuilder(Date timestamp, EventCategory eventCategory, EventType eventType, EventDetails details)
      Returns a new builder for creating an instance of this class.
      Parameters:
      timestamp - The Dropbox timestamp representing when the action was taken. Must not be null.
      eventCategory - The category that this type of action belongs to. Must not be null.
      eventType - The particular type of action taken. Must not be null.
      details - The variable event schema applicable to this type of action, instantiated with respect to this particular action. Must not be null.
      Returns:
      builder for this class.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toStringMultiline

      public String toStringMultiline()
      Returns a String representation of this object formatted for easier readability.

      The returned String may contain newlines.

      Returns:
      Formatted, multiline String representation of this object