[java-shib-attribute] branch main updated: IDP-1795 Complete the removal of Collections from IdPAttributes

Rod Widdowson rdw at steadingsoftware.com
Wed Jul 20 10:38:55 UTC 2022


This is an automated email from the git hooks/post-receive script.

rdw pushed a commit to branch main
in repository java-shib-attribute.

View the commit online:
http://git.shibboleth.net/view/?p=java-shib-attribute.git;a=commit;h=1f2d3f86d330c32f7c589188a9de7887b7662f2b

The following commit(s) were added to refs/heads/main by this push:
     new 1f2d3f86d IDP-1795  Complete the removal of Collections from IdPAttributes
1f2d3f86d is described below

commit 1f2d3f86d330c32f7c589188a9de7887b7662f2b
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Mon Jul 18 20:15:24 2022 +0100

    IDP-1795  Complete the removal of Collections from IdPAttributes
    
    https://shibboleth.atlassian.net/browse/IDP-1795
    
    IdPAttribute#setValues() now takes a List
---
 .../src/main/java/net/shibboleth/idp/attribute/IdPAttribute.java   | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/shib-attribute-api/src/main/java/net/shibboleth/idp/attribute/IdPAttribute.java b/shib-attribute-api/src/main/java/net/shibboleth/idp/attribute/IdPAttribute.java
index 4301c1f99..1bd4f7afb 100644
--- a/shib-attribute-api/src/main/java/net/shibboleth/idp/attribute/IdPAttribute.java
+++ b/shib-attribute-api/src/main/java/net/shibboleth/idp/attribute/IdPAttribute.java
@@ -17,7 +17,6 @@
 
 package net.shibboleth.idp.attribute;
 
-import java.util.Collection;
 import java.util.Collections;
 import java.util.List;
 import java.util.function.Predicate;
@@ -131,12 +130,8 @@ public class IdPAttribute implements Comparable<IdPAttribute>, Cloneable {
      * 
      * @param newValues the new values for this attribute
      */
-    public void setValues(@Nullable @NullableElements final Collection<IdPAttributeValue> newValues) {
+    public void setValues(@Nullable @NullableElements final List<IdPAttributeValue> newValues) {
         if (newValues != null) {
-            if (!(newValues instanceof List)) {
-                DeprecationSupport.warnOnce(ObjectType.METHOD, "Passing a Collection to IdpAttribute#setValues()",
-                        null, "List");
-            }
             values = newValues.stream().
                      map(e -> e==null? new EmptyAttributeValue(EmptyType.NULL_VALUE) :e).
                      collect(Collectors.toUnmodifiableList());

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list