|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tika.config.ServiceLoader
public class ServiceLoader
Internal utility class that Tika uses to look up service providers.
Constructor Summary | |
---|---|
ServiceLoader()
|
|
ServiceLoader(java.lang.ClassLoader loader)
|
|
ServiceLoader(java.lang.ClassLoader loader,
LoadErrorHandler handler)
|
Method Summary | ||
---|---|---|
java.util.Enumeration<java.net.URL> |
findServiceResources(java.lang.String filePattern)
Returns all the available service resources matching the given pattern, such as all instances of tika-mimetypes.xml on the classpath, or all org.apache.tika.parser.Parser service files. |
|
|
loadServiceProviders(java.lang.Class<T> service)
Returns all the available service providers of the given type. |
|
static void |
setContextClassLoader(java.lang.ClassLoader loader)
Sets the context class loader to use for all threads that access this class. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ServiceLoader(java.lang.ClassLoader loader, LoadErrorHandler handler)
public ServiceLoader(java.lang.ClassLoader loader)
public ServiceLoader()
Method Detail |
---|
public static void setContextClassLoader(java.lang.ClassLoader loader)
loader
- default context class loader,
or null
to automatically pick the loaderpublic java.util.Enumeration<java.net.URL> findServiceResources(java.lang.String filePattern)
public <T> java.util.List<T> loadServiceProviders(java.lang.Class<T> service)
service
- service provider interface
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |