Package ch.aaap.harvestclient.impl
Class UserAssignmentsApiImpl
Object
ch.aaap.harvestclient.impl.UserAssignmentsApiImpl
- All Implemented Interfaces:
Api.GetNested<Project,,UserAssignment> UserAssignmentsApi
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate(Reference<Project> projectReference, UserAssignment creationInfo) Create a new UserAssignmentvoiddelete(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference) Delete an existing UserAssignment.get(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference) Return an existing UserAssignment.list(Reference<Project> projectReference, UserAssignmentFilter filter) list(Reference<Project> projectReference, UserAssignmentFilter filter, int page, int perPage) update(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference, UserAssignmentUpdateInfo updateInfo) Updates the specific UserAssignment by setting the values of the parameters passed.
-
Constructor Details
-
UserAssignmentsApiImpl
-
-
Method Details
-
list
- Specified by:
listin interfaceUserAssignmentsApi- Parameters:
projectReference- the project containing the assignmentsfilter- filtering options- Returns:
- a list of all UserAssignments in the project, sorted by creation date, newest first.
-
list
public Pagination<UserAssignment> list(Reference<Project> projectReference, UserAssignmentFilter filter, int page, int perPage) - Specified by:
listin interfaceUserAssignmentsApi- Parameters:
projectReference- the project containing the assignmentsfilter- filtering optionspage- the page numberperPage- how many results to return for one page. Max 100- Returns:
- a list of all UserAssignments in the project, sorted by creation date, newest first.
-
get
public UserAssignment get(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference) Description copied from interface:UserAssignmentsApiReturn an existing UserAssignment.- Specified by:
getin interfaceApi.GetNested<Project,UserAssignment> - Specified by:
getin interfaceUserAssignmentsApi- Parameters:
projectReference- the project containing the assignmentuserAssignmentReference- a reference to an existing UserAssignment- Returns:
- the full UserAssignment object
-
create
Description copied from interface:UserAssignmentsApiCreate a new UserAssignment- Specified by:
createin interfaceUserAssignmentsApi- Parameters:
projectReference- the project that will contain the assignmentcreationInfo- creation information- Returns:
- the created User
-
update
public UserAssignment update(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference, UserAssignmentUpdateInfo updateInfo) Description copied from interface:UserAssignmentsApiUpdates the specific UserAssignment by setting the values of the parameters passed. Any parameters not provided will be left unchanged- Specified by:
updatein interfaceUserAssignmentsApi- Parameters:
projectReference- the project that contains the assignmentuserAssignmentReference- An existing UserAssignment to be updatedupdateInfo- the changes to be performed- Returns:
- the updated UserAssignment
-
delete
public void delete(Reference<Project> projectReference, Reference<UserAssignment> userAssignmentReference) Description copied from interface:UserAssignmentsApiDelete an existing UserAssignment.- Specified by:
deletein interfaceUserAssignmentsApi- Parameters:
projectReference- the project that contains the assignmentuserAssignmentReference- An existing UserAssignment to be deleted
-