@PublicApi
public interface ObjectFacade
Modifier and Type | Method and Description |
---|---|
AttachmentBean |
addAttachmentBean(int objectId,
File file,
String fileName,
String contentType,
String comment)
Add a
AttachmentBean domain objects. |
void |
archiveObjectBean(int id)
Archive an
ObjectBean by ID. |
void |
archiveObjectBean(int id,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Archive an
ObjectBean by ID with control over the event dispatch option. |
void |
archiveObjectBean(String objectKey)
Archive an
ObjectBean by object key. |
void |
archiveObjectBean(String objectKey,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Archive an
ObjectBean by object key with control over the event dispatch option. |
int |
countObjectBeans(int objectTypeId)
Finds total count of all
ObjectBean domain objects. |
WatcherBean |
createWatcherBean(int objectId,
String userKey)
Created a
WatcherBean |
AttachmentBean |
deleteAttachmentBean(int id)
Delete
AttachmentBean |
void |
deleteCommentBean(int commentBeanId)
Delete a
CommentBean |
void |
deleteObjectAttributeBean(int id)
Deprecated.
use the
deleteObjectAttributeBean(long) instead |
void |
deleteObjectAttributeBean(int id,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Deprecated.
use the
deleteObjectAttributeBean(long, EventDispatchOption) instead |
void |
deleteObjectAttributeBean(long id)
Deletes an object attribute bean
|
void |
deleteObjectAttributeBean(long id,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Deletes an object attribute bean
|
void |
deleteObjectBean(int id)
Delete a
ObjectBean |
void |
deleteObjectBean(int id,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Delete a
ObjectBean |
void |
deleteWatcherBean(WatcherBean watcherBean)
Delete a
WatcherBean |
List<AttachmentBean> |
findAttachmentBeans(int objectId)
Finds attachmentBeans for specified
ObjectBean id |
List<CommentBean> |
findCommentBeans(int objectId)
Find all
CommentBean for an ObjectBean |
List<ObjectAttributeBean> |
findObjectAttributeBeans(int objectId)
Finds all
ObjectAttributeBean |
List<ObjectHistoryBean> |
findObjectHistoryBean(int objectId)
Find the
ObjectBean history |
List<ObjectTicketConnectionEntry> |
findObjectTicketConnections(int objectId)
Find all JIRA issues connected to an
ObjectBean |
List<ObjectTicketConnectionEntry> |
findObjectTicketConnections(int objectId,
int offset,
int limit)
Deprecated.
use
findObjectTicketConnections(int) instead |
List<ObjectTicketConnectionEntry> |
findObjectTicketConnections(long ticketId)
Find all ObjectBean connected to a JIRA issue
|
List<WatcherBean> |
findWatcherBeans(int objectId)
Finds all
WatcherBean for an ObjectBean |
AttachmentBean |
loadAttachmentBeanById(int id)
Load a
AttachmentBean |
CommentBean |
loadCommentBean(int commentId)
Load a
CommentBean |
ObjectAttributeBean |
loadObjectAttributeBean(int id)
Deprecated.
Go through the object to load the object attribute bean instead of directly. This will be removed in
future releases
|
ObjectAttributeBean |
loadObjectAttributeBean(int objectId,
int objectTypeAttributeId)
Loads a
ObjectAttributeBean given an object id and object type attribute id |
ObjectAttributeBean |
loadObjectAttributeBean(int objectId,
int objectTypeAttributeId,
boolean ignorePermissionCheck)
Loads a
ObjectAttributeBean given an object id, object type attribute id and a parameter to ignore permission check |
ObjectAttributeBean |
loadObjectAttributeBean(int objectId,
String objectTypeAttributeName)
Loads a
ObjectAttributeBean given an object id and object type attribute name |
ObjectBean |
loadObjectBean(int id)
Loads a
ObjectBean given its id. |
ObjectBean |
loadObjectBean(String key)
Loads a
ObjectBean given its key. |
WatcherBean |
loadWatcherBean(int objectId,
String userKey)
Loads a
WatcherBean |
Progress |
moveObjects(MoveObjectBean moveObjectBean)
Move objects to another object type
|
void |
restoreObjectBean(int id)
Restore an
ObjectBean by ID. |
void |
restoreObjectBean(int id,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Restore an
ObjectBean by ID with control over the event dispatch option. |
void |
restoreObjectBean(String objectKey)
Restore an
ObjectBean by object key. |
void |
restoreObjectBean(String objectKey,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Restore an
ObjectBean by object key with control over the event dispatch option. |
CommentBean |
storeCommentBean(CommentBean commentBean)
Store a
CommentBean |
ObjectAttributeBean |
storeObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean)
Stores a
ObjectAttributeBean |
ObjectAttributeBean |
storeObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Stores a
ObjectAttributeBean |
ObjectAttributeBean |
storeObjectAttributeBean(ObjectAttributeBean objectAttributeBean)
Deprecated.
|
ObjectBean |
storeObjectBean(MutableObjectBean objectBean)
Stores a
ObjectBean |
ObjectBean |
storeObjectBean(MutableObjectBean objectBean,
byte[] avatarData,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Stores a
ObjectBean with the corresponding avatar |
ObjectBean |
storeObjectBean(MutableObjectBean objectBean,
com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption)
Stores a
ObjectBean |
ObjectBean |
storeObjectBeanIgnoreAttributeValidation(MutableObjectBean objectBean)
Stores a
ObjectBean bypassing ALL attribute validation e.g. |
void |
validateObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean,
ObjectBean objectBean)
Validate an object attribute bean.
|
void |
validateObjectBean(MutableObjectBean objectBean)
Validate an object bean.
|
ObjectBean storeObjectBean(MutableObjectBean objectBean, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
objectBean
- the object bean to storeeventDispatchOption
- event dispatchObjectBean
InsightException
- if something goes wrongObjectBean storeObjectBean(@Nonnull MutableObjectBean objectBean, @Nonnull byte[] avatarData, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
with the corresponding avatarobjectBean
- an existing object bean, the object bean must exist and be stored in insight before added as a
parameter to this methodavatarData
- the actual avatar data to be used for the objecteventDispatchOption
- event dispatchObjectBean
InsightException
- if something goesObjectBean storeObjectBean(MutableObjectBean objectBean) throws InsightException
ObjectBean
objectBean
- the object bean to storeObjectBean
InsightException
- if something goes wrongObjectBean storeObjectBeanIgnoreAttributeValidation(MutableObjectBean objectBean) throws InsightException
ObjectBean
bypassing ALL attribute validation e.g. uniqueness. This method should be used with
care because it will create objects that potentially does not conform to the configuration of the object type.objectBean
- the object bean with corresponding attributes. Attributes present will NOT be validatedInsightException
ObjectAttributeBean storeObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean) throws InsightException
ObjectAttributeBean
ObjectAttributeBean
InsightException
- if something goes wrongObjectAttributeBean storeObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectAttributeBean
ObjectAttributeBean
InsightException
- if something goes wrong@Deprecated ObjectAttributeBean storeObjectAttributeBean(ObjectAttributeBean objectAttributeBean) throws InsightException
InsightException
int countObjectBeans(int objectTypeId) throws InsightException
ObjectBean
domain objects.InsightException
ObjectBean loadObjectBean(int id) throws InsightException
ObjectBean
given its id.ObjectBean
InsightException
ObjectBean loadObjectBean(String key) throws InsightException
ObjectBean
given its key.ObjectBean
InsightException
void deleteObjectBean(int id) throws InsightException
ObjectBean
InsightException
void deleteObjectBean(int id, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
InsightException
void archiveObjectBean(int id) throws InsightException
ObjectBean
by ID.id
- the id of the object to archiveInsightException
void archiveObjectBean(int id, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
by ID with control over the event dispatch option.id
- the id of the object to archiveeventDispatchOption
- event dispatch optionInsightException
void archiveObjectBean(String objectKey) throws InsightException
ObjectBean
by object key.objectKey
- the key of the object to archiveInsightException
void archiveObjectBean(String objectKey, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
by object key with control over the event dispatch option.objectKey
- the key of the object to archiveeventDispatchOption
- event dispatch optionInsightException
void restoreObjectBean(int id) throws InsightException
ObjectBean
by ID.id
- the id of the object to restoreInsightException
void restoreObjectBean(int id, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
by ID with control over the event dispatch option.id
- the id of the object to restoreeventDispatchOption
- event dispatch optionInsightException
void restoreObjectBean(String objectKey) throws InsightException
ObjectBean
by object key.objectKey
- the key of the object to restoreInsightException
void restoreObjectBean(String objectKey, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
ObjectBean
by object key with control over the event dispatch option.objectKey
- the key of the object to restoreeventDispatchOption
- event dispatch optionInsightException
List<ObjectAttributeBean> findObjectAttributeBeans(int objectId) throws InsightException
ObjectAttributeBean
objectId
- the ObjectBean
idObjectAttributeBean
InsightException
@Deprecated ObjectAttributeBean loadObjectAttributeBean(int id) throws InsightException
ObjectAttributeBean
given its id.ObjectAttributeBean
InsightException
@Deprecated void deleteObjectAttributeBean(int id) throws InsightException
deleteObjectAttributeBean(long)
insteadInsightException
@Deprecated void deleteObjectAttributeBean(int id, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
deleteObjectAttributeBean(long, EventDispatchOption)
insteadInsightException
void deleteObjectAttributeBean(long id) throws InsightException
InsightException
void deleteObjectAttributeBean(long id, @Nonnull com.riadalabs.jira.plugins.insight.services.events.EventDispatchOption eventDispatchOption) throws InsightException
InsightException
ObjectAttributeBean loadObjectAttributeBean(int objectId, int objectTypeAttributeId) throws InsightException
ObjectAttributeBean
given an object id and object type attribute idObjectAttributeBean
InsightException
ObjectAttributeBean loadObjectAttributeBean(int objectId, int objectTypeAttributeId, boolean ignorePermissionCheck) throws InsightException
ObjectAttributeBean
given an object id, object type attribute id and a parameter to ignore permission checkObjectAttributeBean
InsightException
ObjectAttributeBean loadObjectAttributeBean(int objectId, String objectTypeAttributeName) throws InsightException
ObjectAttributeBean
given an object id and object type attribute nameObjectAttributeBean
InsightException
List<ObjectHistoryBean> findObjectHistoryBean(int objectId) throws InsightException
ObjectBean
historyObjectHistoryBean
InsightException
AttachmentBean loadAttachmentBeanById(int id) throws InsightException
AttachmentBean
AttachmentBean
InsightException
AttachmentBean addAttachmentBean(int objectId, File file, String fileName, String contentType, String comment) throws InsightException
AttachmentBean
domain objects.objectId
- the ObjectBean
idfile
- the file to addfileName
- the filenamecontentType
- the content typecomment
- an optional commentAttachmentBean
InsightException
List<AttachmentBean> findAttachmentBeans(int objectId) throws InsightException
ObjectBean
idobjectId
- the ObjectBean idAttachmentBean
InsightException
AttachmentBean deleteAttachmentBean(int id) throws InsightException
AttachmentBean
AttachmentBean
InsightException
List<ObjectTicketConnectionEntry> findObjectTicketConnections(int objectId) throws InsightException
ObjectBean
ObjectTicketConnectionEntry
InsightException
@Deprecated List<ObjectTicketConnectionEntry> findObjectTicketConnections(int objectId, int offset, int limit) throws InsightException
findObjectTicketConnections(int)
insteadInsightException
List<ObjectTicketConnectionEntry> findObjectTicketConnections(long ticketId) throws InsightException
ObjectTicketConnectionEntry
InsightException
void deleteCommentBean(int commentBeanId) throws InsightException
CommentBean
InsightException
CommentBean storeCommentBean(CommentBean commentBean) throws InsightException
CommentBean
CommentBean
InsightException
List<CommentBean> findCommentBeans(int objectId) throws InsightException
CommentBean
for an ObjectBean
CommentBean
InsightException
CommentBean loadCommentBean(int commentId) throws InsightException
CommentBean
CommentBean
InsightException
WatcherBean loadWatcherBean(int objectId, String userKey) throws InsightException
WatcherBean
objectId
- the ObjectBean iduserKey
- the User keyWatcherBean
InsightException
List<WatcherBean> findWatcherBeans(int objectId) throws InsightException
WatcherBean
for an ObjectBean
WatcherBean
InsightException
WatcherBean createWatcherBean(int objectId, String userKey) throws InsightException
WatcherBean
objectId
- the ObjectBean
iduserKey
- the userkeyWatcherBean
InsightException
void deleteWatcherBean(WatcherBean watcherBean) throws InsightException
WatcherBean
InsightException
Progress moveObjects(MoveObjectBean moveObjectBean) throws Exception
void validateObjectBean(MutableObjectBean objectBean) throws ValidationInsightException, IQLValidationException
void validateObjectAttributeBean(MutableObjectAttributeBean objectAttributeBean, ObjectBean objectBean) throws ValidationInsightException, IQLValidationException
Copyright © 2024 Atlassian. All rights reserved.