public abstract class AbstractCompletionFinder extends Object implements CompletionFinder
CompletionFinder
with facilities for service dependency tracking.AbstractCompleterService
Modifier and Type | Field and Description |
---|---|
protected DependencyServices |
dependencyServices |
Modifier | Constructor and Description |
---|---|
protected |
AbstractCompletionFinder(DependencyServices dependencyServices)
Construct an instance.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
allDependenciesAvailable()
Helper method which returns true iff all dependencies listed by
getRequiredDependencies()
are currently available. |
protected abstract Class<?>[] |
getRequiredDependencies()
Get the list of dependency classes required for this CompletionFinder to work correctly.
|
protected <T> T |
getService(Class<T> klazz)
Get an instance of a service dependency, if any.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
findCompletions
protected final DependencyServices dependencyServices
protected AbstractCompletionFinder(DependencyServices dependencyServices)
dependencyServices
- the dependency servicesprotected <T> T getService(Class<T> klazz)
T
- the type of the class parameterklazz
- the Class parameterallDependenciesAvailable()
protected abstract Class<?>[] getRequiredDependencies()
CompletionFinder
.protected boolean allDependenciesAvailable()
getRequiredDependencies()
are currently available.
Implementations of CompletionFinder.findCompletions()
should first call this method and, most likely,
return an empty list if it returns false.Copyright © 2017. All rights reserved.