Package com.diffplug.spotless.extra
Class EclipseBasedStepBuilder.State
- java.lang.Object
-
- com.diffplug.spotless.extra.EclipseBasedStepBuilder.State
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- EclipseBasedStepBuilder
public static class EclipseBasedStepBuilder.State extends java.lang.Object implements java.io.Serializable
State of Eclipse configuration items, providing functionality to derived information based on the state.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
State(java.lang.String formatterVersion, java.lang.String formatterStepExt, Provisioner jarProvisioner, java.util.List<java.lang.String> dependencies, java.lang.Iterable<java.io.File> settingsFiles)
State constructor expects that all passed items are not modified afterwards
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<java.lang.String>
getMavenCoordinate(java.lang.String prefix)
Returns first coordinate from sorted set that starts with a given prefix.java.util.Properties
getPreferences()
Get formatter preferencesjava.lang.String
getSemanticVersion()
java.lang.Class<?>
loadClass(java.lang.String name)
Load class based on the given configuration of JAR provider and Maven coordinates.
-
-
-
Constructor Detail
-
State
protected State(java.lang.String formatterVersion, java.lang.String formatterStepExt, Provisioner jarProvisioner, java.util.List<java.lang.String> dependencies, java.lang.Iterable<java.io.File> settingsFiles) throws java.io.IOException
State constructor expects that all passed items are not modified afterwards- Throws:
java.io.IOException
-
-
Method Detail
-
getSemanticVersion
public java.lang.String getSemanticVersion()
-
getPreferences
public java.util.Properties getPreferences()
Get formatter preferences
-
getMavenCoordinate
public java.util.Optional<java.lang.String> getMavenCoordinate(java.lang.String prefix)
Returns first coordinate from sorted set that starts with a given prefix.
-
loadClass
public java.lang.Class<?> loadClass(java.lang.String name)
Load class based on the given configuration of JAR provider and Maven coordinates. Different class loader instances are provided in the following scenarios:- The JARs (
jarState
) have changes (this should only occur during development) - Different configurations (
settingsFiles
) are used for different sub-projects - The same Eclipse step implementation provides different formatter types (
formatterStepExt
)
- The JARs (
-
-