org.apache.stanbol.entityhub.servicesapi.util
Class TypeSafeIterator<T>
java.lang.Object
org.apache.stanbol.entityhub.servicesapi.util.AdaptingIterator<Object,T>
org.apache.stanbol.entityhub.servicesapi.util.TypeSafeIterator<T>
- Type Parameters:
T - the type of elements returned by this iterator
- All Implemented Interfaces:
- Iterator<T>
public class TypeSafeIterator<T>
- extends AdaptingIterator<Object,T>
- implements Iterator<T>
Filters elements of the base Iterator base on the generic type of this one
- Author:
- Rupert Westenthaler
|
Constructor Summary |
TypeSafeIterator(Iterator<?> it,
Class<T> type)
Constructs an iterator that selects only elements of the parsed iterator
that are assignable to the parse type |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TypeSafeIterator
public TypeSafeIterator(Iterator<?> it,
Class<T> type)
- Constructs an iterator that selects only elements of the parsed iterator
that are assignable to the parse type
- Parameters:
it - the base iteratortype - the type all elements of this Iterator need to be assignable to.
Copyright © 2010-2013 The Apache Software Foundation. All Rights Reserved.