Package com.atlassian.confluence.core
Class DefaultSaveContext
- java.lang.Object
-
- com.atlassian.confluence.core.AbstractOperationContext<PageUpdateTrigger>
-
- com.atlassian.confluence.core.DefaultSaveContext
-
- All Implemented Interfaces:
OperationContext<PageUpdateTrigger>,SaveContext,Serializable
@ParametersAreNonnullByDefault public class DefaultSaveContext extends AbstractOperationContext<PageUpdateTrigger> implements SaveContext
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDefaultSaveContext.Builder-
Nested classes/interfaces inherited from class com.atlassian.confluence.core.AbstractOperationContext
AbstractOperationContext.BaseBuilder<T extends AbstractOperationContext.BaseBuilder,TRIGGER extends OperationTrigger>
-
-
Field Summary
Fields Modifier and Type Field Description static SaveContextBULK_OPERATIONstatic SaveContextDEFAULTstatic SaveContextDRAFTstatic SaveContextDRAFT_REFACTORINGstatic SaveContextMINOR_EDITstatic SaveContextRAW_DRAFTstatic SaveContextREFACTORINGstatic SaveContextREVERTstatic SaveContextSUPPRESS_NOTIFICATIONS-
Fields inherited from class com.atlassian.confluence.core.AbstractOperationContext
suppressNotifications
-
-
Constructor Summary
Constructors Constructor Description DefaultSaveContext(boolean suppressNotifications, boolean updateLastModifier, boolean suppressEvents)Deprecated.since 6.0.DefaultSaveContext(boolean suppressNotifications, boolean updateLastModifier, boolean suppressEvents, PageUpdateTrigger updateTrigger)Deprecated.since 6.0.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static DefaultSaveContext.Builderbuilder()booleandoUpdateLastModifier()UpdateLastModifier indicates whether to update the LastModifier field when saving a page.booleanequals(Object o)inthashCode()booleanisSuppressAutowatch()Control whether the save should result in the page being watched by the creator if they have their autowatch setting on.voidsetSuppressNotifications(boolean suppressNotifications)Deprecated.since 6.0.voidsetUpdateLastModifier(boolean updateLastModifier)Deprecated.since 6.0.-
Methods inherited from class com.atlassian.confluence.core.AbstractOperationContext
getUpdateTrigger, isEventSuppressed, isSuppressNotifications
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.confluence.core.OperationContext
getUpdateTrigger, isEventSuppressed, isSuppressNotifications
-
-
-
-
Field Detail
-
MINOR_EDIT
public static final SaveContext MINOR_EDIT
-
SUPPRESS_NOTIFICATIONS
public static final SaveContext SUPPRESS_NOTIFICATIONS
-
REFACTORING
public static final SaveContext REFACTORING
-
BULK_OPERATION
public static final SaveContext BULK_OPERATION
- Since:
- 6.0
-
DEFAULT
public static final SaveContext DEFAULT
-
DRAFT
public static final SaveContext DRAFT
-
RAW_DRAFT
public static final SaveContext RAW_DRAFT
-
DRAFT_REFACTORING
public static final SaveContext DRAFT_REFACTORING
-
REVERT
public static final SaveContext REVERT
-
-
Constructor Detail
-
DefaultSaveContext
@Deprecated public DefaultSaveContext(boolean suppressNotifications, boolean updateLastModifier, boolean suppressEvents)
Deprecated.since 6.0. Use thebuilder()or one of the final, pre-constructed contexts.
-
DefaultSaveContext
@Deprecated public DefaultSaveContext(boolean suppressNotifications, boolean updateLastModifier, boolean suppressEvents, PageUpdateTrigger updateTrigger)
Deprecated.since 6.0. Use thebuilder()or one of the final, pre-constructed contexts.
-
-
Method Detail
-
isSuppressAutowatch
public boolean isSuppressAutowatch()
Description copied from interface:SaveContextControl whether the save should result in the page being watched by the creator if they have their autowatch setting on. This has no effect if the event is suppressed as it is implemented as a property on the event.- Specified by:
isSuppressAutowatchin interfaceSaveContext- Returns:
- if true if automatic watches is to be suppressed.
-
setSuppressNotifications
@Deprecated public void setSuppressNotifications(boolean suppressNotifications)
Deprecated.since 6.0. Use thebuilder()instead.Description copied from interface:SaveContextIndicates that notifications should not be sent out informing users of the changes to this content.- Specified by:
setSuppressNotificationsin interfaceSaveContext
-
doUpdateLastModifier
public boolean doUpdateLastModifier()
Description copied from interface:SaveContextUpdateLastModifier indicates whether to update the LastModifier field when saving a page.- Specified by:
doUpdateLastModifierin interfaceSaveContext- Returns:
- true if the LastModifier should be updated
-
setUpdateLastModifier
@Deprecated public void setUpdateLastModifier(boolean updateLastModifier)
Deprecated.since 6.0. Use thebuilder()instead.- Specified by:
setUpdateLastModifierin interfaceSaveContext
-
builder
public static DefaultSaveContext.Builder builder()
- Returns:
- A builder object with all boolean fields initialised to false and updateTrigger initialised to UNKNOWN.
- Since:
- 6.0
-
-