public abstract class JavaSourceTaskFactory extends Object
JavaSourceJava parsing harness. Please note that there is usually no need to implement this class directly, as there are support classes for common
JavaSourceTaskFactoryimplementations. This factory should be registered in the global lookup using
|Modifier||Constructor and Description|
|Modifier and Type||Method and Description|
Create task for a given file.
Notify the infrastructure that the collection of fileobjects has been changed.
Specifies on which files should be registered tasks created by this factory.
Re-run task created by this factory for given file.
protected JavaSourceTaskFactory(@NonNull JavaSource.Phase phase, @NonNull JavaSource.Priority priority)
protected JavaSourceTaskFactory(@NonNull JavaSource.Phase phase, @NonNull JavaSource.Priority priority, @NonNull TaskIndexingMode taskIndexingMode)
phase- phase to use for tasks created by
priority- priority to use for tasks created by
taskIndexingMode- the awareness of indexing. For tasks which can run during indexing use
TaskIndexingMode.ALLOWED_DURING_SCANfor tasks which cannot run during indexing use
@NonNull protected abstract CancellableTask<CompilationInfo> createTask(FileObject file)
JavaSourceparsing harness with a given
phase. Please note that this method should run as quickly as possible.
file- for which file the task should be created.
CancellableTaskfor a given file.
@NonNull protected abstract Collection<FileObject> getFileObjects()
JavaSource's corresponding to
FileObjects returned from this method will be registered tasks created by the
createTask(org.openide.filesystems.FileObject)method of this factory. If this list changes, a change event should be fired to all registered
protected final void fileObjectsChanged()
getFileObjects()to get a new collection files.
Built on October 25 2023. | Copyright © 2017-2023 Apache Software Foundation. All Rights Reserved.