public final class QuerySupport extends Object
| Modifier and Type | Method and Description |
|---|---|
static AnnotationProcessingQueryImplementation |
createAnnotationProcessingQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
String annotationProcessingEnabledProperty,
String annotationProcessingEnabledInEditorProperty,
String runAllAnnotationProcessorsProperty,
String annotationProcessorsProperty,
String sourceOutputProperty,
String processorOptionsProperty)
Create a new query to provide annotation processing configuration data.
|
static BinaryForSourceQueryImplementation |
createBinaryForSourceQueryImplementation(SourceRoots src,
SourceRoots test,
AntProjectHelper helper,
PropertyEvaluator eval)
Shortcut version of
createBinaryForSourceQueryImplementation(org.netbeans.modules.java.api.common.SourceRoots, org.netbeans.modules.java.api.common.SourceRoots, org.netbeans.spi.project.support.ant.AntProjectHelper, org.netbeans.spi.project.support.ant.PropertyEvaluator, java.lang.String, java.lang.String)
which assumes that build classes folder is stored in property build.classes.dir and
built test classes folder is stored in property build.test.classes.dir. |
static BinaryForSourceQueryImplementation |
createBinaryForSourceQueryImplementation(SourceRoots src,
SourceRoots test,
AntProjectHelper helper,
PropertyEvaluator eval,
String sourceProp,
String testProp)
Creates an implementation of
BinaryForSourceQueryImplementation
which maps given project source roots and test roots to given folders
with built classes and built test classes. |
static SourceForBinaryQueryImplementation |
createCompiledSourceForBinaryQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots srcRoots,
SourceRoots testRoots)
Create a new query to provide information about where Java sources
corresponding to binaries (classfiles) can be found.
|
static SourceForBinaryQueryImplementation |
createCompiledSourceForBinaryQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots srcRoots,
SourceRoots testRoots,
String[] binaryProperties,
String[] testBinaryProperties)
Create a new query to provide information about where Java sources
corresponding to binaries (classfiles) can be found.
|
static FileBuiltQueryImplementation |
createFileBuiltQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots sourceRoots,
SourceRoots testRoots)
Create a new query to test whether a file can be considered to be built (up to date).
|
static FileEncodingQueryImplementation |
createFileEncodingQuery(PropertyEvaluator eval,
String sourceEncodingPropertyName)
Create a new query to provide information about encoding of a file.
|
static JavadocForBinaryQueryImplementation |
createJavadocForBinaryQuery(AntProjectHelper helper,
PropertyEvaluator evaluator)
Create a new query to find Javadoc.
|
static JavadocForBinaryQueryImplementation |
createJavadocForBinaryQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
String[] binaryProperties)
Create a new query to find Javadoc.
|
static ProjectInformation |
createProjectInformation(AntProjectHelper projectHelper,
Project project,
Icon icon) |
static ProjectInformation |
createProjectInformation(UpdateHelper updateHelper,
Project project,
Icon icon) |
static SharabilityQueryImplementation |
createSharabilityQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots srcRoots,
SourceRoots testRoots)
|
static SharabilityQueryImplementation |
createSharabilityQuery(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots srcRoots,
SourceRoots testRoots,
String... additionalSourceRoots)
|
static SharabilityQueryImplementation2 |
createSharabilityQuery2(AntProjectHelper helper,
PropertyEvaluator evaluator,
SourceRoots srcRoots,
SourceRoots testRoots,
String... additionalSourceRoots)
Create a new query to provide information about files sharability.
|
static SourceLevelQueryImplementation |
createSourceLevelQuery(PropertyEvaluator evaluator)
|
static SourceLevelQueryImplementation2 |
createSourceLevelQuery2(PropertyEvaluator evaluator)
Create a new query to find out source level of Java source files (SourceLevelQueryImplementation2).
|
static Sources |
createSources(Project project,
AntProjectHelper helper,
PropertyEvaluator evaluator,
Roots... roots)
Returns
Sources implementation designed for projects that supports adding
or removing of the source roots. |
static CreateFromTemplateAttributesProvider |
createTemplateAttributesProvider(AntProjectHelper helper,
FileEncodingQueryImplementation encodingQuery)
Creates an implementation of
CreateFromTemplateAttributesProvider providing
attributes for the project license and encoding. |
static MultipleRootsUnitTestForSourceQueryImplementation |
createUnitTestForSourceQuery(SourceRoots sourceRoots,
SourceRoots testRoots)
Create a new query to find Java package roots of unit tests for Java package root of sources and vice versa.
|
public static SourceForBinaryQueryImplementation createCompiledSourceForBinaryQuery(AntProjectHelper helper, PropertyEvaluator evaluator, SourceRoots srcRoots, SourceRoots testRoots)
helper - AntProjectHelper used for resolving files, e.g. output directory.evaluator - PropertyEvaluator used for obtaining project properties.srcRoots - a list of source roots.testRoots - a list of test roots.SourceForBinaryQueryImplementation to provide information about where Java sources can be found.SourceForBinaryQueryImplementationpublic static SourceForBinaryQueryImplementation createCompiledSourceForBinaryQuery(@NonNull AntProjectHelper helper, @NonNull PropertyEvaluator evaluator, @NonNull SourceRoots srcRoots, @NullAllowed SourceRoots testRoots, @NonNull String[] binaryProperties, @NullAllowed String[] testBinaryProperties)
helper - AntProjectHelper used for resolving files, e.g. output directory.evaluator - PropertyEvaluator used for obtaining project properties.srcRoots - a list of source roots.testRoots - a list of test roots, may be null if the project does not support tests.binaryProperties - array of property names of binary artifacts produced by this project, e.g. dist.jartestBinaryProperties - array of property names of test binary artifacts produced by this project, e.g. build.test.classes.dir
If the testRoots parameter is null this parameter has to be null as well.SourceForBinaryQueryImplementation to provide information about where Java sources can be found.SourceForBinaryQueryImplementationpublic static FileEncodingQueryImplementation createFileEncodingQuery(PropertyEvaluator eval, String sourceEncodingPropertyName)
eval - PropertyEvaluator used for obtaining the value of source encoding.sourceEncodingPropertyName - the source encoding property name.FileEncodingQueryImplementation to provide information about encoding of a file.public static JavadocForBinaryQueryImplementation createJavadocForBinaryQuery(AntProjectHelper helper, PropertyEvaluator evaluator)
helper - AntProjectHelper used for resolving files, e.g. output directory.evaluator - PropertyEvaluator used for obtaining the Javadoc root.JavadocForBinaryQueryImplementation to find Javadoc.public static JavadocForBinaryQueryImplementation createJavadocForBinaryQuery(AntProjectHelper helper, PropertyEvaluator evaluator, String[] binaryProperties)
helper - AntProjectHelper used for resolving files, e.g. output directory.evaluator - PropertyEvaluator used for obtaining the Javadoc root.binaryProperties - array of property names of binary artifacts produced by this project, e.g. dist.jarJavadocForBinaryQueryImplementation to find Javadoc.public static SharabilityQueryImplementation2 createSharabilityQuery2(@NonNull AntProjectHelper helper, @NonNull PropertyEvaluator evaluator, @NonNull SourceRoots srcRoots, @NullAllowed SourceRoots testRoots, @NullAllowed String... additionalSourceRoots)
helper - AntProjectHelper used for creating a query itself.evaluator - a property evaluator to interpret paths with.srcRoots - a list of source roots to treat as sharable.testRoots - a list of test roots to treat as sharable, may be null if the project does not support testsadditionalSourceRoots - additional paths to treat as sharable (just pure property names, do not
use ${ and } characters). Can be null.@Deprecated public static SharabilityQueryImplementation createSharabilityQuery(@NonNull AntProjectHelper helper, @NonNull PropertyEvaluator evaluator, @NonNull SourceRoots srcRoots, @NullAllowed SourceRoots testRoots, @NullAllowed String... additionalSourceRoots)
@Deprecated public static SharabilityQueryImplementation createSharabilityQuery(AntProjectHelper helper, PropertyEvaluator evaluator, SourceRoots srcRoots, SourceRoots testRoots)
@Deprecated public static SourceLevelQueryImplementation createSourceLevelQuery(PropertyEvaluator evaluator)
evaluator - PropertyEvaluator used for obtaining needed properties.SourceLevelQueryImplementation to find out specification source level of Java source files.public static SourceLevelQueryImplementation2 createSourceLevelQuery2(@NonNull PropertyEvaluator evaluator)
evaluator - PropertyEvaluator used for obtaining needed properties.SourceLevelQueryImplementation2 to find out source level of Java source files.public static MultipleRootsUnitTestForSourceQueryImplementation createUnitTestForSourceQuery(SourceRoots sourceRoots, SourceRoots testRoots)
sourceRoots - a list of source roots.testRoots - a list of test roots.MultipleRootsUnitTestForSourceQueryImplementation to find Java package roots of unit tests
for Java package root of sources and vice versa.public static FileBuiltQueryImplementation createFileBuiltQuery(AntProjectHelper helper, PropertyEvaluator evaluator, SourceRoots sourceRoots, SourceRoots testRoots)
helper - AntProjectHelper used for creating a query itself.evaluator - PropertyEvaluator used for obtaining needed properties.sourceRoots - a list of source roots.testRoots - a list of test roots.FileBuiltQueryImplementation to test whether a file can be considered to be built (up to date).public static CreateFromTemplateAttributesProvider createTemplateAttributesProvider(AntProjectHelper helper, FileEncodingQueryImplementation encodingQuery)
CreateFromTemplateAttributesProvider providing
attributes for the project license and encoding.helper - AntProjectHelper used for reading the project properties.encodingQuery - FileEncodingQueryImplementation used to obtain an encoding.CreateFromTemplateAttributesProvider.public static BinaryForSourceQueryImplementation createBinaryForSourceQueryImplementation(SourceRoots src, SourceRoots test, AntProjectHelper helper, PropertyEvaluator eval, String sourceProp, String testProp)
BinaryForSourceQueryImplementation
which maps given project source roots and test roots to given folders
with built classes and built test classes.src - project source rootstest - project test rootshelper - AntProjectHelpereval - PropertyEvaluatorsourceProp - name of property pointing to a folder with built classestestProp - name of property pointing to a folder with built test classespublic static BinaryForSourceQueryImplementation createBinaryForSourceQueryImplementation(SourceRoots src, SourceRoots test, AntProjectHelper helper, PropertyEvaluator eval)
createBinaryForSourceQueryImplementation(org.netbeans.modules.java.api.common.SourceRoots, org.netbeans.modules.java.api.common.SourceRoots, org.netbeans.spi.project.support.ant.AntProjectHelper, org.netbeans.spi.project.support.ant.PropertyEvaluator, java.lang.String, java.lang.String)
which assumes that build classes folder is stored in property build.classes.dir and
built test classes folder is stored in property build.test.classes.dir.src - project source rootstest - project test rootshelper - AntProjectHelpereval - PropertyEvaluatorsourceProps - array of properties pointing to source folderstestProps - array of properties pointing to test folderspublic static AnnotationProcessingQueryImplementation createAnnotationProcessingQuery(AntProjectHelper helper, PropertyEvaluator evaluator, String annotationProcessingEnabledProperty, String annotationProcessingEnabledInEditorProperty, String runAllAnnotationProcessorsProperty, String annotationProcessorsProperty, String sourceOutputProperty, String processorOptionsProperty)
helper - project's AntProjectHelperevaluator - project's evaluatorannotationProcessingEnabledProperty - property whose value says whether the annotation processing is enabled for the given project at all
(will be returned from Result#annotationProcessingEnabled())annotationProcessingEnabledInEditorProperty - property whose value says whether the annotation processing should be enabled
in the editor (will be returned from Result#annotationProcessingEnabled())runAllAnnotationProcessorsProperty - when true, Result#annotationProcessorsToRun() will return nullannotationProcessorsProperty - should contain comma separated list of annotation processors to run (will be returned from Result#annotationProcessorsToRun())sourceOutputProperty - directory to which the annotation processors generate source files (will be returned from Result#sourceOutputProperty())processorOptionsProperty - options passed to the annotation processors (-Akey=value)AnnotationProcessingQueryImplementation to provide annotation processing configuration data for this project.public static ProjectInformation createProjectInformation(AntProjectHelper projectHelper, Project project, Icon icon)
public static ProjectInformation createProjectInformation(UpdateHelper updateHelper, Project project, Icon icon)
public static Sources createSources(@NonNull Project project, @NonNull AntProjectHelper helper, @NonNull PropertyEvaluator evaluator, @NonNull Roots... roots)
Sources implementation designed for projects that supports adding
or removing of the source roots. The returned instance also implements SourceGroupModifierImplementationproject - the Project for which the Sources should be createdhelper - the AntProjectHelper of the project, used only to resolve filesevaluator - the PropertyEvaluator to evaluate the propertiesroots - the array of Roots providing the roots of given typeSources instance implementing also the SourceGroupModifierImplementation interfaceBuilt on May 19 2013. | Portions Copyright 1997-2013 Oracle. All rights reserved.