Class ModuleDependency.Builder

java.lang.Object
org.wildfly.testing.tools.modules.ModuleDependency.Builder
Enclosing class:
ModuleDependency

public static class ModuleDependency.Builder extends Object
Builds a module dependency.
Author:
James R. Perkins
  • Method Details

    • optional

      public ModuleDependency.Builder optional(boolean optional)
      Whether the dependency should be optional or not.
      Parameters:
      optional - true if the dependency should be optional
      Returns:
      this builder
    • export

      public ModuleDependency.Builder export(boolean export)
      Whether the dependency should be exported or not.
      Parameters:
      export - true if the dependency should be exported
      Returns:
      this builder
    • services

      Define the value for the dependencies services attribute.
      Parameters:
      services - the value for the service attribute
      Returns:
      this builder
    • addImportFilter

      public ModuleDependency.Builder addImportFilter(ModuleDependency.Filter filter)
      Adds an import filter for the dependency.
      Parameters:
      filter - the import filter
      Returns:
      this builder
    • addImportFilter

      public ModuleDependency.Builder addImportFilter(String path, boolean include)
      Adds an import filter for the dependency.
      Parameters:
      path - the path to filter
      include - true if the path should be included, false if the path should be excluded
      Returns:
      this builder
    • addImportFilters

      public ModuleDependency.Builder addImportFilters(ModuleDependency.Filter... filters)
      Adds the filters as import filters for the dependency.
      Parameters:
      filters - the filters to add
      Returns:
      this builder
    • addImportFilters

      public ModuleDependency.Builder addImportFilters(Collection<ModuleDependency.Filter> filters)
      Adds the filters as import filters for the dependency.
      Parameters:
      filters - the filters to add
      Returns:
      this builder
    • addExportFilter

      public ModuleDependency.Builder addExportFilter(ModuleDependency.Filter filter)
      Adds an export filter for the dependency.
      Parameters:
      filter - the export filter
      Returns:
      this builder
    • addExportFilter

      public ModuleDependency.Builder addExportFilter(String path, boolean include)
      Adds an export filter for the dependency.
      Parameters:
      path - the path to filter
      include - true if the path should be included, false if the path should be excluded
      Returns:
      this builder
    • addExportFilters

      public ModuleDependency.Builder addExportFilters(ModuleDependency.Filter... filters)
      Adds the filters as export filters for the dependency.
      Parameters:
      filters - the filters to add
      Returns:
      this builder
    • addExportFilters

      public ModuleDependency.Builder addExportFilters(Collection<ModuleDependency.Filter> filters)
      Adds the filters as export filters for the dependency.
      Parameters:
      filters - the filters to add
      Returns:
      this builder
    • build

      public ModuleDependency build()
      Creates the module dependency.
      Returns:
      the module dependency