Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,20 @@ public static Long commandId(final MultivaluedMap<String, String> queryParams) {
return id;
}

/**
* Extracts the "fields" query parameter from the API request.
*
* Example:
* GET /clients?fields=id,name,status
*
* Result:
* ["id", "name", "status"]
*
* This is used to limit response payload size and improve performance.
*
* @param queryParams HTTP query parameters
* @return Set of requested response fields, or empty set if none provided
*/
public static Set<String> extractFieldsForResponseIfProvided(final MultivaluedMap<String, String> queryParams) {
Set<String> fields = new HashSet<>();
String commaSeparatedParameters = "";
Expand Down
Loading