Package eu.maveniverse.domtrip.maven
Class AlignOptions.Builder
- java.lang.Object
-
- eu.maveniverse.domtrip.maven.AlignOptions.Builder
-
- Enclosing class:
- AlignOptions
public static final class AlignOptions.Builder extends java.lang.ObjectBuilder forAlignOptions.- Since:
- 1.1.0
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AlignOptionsbuild()Create an AlignOptions configured with the builder's current settings.AlignOptions.BuildernamingConvention(AlignOptions.PropertyNamingConvention namingConvention)Sets the property naming convention override.AlignOptions.BuilderpropertyName(java.lang.String propertyName)Sets an explicit property name, overriding auto-generation.AlignOptions.BuilderpropertyNameGenerator(java.util.function.Function<Coordinates,java.lang.String> generator)Set a custom function that generates property names from dependency coordinates.AlignOptions.Builderscope(java.lang.String scope)Sets the dependency scope.AlignOptions.BuilderversionSource(AlignOptions.VersionSource versionSource)Sets the version source override.AlignOptions.BuilderversionStyle(AlignOptions.VersionStyle versionStyle)Sets the version style override.
-
-
-
Method Detail
-
versionStyle
public AlignOptions.Builder versionStyle(AlignOptions.VersionStyle versionStyle)
Sets the version style override.- Parameters:
versionStyle- the version style (null for auto-detection)- Returns:
- this builder
-
versionSource
public AlignOptions.Builder versionSource(AlignOptions.VersionSource versionSource)
Sets the version source override.- Parameters:
versionSource- the version source (null for auto-detection)- Returns:
- this builder
-
namingConvention
public AlignOptions.Builder namingConvention(AlignOptions.PropertyNamingConvention namingConvention)
Sets the property naming convention override.- Parameters:
namingConvention- the naming convention (null for auto-detection)- Returns:
- this builder
-
propertyNameGenerator
public AlignOptions.Builder propertyNameGenerator(java.util.function.Function<Coordinates,java.lang.String> generator)
Set a custom function that generates property names from dependency coordinates.Allows arbitrary naming patterns beyond the built-in conventions.
Example:
.propertyNameGenerator(coords -> coords.groupId().replace(".", "-") + "." + coords.artifactId() + ".version")- Parameters:
generator- the function to generate property names (null to clear)- Returns:
- this builder
- Since:
- 1.1.0
-
propertyName
public AlignOptions.Builder propertyName(java.lang.String propertyName)
Sets an explicit property name, overriding auto-generation.- Parameters:
propertyName- the property name to use- Returns:
- this builder
-
scope
public AlignOptions.Builder scope(java.lang.String scope)
Sets the dependency scope.- Parameters:
scope- the scope (e.g., "test", "provided")- Returns:
- this builder
-
build
public AlignOptions build()
Create an AlignOptions configured with the builder's current settings.No validation or additional processing is performed; the builder's field values (which may be
null) are copied directly into the created instance.- Returns:
- the constructed AlignOptions
-
-