Package com.atlassian.jira.notification
Class DefaultNotificationSchemeService
java.lang.Object
com.atlassian.jira.notification.DefaultNotificationSchemeService
- All Implemented Interfaces:
NotificationSchemeService
- Since:
- 6.5
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefaultNotificationSchemeService(NotificationSchemeManager notificationSchemeManager, EventTypeManager eventTypeManager, UserManager userManager, GroupManager groupManager, ProjectRoleManager projectRoleManager, CustomFieldManager customFieldManager, PermissionManager permissionManager, GlobalPermissionManager globalPermissionManager, I18nHelper i18n, ProjectManager projectManager) -
Method Summary
Modifier and TypeMethodDescriptiongetNotificationScheme(ApplicationUser user, Long id) Returns the notification scheme for given id.getNotificationSchemeForProject(ApplicationUser user, Long projectId) Returns a notification scheme for the given project identified by the project's id.getNotificationSchemeForProject(ApplicationUser user, String projectKey) Returns a notification scheme for the given project identified by the project's key.getNotificationSchemes(ApplicationUser user, PageRequest pageRequest) Returns a page with notification schemes for the givenPageRequestordered by name.
-
Field Details
-
MAX_PAGE_RESULT
public static final int MAX_PAGE_RESULT- See Also:
-
-
Constructor Details
-
DefaultNotificationSchemeService
public DefaultNotificationSchemeService(NotificationSchemeManager notificationSchemeManager, EventTypeManager eventTypeManager, UserManager userManager, GroupManager groupManager, ProjectRoleManager projectRoleManager, CustomFieldManager customFieldManager, PermissionManager permissionManager, GlobalPermissionManager globalPermissionManager, I18nHelper i18n, ProjectManager projectManager)
-
-
Method Details
-
getNotificationScheme
public ServiceOutcome<NotificationScheme> getNotificationScheme(ApplicationUser user, @Nonnull Long id) Description copied from interface:NotificationSchemeServiceReturns the notification scheme for given id. This method executes a permission check, in order to have permissions to retrieve the notification scheme, the user is required to have permissions for administering at least one project associated with the notification scheme.- Specified by:
getNotificationSchemein interfaceNotificationSchemeService- Parameters:
user- user who requests the access to the notification schemeid- id of the notification scheme to retrieve- Returns:
- information about the notification scheme.
-
getNotificationSchemes
public Page<NotificationScheme> getNotificationSchemes(ApplicationUser user, @Nonnull PageRequest pageRequest) Description copied from interface:NotificationSchemeServiceReturns a page with notification schemes for the givenPageRequestordered by name. This method executes a permission check. User is required to have administer permissions on projects associated with the scheme in order to see it.- Specified by:
getNotificationSchemesin interfaceNotificationSchemeService- Parameters:
user- user who requests access to notification schemes.pageRequest- information about the desired number of results and theirs offset.- Returns:
- the page with notification schemes. The page may be empty.
-
getNotificationSchemeForProject
public ServiceOutcome<NotificationScheme> getNotificationSchemeForProject(ApplicationUser user, @Nonnull Long projectId) Description copied from interface:NotificationSchemeServiceReturns a notification scheme for the given project identified by the project's id.- Specified by:
getNotificationSchemeForProjectin interfaceNotificationSchemeService- Parameters:
user- user who requests the access to the notification schemeprojectId- id of the project for which the associated notification scheme will be returned- Returns:
- information about the notification scheme.
- See Also:
-
getNotificationSchemeForProject
public ServiceOutcome<NotificationScheme> getNotificationSchemeForProject(ApplicationUser user, @Nonnull String projectKey) Description copied from interface:NotificationSchemeServiceReturns a notification scheme for the given project identified by the project's key.- Specified by:
getNotificationSchemeForProjectin interfaceNotificationSchemeService- Parameters:
user- user who requests the access to the notification schemeprojectKey- key of the project for which the associated notification scheme will be returned- Returns:
- information about the notification scheme.
- See Also:
-