public class PageContentTypeApiSupport extends BaseContentTypeApiSupport<Page>
Page
s for the API.Constructor and Description |
---|
PageContentTypeApiSupport(ContentFactory contentFactory,
PageManagerInternal pageManager,
PaginationService paginationService,
ApiSupportProvider apiSupportProvider,
ContentCreator contentCreator) |
Modifier and Type | Method and Description |
---|---|
Page |
create(Content newContent)
Create a new persistent entity for the given api content
|
protected PageResponse<Content> |
getChildrenForThisType(Page content,
LimitedRequest limitedRequest,
Expansions expansions,
Depth depth) |
protected PageResponse<Content> |
getChildrenOfThisTypeForOtherType(ContentConvertible otherTypeParent,
LimitedRequest limitedRequest,
Expansions expansions,
Depth depth) |
Class<Page> |
getEntityClass()
Get the class of the hibernate object used to persist the content type handled by this api support
|
Map<ContentId,Map<String,Object>> |
getExtensions(Iterable<Page> pages,
Expansions expansions)
Get the set of extension properties for the collection of contentEntity Ids.
|
ContentType |
getHandledType() |
boolean |
supportsChildrenForParentType(ContentType parentType) |
boolean |
supportsChildrenOfType(ContentType parentType)
A check that to allow other ContentTypeApiSupports to provide children for this type
|
Page |
update(Content updatedContent,
Page page)
Updates an existing persistent entity from the given api content
|
ValidationResult |
validateCreate(Content newContent)
Validate the create operation
|
ValidationResult |
validateUpdate(Content updatedContent,
Page sceo)
Validate the update operation
|
getChildren, getChildrenForThisType, getChildrenOfThisTypeForOtherType, getContainer, getLinks
public PageContentTypeApiSupport(ContentFactory contentFactory, PageManagerInternal pageManager, PaginationService paginationService, ApiSupportProvider apiSupportProvider, ContentCreator contentCreator)
public ContentType getHandledType()
ContentType
of the Content
that this service provides.protected PageResponse<Content> getChildrenForThisType(Page content, LimitedRequest limitedRequest, Expansions expansions, Depth depth)
getChildrenForThisType
in class BaseContentTypeApiSupport<Page>
public boolean supportsChildrenOfType(ContentType parentType)
BaseContentTypeApiSupport
supportsChildrenOfType
in interface ContentTypeApiSupport<Page>
supportsChildrenOfType
in class BaseContentTypeApiSupport<Page>
parentType
- - the other Content type that wants to offer children of our typeprotected PageResponse<Content> getChildrenOfThisTypeForOtherType(ContentConvertible otherTypeParent, LimitedRequest limitedRequest, Expansions expansions, Depth depth)
getChildrenOfThisTypeForOtherType
in class BaseContentTypeApiSupport<Page>
public boolean supportsChildrenForParentType(ContentType parentType)
supportsChildrenForParentType
in interface ContentTypeApiSupport<Page>
supportsChildrenForParentType
in class BaseContentTypeApiSupport<Page>
Content
of this binding's ContentType
can be a child of contentEntity of the given typepublic Class<Page> getEntityClass()
ContentTypeApiSupport
public Map<ContentId,Map<String,Object>> getExtensions(Iterable<Page> pages, Expansions expansions)
BaseContentTypeApiSupport
getExtensions
in interface ContentTypeApiSupport<Page>
getExtensions
in class BaseContentTypeApiSupport<Page>
public ValidationResult validateCreate(Content newContent)
ContentTypeApiSupport
validateCreate
in interface ContentTypeApiSupport<Page>
validateCreate
in class BaseContentTypeApiSupport<Page>
newContent
- the content that will be used to create an entitypublic ValidationResult validateUpdate(Content updatedContent, Page sceo)
ContentTypeApiSupport
validateUpdate
in interface ContentTypeApiSupport<Page>
validateUpdate
in class BaseContentTypeApiSupport<Page>
updatedContent
- the content that will be used to update the entitysceo
- the existing entity to be updatedpublic Page create(Content newContent)
ContentTypeApiSupport
create
in interface ContentTypeApiSupport<Page>
create
in class BaseContentTypeApiSupport<Page>
newContent
- the model object to create a persistent entity forpublic Page update(Content updatedContent, Page page)
ContentTypeApiSupport
update
in interface ContentTypeApiSupport<Page>
update
in class BaseContentTypeApiSupport<Page>
updatedContent
- the updated contentpage
- the existing entityCopyright © 2003–2015 Atlassian. All rights reserved.