|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
@ExperimentalApi public interface ContentService
Provides methods for creating, reading, updating and deleting Confluence Content objects such as
Pages, BlogPosts and Comments.
This interface provides no capability for searching content, use the SearchService instead.
| Method Summary | |
|---|---|
Content |
create(Content newContent)
Create a piece of content. |
void |
delete(Content content)
Removes an item of Content from the system. |
com.atlassian.fugue.Option<Content> |
find(ContentLocator locator,
Expansion... expansions)
Retrieve a piece of content by some more complex criteria (defined by the ContentLocator). |
com.atlassian.fugue.Option<Content> |
findById(java.lang.String contentId,
Expansion... expansions)
Retrieve a piece of content by its id. |
com.atlassian.fugue.Option<Macro> |
findMacro(java.lang.String contentId,
java.lang.String versionId,
java.lang.String hash,
Expansion... expansions)
Retrieve details about a macro matching the page, version and macro hash. |
Content |
update(Content content)
Updates a piece of content. |
ValidationResult |
validateCreate(Content newContent)
Validate that a piece of content can be included, including permission checks. |
ValidationResult |
validateDelete(Content content)
Validate that a piece of content can be deleted, including permission checks. |
| Method Detail |
|---|
com.atlassian.fugue.Option<Content> findById(java.lang.String contentId,
Expansion... expansions)
contentId - the id of the content you are looking for
com.atlassian.fugue.Option<Macro> findMacro(java.lang.String contentId,
java.lang.String versionId,
java.lang.String hash,
Expansion... expansions)
throws ServiceException
contentId - The content to scan for the macroversionId - The version of the page to scan for the macrohash - The hash identifying the body of the macro
ServiceException
com.atlassian.fugue.Option<Content> find(ContentLocator locator,
Expansion... expansions)
locator - the locator containing the criteria for the content you are looking for
ValidationResult validateCreate(Content newContent)
throws ServiceException
newContent - the content to be created
ServiceException
Content create(Content newContent)
throws ServiceException
Valid ContentRepresentations for the ContentBody can be found in the documentation on the
ContentBodyConversionService.
newContent - the content to create
ServiceException - if the content cannot be created
Content update(Content content)
throws ServiceException
Valid ContentRepresentations for the ContentBody can be found in the documentation on the
ContentBodyConversionService.
content - the updated Content with metadata about the change
ServiceExceptionValidationResult validateDelete(Content content)
content - the content to be deleted
void delete(Content content)
throws ServiceException
content - if of the content to remove
ServiceException - if the content cannot be found, or cannot be deleted
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||