Class UIRemoteProjectService
- java.lang.Object
-
- ca.corefacility.bioinformatics.irida.ria.web.services.UIRemoteProjectService
-
@Component public class UIRemoteProjectService extends java.lang.Object
A utility class for doing operations on remote project sync settings.
-
-
Constructor Summary
Constructors Constructor Description UIRemoteProjectService(org.springframework.context.MessageSource messageSource, ProjectService projectService, ProjectRemoteService projectRemoteService, UserService userService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RemoteProjectSettings
getProjectRemoteSettings(java.lang.Long projectId, java.util.Locale locale)
Gets the remote synchronizationProject
settingsjava.lang.String
updateProjectSyncSettings(java.lang.Long projectId, RemoteProjectSettingsUpdateRequest remoteProjectSettingsUpdateRequest, java.security.Principal principal, java.util.Locale locale)
Update the project sync settings
-
-
-
Constructor Detail
-
UIRemoteProjectService
@Autowired public UIRemoteProjectService(org.springframework.context.MessageSource messageSource, ProjectService projectService, ProjectRemoteService projectRemoteService, UserService userService)
-
-
Method Detail
-
updateProjectSyncSettings
public java.lang.String updateProjectSyncSettings(java.lang.Long projectId, RemoteProjectSettingsUpdateRequest remoteProjectSettingsUpdateRequest, java.security.Principal principal, java.util.Locale locale) throws java.lang.Exception
Update the project sync settings- Parameters:
projectId
- the project id to updateremoteProjectSettingsUpdateRequest
- object which is used to update frequency, and sync user, as well as force sync for a projectprincipal
- The current logged in userlocale
- user's locale- Returns:
String
- Throws:
java.lang.Exception
- if user cannot read the remote project or project is not found
-
getProjectRemoteSettings
public RemoteProjectSettings getProjectRemoteSettings(java.lang.Long projectId, java.util.Locale locale) throws java.lang.Exception
Gets the remote synchronizationProject
settings- Parameters:
projectId
- the ID of theProject
to readlocale
- user's locale- Returns:
RemoteProjectSettings
- Throws:
java.lang.Exception
- throws Exception if project is not found
-
-