scim2 icon indicating copy to clipboard operation
scim2 copied to clipboard

Add methods to replace and remove values from an multi-valued attribute using POJOs

Open digitalperk opened this issue 9 years ago • 0 comments

Currently, to remove and/or replace values of a multi-valued attribute, you will have to provide a path to the remove and replace methods. This is often inconvenient since the getters return POJOs and it will be much easier to just remove and/or replace using one of the returned instances instead of constructing a filter. This allows for quick object manipulation like:

List<Address> addresses = resource.getValues("addresses", Address.class);
for(Address address : addresses)
{
  if(address.zipCode().equals("78750"))
  {
    resource.removeValues("addresses", address);
  }
}

This applies to the *ScimResource as well as the ModifyRequestBuilder classes.

digitalperk avatar Jun 10 '15 22:06 digitalperk