Class TeamService
java.lang.Object
org.exoplatform.timetracker.service.TeamService
A Service to access and store Teams
- Version:
- $Id: $Id
- Author:
- medamine
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateTeam(Team team) Create new Team that will be available for all users.voidcreateTeamMember(TeamMember teamMember) Create new TeamMember that will be available for all users.voiddeleteTeam(String teamId) Delete Team identified by its id and check if username has permission to delete it.voiddeleteTeamMember(String teamMemberId) Delete TeamMember identified by its id and check if username has permission to delete it.getEmployeesList(String userName) Retrieves the list of Employees emptygetMembersList(String teamID) Retrieves the list of Teams with offset, limit and a keyword that can be emptygetTeams()Retrieves the list of Teams with offset, limit and a keyword that can be emptygetTeamsList(String userName) Retrieves the list of Teams with offset, limit and a keyword that can be emptyupdateTeam(Team team) Update an existing Project on datasource.
-
Constructor Details
-
TeamService
Constructor for TeamService.
- Parameters:
teamStorage- aTeamStorageobject.
-
-
Method Details
-
createTeam
Create new Team that will be available for all users. If the Team already exits anEntityExistsExceptionwill be thrown. -
updateTeam
Update an existing Project on datasource. If the Project doesn't exit anEntityNotFoundExceptionwill be thrown. -
deleteTeam
Delete Team identified by its id and check if username has permission to delete it.- Parameters:
teamId- technical identifier of Team- Throws:
javax.persistence.EntityNotFoundException- if Team wasn't foundIllegalAccessException- if user is not allowed to delete TeamException- if any.
-
getTeamsList
Retrieves the list of Teams with offset, limit and a keyword that can be empty -
getMembersList
Retrieves the list of Teams with offset, limit and a keyword that can be empty -
getEmployeesList
Retrieves the list of Employees empty -
getTeams
Retrieves the list of Teams with offset, limit and a keyword that can be empty -
createTeamMember
Create new TeamMember that will be available for all users. If the TeamMember already exits anEntityExistsExceptionwill be thrown.- Parameters:
teamMember- TeamMember to create- Throws:
Exception- when TeamMember already exists or an error occurs while creating TeamMember or its attached image
-
deleteTeamMember
Delete TeamMember identified by its id and check if username has permission to delete it.- Parameters:
teamMemberId- technical identifier of TeamMember- Throws:
javax.persistence.EntityNotFoundException- if TeamMember wasn't foundIllegalAccessException- if user is not allowed to delete TeamMemberException- if any.
-