public final class SPIClassIterator<S>
extends java.lang.Object
implements java.util.Iterator<java.lang.Class<? extends S>>
ServiceLoader but is guaranteed to
be bug-free regarding classpath order and does not instantiate or initialize
the classes found.| Modifier and Type | Method and Description |
|---|---|
static <S> SPIClassIterator<S> |
get(java.lang.Class<S> clazz) |
static <S> SPIClassIterator<S> |
get(java.lang.Class<S> clazz,
java.lang.ClassLoader loader) |
boolean |
hasNext() |
static boolean |
isParentClassLoader(java.lang.ClassLoader parent,
java.lang.ClassLoader child)
Utility method to check if some class loader is a (grand-)parent of or the same as another one.
|
java.lang.Class<? extends S> |
next() |
void |
remove() |
public static <S> SPIClassIterator<S> get(java.lang.Class<S> clazz)
public static <S> SPIClassIterator<S> get(java.lang.Class<S> clazz, java.lang.ClassLoader loader)
public static boolean isParentClassLoader(java.lang.ClassLoader parent,
java.lang.ClassLoader child)
public boolean hasNext()
hasNext in interface java.util.Iterator<java.lang.Class<? extends S>>public java.lang.Class<? extends S> next()
next in interface java.util.Iterator<java.lang.Class<? extends S>>public void remove()
remove in interface java.util.Iterator<java.lang.Class<? extends S>>Copyright © 2010 - 2024 Adobe. All Rights Reserved