Class FilterResourceResolver
- java.lang.Object
-
- de.captaingoldfish.scim.sdk.server.filter.resources.FilterResourceResolver
-
public class FilterResourceResolver extends Object
author Pascal Knueppel
created at: 20.10.2019 - 20:17
This class is used to use aFilterNodetree on a resource list to filter all resources that match the given filter expression
-
-
Constructor Summary
Constructors Constructor Description FilterResourceResolver()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description protected static booleancheckValueEquality(com.fasterxml.jackson.databind.JsonNode attributeNode, AttributeExpressionLeaf attributeExpressionLeaf)checks if the given simple attribute node does match the given filter expressionstatic <T extends ResourceNode>
List<T>filterResources(List<T> resources, FilterNode filterNode)filters the given resources based on the filternode
-
-
-
Method Detail
-
filterResources
public static <T extends ResourceNode> List<T> filterResources(List<T> resources, FilterNode filterNode)
filters the given resources based on the filternode- Type Parameters:
T- aResourceNodetype- Parameters:
resources- the resources that must be filteredfilterNode- the filter node that holds the information how the resources should be filtered- Returns:
- the filtered resources
-
checkValueEquality
protected static boolean checkValueEquality(com.fasterxml.jackson.databind.JsonNode attributeNode, AttributeExpressionLeaf attributeExpressionLeaf)checks if the given simple attribute node does match the given filter expression- Parameters:
attributeNode- a simple attribute node with primitive values. This might be a json array with primitives or a json primitiveattributeExpressionLeaf- the expression leaf that describes the node- Returns:
- true if the attribute matches the expression, false else
-
-