Class DefaultCollaborativeEditingHelper
java.lang.Object
com.atlassian.confluence.setup.settings.DefaultCollaborativeEditingHelper
- All Implemented Interfaces:
CollaborativeEditingHelper
@Internal
public class DefaultCollaborativeEditingHelper
extends Object
implements CollaborativeEditingHelper
- Since:
- 6.3.0
-
Field Summary
Fields inherited from interface com.atlassian.confluence.setup.settings.CollaborativeEditingHelper
COLLABORATIVE_MODE, LEGACY_MODE, LIMITED_MODE, SHARED_DRAFTS_DARK_FEATURE, SITE_WIDE_SHARED_DRAFTS_DARK_FEATURE, SITE_WIDE_SYNCHRONY_DARK_FEATURE, SYNCHRONY_DARK_FEATURE, USER_LIMIT_DARK_FEATURE_DISABLE
-
Constructor Summary
ConstructorDescriptionDefaultCollaborativeEditingHelper
(DarkFeaturesManager darkFeaturesManager, UpgradedFlag upgradedFlag) DefaultCollaborativeEditingHelper
(DarkFeaturesManager darkFeaturesManager, UpgradeManager upgradeManager) Deprecated.since 7.20 -
Method Summary
Modifier and TypeMethodDescriptiongetEditMode
(String spaceKey) Returns the current editing mode.static String
getSpaceDarkFeature
(String spaceKey) static String
getSynchronySpaceDarkFeature
(String spaceKey) Deprecated.since 7.5.0.int
Returns the number of users allowed in editor.boolean
isLimitedModeEnabled
(String spaceKey) Deprecated.boolean
isOverLimit
(int numberOfConcurrentUsers) boolean
isSharedDraftsFeatureEnabled
(String spaceKey) Checks if the Shared Drafts dark feature is enabled for the space or globally when no space is passed.boolean
Maybe better alternative is do synchrony event propagation via this class so upgrade check is isolated in one place.
-
Constructor Details
-
DefaultCollaborativeEditingHelper
public DefaultCollaborativeEditingHelper(DarkFeaturesManager darkFeaturesManager, UpgradedFlag upgradedFlag) - Since:
- 7.20
-
DefaultCollaborativeEditingHelper
public DefaultCollaborativeEditingHelper(DarkFeaturesManager darkFeaturesManager, UpgradeManager upgradeManager) Deprecated.since 7.20- Since:
- 7.5
-
-
Method Details
-
isUpgraded
public boolean isUpgraded()Description copied from interface:CollaborativeEditingHelper
Maybe better alternative is do synchrony event propagation via this class so upgrade check is isolated in one place.- Specified by:
isUpgraded
in interfaceCollaborativeEditingHelper
- Returns:
- false if upgrade is in progress so synchrony events could be suppressed.
-
isLimitedModeEnabled
Deprecated.- Specified by:
isLimitedModeEnabled
in interfaceCollaborativeEditingHelper
- Parameters:
spaceKey
- space key- Returns:
- true if limited mode is enabled (since 7.5.0 this method always returns
false
)
-
getEditMode
Description copied from interface:CollaborativeEditingHelper
Returns the current editing mode.- Specified by:
getEditMode
in interfaceCollaborativeEditingHelper
- Parameters:
spaceKey
- space key- Returns:
- the current editing mode, one of
CollaborativeEditingHelper.LEGACY_MODE
,CollaborativeEditingHelper.COLLABORATIVE_MODE
,
-
getSpaceDarkFeature
-
getSynchronySpaceDarkFeature
Deprecated.since 7.5.0. Limited mode is no longer supported since 7.5.0 -
isOverLimit
public boolean isOverLimit(int numberOfConcurrentUsers) - Specified by:
isOverLimit
in interfaceCollaborativeEditingHelper
- Parameters:
numberOfConcurrentUsers
- Number of users currently in the editor including the current user.- Returns:
- true if the number of users in the editor is greater than the limit
-
getUserLimit
public int getUserLimit()Description copied from interface:CollaborativeEditingHelper
Returns the number of users allowed in editor.- Specified by:
getUserLimit
in interfaceCollaborativeEditingHelper
- Returns:
- the number of users allowed in editor