BuildInputBuilder¶
-
public class
BuildInputBuilder
¶ Fluent interface for creating
BuildInput
objects.See also:
BuildInput
Methods¶
addComponent¶
-
public BuildInputBuilder
addComponent
(ILanguageComponent component)¶ Adds languages from given language component.
addComponents¶
-
public BuildInputBuilder
addComponents
(Iterable<? extends ILanguageComponent> components)¶ Adds languages from given language components.
addIdentifiedSources¶
-
public BuildInputBuilder
addIdentifiedSources
(Iterable<IdentifiedResource> sources)¶ Add addition source changes from given identified sources.
addIncludePaths¶
-
public BuildInputBuilder
addIncludePaths
(ILanguageImpl language, Iterable<FileObject> includePaths)¶ Add given include files for given language.
addLanguage¶
-
public BuildInputBuilder
addLanguage
(ILanguageImpl language)¶ Adds a single language implementation.
addLanguages¶
-
public BuildInputBuilder
addLanguages
(Iterable<? extends ILanguageImpl> languages)¶ Adds given language implementations.
addPardonedLanguage¶
-
public BuildInputBuilder
addPardonedLanguage
(ILanguageImpl pardonedLanguage)¶ Adds a single pardoned language.
addPardonedLanguageString¶
-
public BuildInputBuilder
addPardonedLanguageString
(String pardonedLanguage)¶ Adds a single pardoned language from given language name.
addSource¶
-
public BuildInputBuilder
addSource
(IdentifiedResource source)¶ Adds a single addition source change from given identified source.
addSource¶
-
public BuildInputBuilder
addSource
(FileObject source)¶ Adds a single addition source change from given source.
addSourceChanges¶
-
public BuildInputBuilder
addSourceChanges
(Iterable<ResourceChange> sourceChanges)¶ Adds a source change.
addSources¶
-
public BuildInputBuilder
addSources
(Iterable<FileObject> sources)¶ Add addition source changes from given sources.
addSourcesFromSourceLocations¶
-
public BuildInputBuilder
addSourcesFromSourceLocations
(Iterable<FileObject> sourceLocations)¶ Add addition source changes from source files at given source locations.
addTransformGoal¶
-
public BuildInputBuilder
addTransformGoal
(ITransformGoal goal)¶ Adds a single transform goal.
build¶
-
public BuildInput
build
(IDependencyService dependencyService, ILanguagePathService languagePathService)¶ Builds a build input object from the current state.
Throws: - MetaborgException – When
IDependencyService.compileDeps
throws.
- MetaborgException – When
reset¶
-
public BuildInputBuilder
reset
()¶ Resets the builder to its original state.
withAnalysis¶
-
public BuildInputBuilder
withAnalysis
(boolean analyze)¶ Sets if analysis should be executed. Defaults to true.
withAnalyzeSelector¶
-
public BuildInputBuilder
withAnalyzeSelector
(FileSelector analyzeSelector)¶ Sets the analysis file selector to given selector.
withCompileDependencyLanguages¶
-
public BuildInputBuilder
withCompileDependencyLanguages
(boolean addDependencyLanguages)¶ Sets if compile time dependencies should be added to languages when the input is built. Defaults to true.
withComponents¶
-
public BuildInputBuilder
withComponents
(Iterable<ILanguageComponent> components)¶ Sets the languages from given language components.
withDefaultIncludePaths¶
-
public BuildInputBuilder
withDefaultIncludePaths
(boolean addDefaultIncludePaths)¶ Sets if default include files should be added when the input is build. Defaults to true.
withIncludePaths¶
-
public BuildInputBuilder
withIncludePaths
(Multimap<ILanguageImpl, FileObject> includePaths)¶ Sets the include files to given files.
withLanguages¶
-
public BuildInputBuilder
withLanguages
(Set<ILanguageImpl> languages)¶ Sets the languages to given language implementations.
withLanguages¶
-
public BuildInputBuilder
withLanguages
(Iterable<ILanguageImpl> languages)¶ Sets the languages to given language implementations.
withMessagePrinter¶
-
public BuildInputBuilder
withMessagePrinter
(IMessagePrinter messagePrinter)¶ Sets the message printer to given message printer.
withPardonedLanguageStrings¶
-
public BuildInputBuilder
withPardonedLanguageStrings
(Iterable<String> pardonedLanguages)¶ Set the pardoned languages from given language names.
withPardonedLanguages¶
-
public BuildInputBuilder
withPardonedLanguages
(Set<ILanguageImpl> pardonedLanguages)¶ Set the pardoned languages from given set of pardoned languages.
withSelector¶
-
public BuildInputBuilder
withSelector
(FileSelector selector)¶ Sets the file selector to given selector.
withSourceChanges¶
-
public BuildInputBuilder
withSourceChanges
(Collection<ResourceChange> sourceChanges)¶ Sets the source changes to given resource changes.
withSourceChanges¶
-
public BuildInputBuilder
withSourceChanges
(Iterable<ResourceChange> sourceChanges)¶ Sets the source changes to given resource changes.
withSources¶
-
public BuildInputBuilder
withSources
(Iterable<FileObject> sources)¶ Set the source changes to additions from given sources.
withSourcesFromDefaultSourceLocations¶
-
public BuildInputBuilder
withSourcesFromDefaultSourceLocations
(boolean addSourcesFromDefaultSourceLocations)¶ Sets if addition source changes should be added from source at default source locations, when the input is built. Defaults to false.
withState¶
-
public BuildInputBuilder
withState
(BuildState state)¶ Sets the build state to given build state.
withThrowOnErrors¶
-
public BuildInputBuilder
withThrowOnErrors
(boolean throwOnErrors)¶ Sets if a runtime exception should be thrown when errors occur. Defaults to false.
withTransformGoals¶
-
public BuildInputBuilder
withTransformGoals
(Collection<ITransformGoal> transformGoals)¶ Sets the transform goals to given transform goals.
withTransformSelector¶
-
public BuildInputBuilder
withTransformSelector
(FileSelector transformSelector)¶ Sets the transformation file selector to given selector.
withTransformation¶
-
public BuildInputBuilder
withTransformation
(boolean transform)¶ Sets if transformations should be executed. Defaults to true.