Class DefaultBlogPostService
- java.lang.Object
-
- com.atlassian.confluence.content.service.DefaultBlogPostService
-
- All Implemented Interfaces:
BlogPostService
public class DefaultBlogPostService extends Object implements BlogPostService
-
-
Constructor Summary
Constructors Constructor Description DefaultBlogPostService(PageManager pageManager, PermissionManager permissionManager, ContentPermissionManager contentPermissionManager, SpacePermissionManager spacePermissionManager, DraftService draftService, AttachmentManager attachmentManager, NotificationManager notificationManager, com.atlassian.event.api.EventPublisher eventPublisher, ContentPropertyManager contentPropertyManager, LabelManager labelManager, com.google.common.base.Supplier<DraftsTransitionHelper> draftsTransitionHelperSupplier)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description DraftsTransitionHelper
getDraftsTransitionHelper()
BlogPostLocator
getIdBlogPostLocator(long pageId)
Creates a blogpost locator that can locate a blogpost based on its id.ServiceCommand
newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, ContentEntityObject draft, com.atlassian.user.User user, boolean notifySelf)
Deprecated.ServiceCommand
newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, BlogPost draft, com.atlassian.user.User user, boolean notifySelf)
ServiceCommand
newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, Draft draft, com.atlassian.user.User user, boolean notifySelf)
Deprecated.ServiceCommand
newDeleteBlogPostCommand(BlogPostLocator blogPostLocator)
Retrieve a command to remove an existing blog postServiceCommand
newMoveBlogPostCommand(BlogPostLocator blogPostLocator, SpaceLocator targetSpaceLocator)
Creates a newServiceCommand
for moving an existingBlogPost
.ServiceCommand
newRemoveBlogPostVersionCommand(BlogPostLocator blogPostLocator)
ServiceCommand
newRevertBlogPostCommand(BlogPostLocator blogPostToRevert, int version, String revertComment, boolean revertTitle)
Retrieve a command to revert a blogpostvoid
setPermissionManager(PermissionManager permissionManager)
-
-
-
Constructor Detail
-
DefaultBlogPostService
public DefaultBlogPostService(PageManager pageManager, PermissionManager permissionManager, ContentPermissionManager contentPermissionManager, SpacePermissionManager spacePermissionManager, DraftService draftService, AttachmentManager attachmentManager, NotificationManager notificationManager, com.atlassian.event.api.EventPublisher eventPublisher, ContentPropertyManager contentPropertyManager, LabelManager labelManager, com.google.common.base.Supplier<DraftsTransitionHelper> draftsTransitionHelperSupplier)
-
-
Method Detail
-
newDeleteBlogPostCommand
public ServiceCommand newDeleteBlogPostCommand(BlogPostLocator blogPostLocator)
Description copied from interface:BlogPostService
Retrieve a command to remove an existing blog post- Specified by:
newDeleteBlogPostCommand
in interfaceBlogPostService
-
getIdBlogPostLocator
public BlogPostLocator getIdBlogPostLocator(long pageId)
Description copied from interface:BlogPostService
Creates a blogpost locator that can locate a blogpost based on its id.- Specified by:
getIdBlogPostLocator
in interfaceBlogPostService
-
newRevertBlogPostCommand
public ServiceCommand newRevertBlogPostCommand(BlogPostLocator blogPostToRevert, int version, String revertComment, boolean revertTitle)
Description copied from interface:BlogPostService
Retrieve a command to revert a blogpost- Specified by:
newRevertBlogPostCommand
in interfaceBlogPostService
-
newCreateBlogPostCommand
public ServiceCommand newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, BlogPost draft, com.atlassian.user.User user, boolean notifySelf)
- Specified by:
newCreateBlogPostCommand
in interfaceBlogPostService
- Parameters:
provider
- an object that can provide a BlogPost to the commandpermissionProvider
- an object that can provide the permissions for the blog postcontextProvider
- an object that can provide a context to be included when publishing the blog post creation eventuser
- the user creating this blog post or null if the anonymous usernotifySelf
- a flag indicating whether the user themselves should be notified about this creation.- Returns:
- the CreateBlogPostCommand.
-
newCreateBlogPostCommand
@Deprecated public ServiceCommand newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, ContentEntityObject draft, com.atlassian.user.User user, boolean notifySelf)
Deprecated.- Specified by:
newCreateBlogPostCommand
in interfaceBlogPostService
- Parameters:
provider
- an object that can provide a BlogPost to the commandpermissionProvider
- an object that can provide the permissions for the blog postcontextProvider
- an object that can provide a context to be included when publishing the blog post creation eventuser
- the user creating this blog post or null if the anonymous usernotifySelf
- a flag indicating whether the user themselves should be notified about this creation.- Returns:
- the CreateBlogPostCommand.
-
newCreateBlogPostCommand
@Deprecated public ServiceCommand newCreateBlogPostCommand(BlogPostProvider provider, ContentPermissionProvider permissionProvider, CreateContextProvider contextProvider, Draft draft, com.atlassian.user.User user, boolean notifySelf)
Deprecated.- Specified by:
newCreateBlogPostCommand
in interfaceBlogPostService
- Parameters:
provider
- an object that can provide a BlogPost to the commandpermissionProvider
- an object that can provide the permissions for the blog postcontextProvider
- an object that can provide a context to be included when publishing the blog post creation eventuser
- the user creating this blog post or null if the anonymous usernotifySelf
- a flag indicating whether the user themselves should be notified about this creation.- Returns:
- the CreateBlogPostCommand.
-
newMoveBlogPostCommand
public ServiceCommand newMoveBlogPostCommand(BlogPostLocator blogPostLocator, SpaceLocator targetSpaceLocator)
Description copied from interface:BlogPostService
Creates a newServiceCommand
for moving an existingBlogPost
.- Specified by:
newMoveBlogPostCommand
in interfaceBlogPostService
- Parameters:
blogPostLocator
- provides the BlogPost to the commandtargetSpaceLocator
- provides the target space to the command
-
newRemoveBlogPostVersionCommand
public ServiceCommand newRemoveBlogPostVersionCommand(BlogPostLocator blogPostLocator)
- Specified by:
newRemoveBlogPostVersionCommand
in interfaceBlogPostService
- Parameters:
blogPostLocator
- provides the BlogPost version to the command- Returns:
- a command to remove a version of a blog post.
-
setPermissionManager
public void setPermissionManager(PermissionManager permissionManager)
-
getDraftsTransitionHelper
public DraftsTransitionHelper getDraftsTransitionHelper()
-
-