All Downloads are FREE. Search and download functionalities are using the official Maven repository.

edu.ksu.canvas.requestOptions.GetUsersInAccountOptions Maven / Gradle / Ivy

The newest version!
package edu.ksu.canvas.requestOptions;

import java.util.List;

/**
 * Options class which supports queries used to retrieve all users for a given account.
 * 

* Standard information which can be queried upon include: *

    *
  • A search term - which behaves analogously to the browser search in what it accepts and searches on
  • *
  • The column with which to sort by - username, email, sis_id and login are acceptable options
  • *
  • The overall ordering cardinality of the data brought back
  • *
*

* A commonplace query parameter is also added for querying convenience: *
* include[] - useful to include extra values that are not included in the data objects by default. * Acceptable values are avatar_url, email, last_login and time_zone. *

* The values which are supported with this are found * on the "List users in account" portion of the Canvas API. */ public class GetUsersInAccountOptions extends BaseOptions { public enum Include { avatar_url, email, last_login, time_zone } private String accountId; public GetUsersInAccountOptions(final String accountId) { this.accountId = accountId; } public String getAccountId() { return accountId; } public GetUsersInAccountOptions searchTerm(final String searchTerm) { addSingleItem("search_term", searchTerm); return this; } public GetUsersInAccountOptions sort(final String sort) { addSingleItem("sort", sort); return this; } public GetUsersInAccountOptions order(final String order) { addSingleItem("order", order); return this; } public GetUsersInAccountOptions include(List includes) { addEnumList("include[]", includes); return this; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy