org.identityconnectors.framework.common.objects
Class AttributeInfoUtil

java.lang.Object
  extended by org.identityconnectors.framework.common.objects.AttributeInfoUtil

public final class AttributeInfoUtil
extends Object

Utility methods to retrieve values from instances of AttributeInfo.


Constructor Summary
AttributeInfoUtil()
           
 
Method Summary
static AttributeInfo find(String name, Set<AttributeInfo> attrs)
          Find the AttributeInfo of the given name in the Set.
static Map<String,AttributeInfo> toMap(Collection<? extends AttributeInfo> attributes)
          Transform a Collection of AttributeInfo instances into a Map.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttributeInfoUtil

public AttributeInfoUtil()
Method Detail

toMap

public static Map<String,AttributeInfo> toMap(Collection<? extends AttributeInfo> attributes)
Transform a Collection of AttributeInfo instances into a Map. The key to each element in the map is the name of an AttributeInfo. The value of each element in the map is the AttributeInfo instance with that name.

Parameters:
attributes - set of AttributeInfo to transform to a map.
Returns:
a map of string and AttributeInfo.
Throws:
NullPointerException - iff the parameter attributes is null.

find

public static AttributeInfo find(String name,
                                 Set<AttributeInfo> attrs)
Find the AttributeInfo of the given name in the Set.

Parameters:
name - AttributeInfo's name to search for.
attrs - Set of AttributeInfo to search.
Returns:
AttributeInfo with the specified otherwise null.


Copyright © 2012. All Rights Reserved.