net.shibboleth.metadata.util
Class ItemMetadataSupport

java.lang.Object
  extended by net.shibboleth.metadata.util.ItemMetadataSupport

public final class ItemMetadataSupport
extends Object

Helper class for dealing with ItemMetadata operations.


Constructor Summary
private ItemMetadataSupport()
          Constructor.
 
Method Summary
static void addToAll(Collection<? extends Item> itemCollection, ItemMetadata... metadatas)
          Adds all the give ItemMetadata items to each Item element in the given collection.
static void addToAll(Item<?> item, ItemMetadata... metadatas)
          Adds all the given ItemMetadata items to the given Item element.
static void addToCollection(Collection<? extends Item> itemCollection, ItemMetadata... itemMetadatas)
          Adds one or more ItemMetadata to the given collection if the collection is an instance of ItemCollectionWithMetadata.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ItemMetadataSupport

private ItemMetadataSupport()
Constructor.

Method Detail

addToAll

public static void addToAll(Collection<? extends Item> itemCollection,
                            ItemMetadata... metadatas)
Adds all the give ItemMetadata items to each Item element in the given collection.

Parameters:
itemCollection - collection of Item elements
metadatas - collection of ItemMetadata items to be added to each Item element of the given collection

addToAll

public static void addToAll(Item<?> item,
                            ItemMetadata... metadatas)
Adds all the given ItemMetadata items to the given Item element.

Parameters:
item - element to which ItemMetadata will be added
metadatas - ItemMetadata to be added to the metadata element

addToCollection

public static void addToCollection(Collection<? extends Item> itemCollection,
                                   ItemMetadata... itemMetadatas)
Adds one or more ItemMetadata to the given collection if the collection is an instance of ItemCollectionWithMetadata.

Parameters:
itemCollection - collection to which the metadata may be added
itemMetadatas - the metadata which may be added to the collection


Copyright © 2009-2011. All Rights Reserved.