|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.confluence.rest.client.AbstractRemoteService<AttachmentService>
com.atlassian.confluence.rest.client.RemoteAttachmentServiceImpl
public class RemoteAttachmentServiceImpl
AttachmentService implementation that communicates with Confluence remotely using the Confluence REST api
| Constructor Summary | |
|---|---|
RemoteAttachmentServiceImpl(AuthenticatedWebResourceProvider provider,
com.google.common.util.concurrent.ListeningExecutorService executor)
|
|
| Method Summary | |
|---|---|
java.util.concurrent.Future<PageResponse<Content>> |
addAttachments(ContentId contentId,
java.util.Collection<AttachmentUpload> uploads)
Add one or more attachments to a piece of Content. |
java.util.concurrent.Future<java.lang.Boolean> |
canCreateAttachments(ContentId contentId)
Checks if the user is permitted to add attachments to the given content |
java.util.concurrent.Future<com.atlassian.fugue.Option<Content>> |
findByContainerAndFilename(ContentId containerId,
java.lang.String filename,
Expansion... expansions)
Locates a single Attachment given the id of its container Content and its file name. |
java.util.concurrent.Future<PageResponse<Content>> |
getAttachments(ContentId contentId,
PageRequest pageRequest,
AttachmentFilter filter,
Expansion... expansions)
Get a page of attachments under the Content with the specified id. |
java.util.concurrent.Future<Content> |
updateData(ContentId attachmentId,
AttachmentUpload upload)
Updates the data part of an Attachment Content instance. |
| Methods inherited from class com.atlassian.confluence.rest.client.AbstractRemoteService |
|---|
addExpansions, addPageRequest, addPageRequestParams, deleteFuture, getFutureGenericCollection, getFutureMapOfPageResponses, getFutureOption, getFuturePageResponseList, newRestWebResource, postFuture, postFuture, postFuture, postFutureToPageResponse, putFuture |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RemoteAttachmentServiceImpl(AuthenticatedWebResourceProvider provider,
com.google.common.util.concurrent.ListeningExecutorService executor)
| Method Detail |
|---|
public java.util.concurrent.Future<PageResponse<Content>> addAttachments(ContentId contentId,
java.util.Collection<AttachmentUpload> uploads)
throws ServiceException
RemoteAttachmentServiceContent.
addAttachments in interface RemoteAttachmentServicecontentId - the id of the content to attach touploads - the attachments being uploaded
ServiceExceptionpublic java.util.concurrent.Future<java.lang.Boolean> canCreateAttachments(ContentId contentId)
RemoteAttachmentService
canCreateAttachments in interface RemoteAttachmentServicecontentId - the id of the content to attach to
public java.util.concurrent.Future<PageResponse<Content>> getAttachments(ContentId contentId,
PageRequest pageRequest,
AttachmentFilter filter,
Expansion... expansions)
throws ServiceException
RemoteAttachmentServiceContent with the specified id.
getAttachments in interface RemoteAttachmentServicecontentId - id of the Content that contains the attachments.pageRequest - - a pageRequest indicating how much content to retrieve.filter - - a filter to apply to the found Attachmentsexpansions - the expansions to apply to each Attachment in the returned page
ServiceException
public java.util.concurrent.Future<com.atlassian.fugue.Option<Content>> findByContainerAndFilename(ContentId containerId,
java.lang.String filename,
Expansion... expansions)
throws ServiceException
RemoteAttachmentService
findByContainerAndFilename in interface RemoteAttachmentServicecontainerId - the id of the content containing the attachmentfilename - the name of the attachment fileexpansions - expansions to return on the Attachment content
ServiceException
public java.util.concurrent.Future<Content> updateData(ContentId attachmentId,
AttachmentUpload upload)
throws ServiceException
RemoteAttachmentServiceContent instance.
updateData in interface RemoteAttachmentServiceattachmentId - the id of the attachment to updateupload - the new content of the Attachment
ServiceException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||