Class MockContentPropertyService
java.lang.Object
com.atlassian.integrationtest.confluence.api.service.content.MockContentPropertyService
- All Implemented Interfaces:
ContentPropertyService
A dummy
ContentPropertyService
for integration tests.
Just enough to start the other beans in implementationContext.xml. Needed because the real service is imported from confluence-content-property-storage plugin, and hence not available in integration tests.
See services/api/implementationContextPluginProvided.xml for more info.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.confluence.api.service.content.ContentPropertyService
ContentPropertyService.ContentPropertyFetcher, ContentPropertyService.ContentPropertyFinder, ContentPropertyService.ParameterContentPropertyFinder, ContentPropertyService.SingleContentPropertyFetcher, ContentPropertyService.Validator
-
Field Summary
Fields inherited from interface com.atlassian.confluence.api.service.content.ContentPropertyService
MAXIMUM_KEY_LENGTH, MAXIMUM_PROPERTIES_PER_PAGE_REQUEST, MAXIMUM_VALUE_LENGTH
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate
(JsonContentProperty newProperty) Create a content property.void
delete
(JsonContentProperty property) Removes a content property from the system.Create aContentPropertyService.ContentPropertyFinder
for locating content, the expansions will be applied to each property that matches the finder.update
(JsonContentProperty property) Updates a content property.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.confluence.api.service.content.ContentPropertyService
copyAllJsonContentProperties
-
Constructor Details
-
MockContentPropertyService
public MockContentPropertyService()
-
-
Method Details
-
create
Description copied from interface:ContentPropertyService
Create a content property.- Specified by:
create
in interfaceContentPropertyService
- Parameters:
newProperty
- the property to create- Returns:
- the property created
- Throws:
ServiceException
- if the property cannot be created
-
find
Description copied from interface:ContentPropertyService
Create aContentPropertyService.ContentPropertyFinder
for locating content, the expansions will be applied to each property that matches the finder. JsonContentProperty objects will be retrieved by using the fetch methods on the returned ContentPropertyFinder.- Specified by:
find
in interfaceContentPropertyService
- Parameters:
expansions
- properties to expand- Returns:
- the finder
-
update
Description copied from interface:ContentPropertyService
Updates a content property.- Specified by:
update
in interfaceContentPropertyService
- Parameters:
property
- the updatedJsonContentProperty
with metadata about the change- Returns:
- the updated content after being persisted
- Throws:
ServiceException
-
delete
Description copied from interface:ContentPropertyService
Removes a content property from the system.- Specified by:
delete
in interfaceContentPropertyService
- Parameters:
property
- the content property to remove- Throws:
ServiceException
- if the content property cannot be found, or cannot be deleted
-
validator
- Specified by:
validator
in interfaceContentPropertyService
- Returns:
- the validator view of the ContentPropertyService.
-