de.smartics.properties.spi.config.support
Class MultiPropertyCollection

Package class diagram package MultiPropertyCollection
java.lang.Object
  extended by de.smartics.properties.spi.config.support.MultiPropertyCollection
All Implemented Interfaces:
PropertyCollection, Iterable< Property>

public final class MultiPropertyCollection
     
     
extends Object
implements PropertyCollection

Provides access to a set of property iterators.


Constructor Summary
MultiPropertyCollection()
           
 
Method Summary
 void add(PropertyCollection collection)
          Adds the given collection to this set.
 void close()
          Releases all resources used by this collection.
 Iterator<Property> iterator()
          Returns an iterator over a set of properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MultiPropertyCollection

public MultiPropertyCollection()
Method Detail

add

public void add(PropertyCollection collection)
         throws NullPointerException
Adds the given collection to this set.

Parameters:
collection - the collection to add.
Throws:
NullPointerException - if collection is null.

close

public void close()
Releases all resources used by this collection.

Closes each collection in the set.

Specified by:
close in interface PropertyCollection

iterator

public Iterator<Property> iterator()
Returns an iterator over a set of properties.

Please note that an implementation may require to call PropertyCollection.close() after iterating over the values. The client calling PropertyCollection.iterator() is responsible for closing the collection.

Returns an iterator on each collection in the set.

Specified by:
iterator in interface PropertyCollection
Specified by:
iterator in interface Iterable<Property>
Returns:
an iterator.


Copyright © 2012-2013 Kronseder & Reiner GmbH - smartics. All Rights Reserved.