public abstract class AttachmentEvent extends ContentEvent
source| Modifier | Constructor and Description |
|---|---|
protected |
AttachmentEvent(Object src,
Attachment attachment)
Convenience method.
|
protected |
AttachmentEvent(Object src,
Attachment attachment,
boolean suppressNotifications)
Convenience method.
|
protected |
AttachmentEvent(Object src,
List<Attachment> attachments)
Convenience method.
|
protected |
AttachmentEvent(Object src,
List<Attachment> attachments,
boolean suppressNotifications)
Constructs a multi-attachment event.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(@Nullable Object o)
Equals for ConfluenceEvents is defined such that specific sub-events are only equal to events of the same type.
|
@NonNull ContentEntityObject |
getAttachedTo() |
Attachment |
getAttachment()
Returns the real content (the first attachment of the list or null if there is none)
|
@NonNull List<Attachment> |
getAttachments() |
@NonNull ContentEntityObject |
getContent() |
int |
hashCode()
Subclasses must override this to hash their own fields.
|
isSuppressNotifications, setSuppressNotificationsgetSource, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetTimestampprotected AttachmentEvent(Object src, List<Attachment> attachments, boolean suppressNotifications)
src - the object publishing the eventattachments - the list of attachments that this event is aboutsuppressNotifications - whether or not to trigger notifications (e.g. emails to users watching the page)protected AttachmentEvent(Object src, List<Attachment> attachments)
new AttachmentEvent(src, attachments, false)protected AttachmentEvent(Object src, Attachment attachment)
new AttachmentEvent(src, Collections.singletonList(attachment), false)protected AttachmentEvent(Object src, Attachment attachment, boolean suppressNotifications)
new AttachmentEvent(src, Collections.singletonList(attachment), suppressNotifications)public @NonNull ContentEntityObject getContent()
public @NonNull ContentEntityObject getAttachedTo()
public Attachment getAttachment()
getAttachments()public @NonNull List<Attachment> getAttachments()
public boolean equals(@Nullable Object o)
ConfluenceEventSubclasses must override this to compare their own fields.
equals in class ContentEvento - the object to compare.Event.equals(Object)public int hashCode()
ConfluenceEventhashCode in class ContentEventEvent.hashCode()Copyright © 2003–2021 Atlassian. All rights reserved.