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

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

@NotThreadSafe
public final class PropertiesPropertyCollection
     
     
extends Object
implements PropertyCollection

Implementation of PropertyCollection based on properties.


Constructor Summary
PropertiesPropertyCollection(Collection<Properties> properties)
          Constructor to add properties via a collection.
PropertiesPropertyCollection(Properties... properties)
          Constructor to add properties.
 
Method Summary
 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

PropertiesPropertyCollection

public PropertiesPropertyCollection(Collection<Properties> properties)
Constructor to add properties via a collection.

Parameters:
properties - the properties to iterate over.

PropertiesPropertyCollection

public PropertiesPropertyCollection(Properties... properties)
Constructor to add properties.

Parameters:
properties - the properties to iterate over.
Method Detail

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.

Specified by:
iterator in interface PropertyCollection
Specified by:
iterator in interface Iterable<Property>
Returns:
an iterator.
See Also:
Iterable.iterator()

close

public void close()
Description copied from interface: PropertyCollection
Releases all resources used by this collection.

Specified by:
close in interface PropertyCollection


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