Skip to content

Commit 84fbf9b

Browse files
committed
Lint
1 parent 5c2343e commit 84fbf9b

2 files changed

Lines changed: 18 additions & 15 deletions

File tree

‎src/main/java/com/azuredoom/levelingcore/config/ConfigBootstrap.java‎

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88

99
/**
1010
* ConfigBootstrap is a utility class that initializes and configures the core components of the LevelingCore system.
11-
* This includes loading configuration settings, setting up database connections, initializing the leveling formula,
12-
* and creating a level service for managing levels and experience points (XP).
11+
* This includes loading configuration settings, setting up database connections, initializing the leveling formula, and
12+
* creating a level service for managing levels and experience points (XP).
1313
* <p>
1414
* This class cannot be instantiated and provides a static method to bootstrap the system.
1515
*/
@@ -18,16 +18,19 @@ public final class ConfigBootstrap {
1818
private ConfigBootstrap() {}
1919

2020
/**
21-
* Record Bootstrap is a utility data holder used during the initialization of the LevelingCore system.
22-
* It encapsulates core parts necessary for the functionality of the leveling system. The record is
23-
* primarily designed to simplify the return of multiple related objects from the bootstrap process.
21+
* Record Bootstrap is a utility data holder used during the initialization of the LevelingCore system. It
22+
* encapsulates core parts necessary for the functionality of the leveling system. The record is primarily designed
23+
* to simplify the return of multiple related objects from the bootstrap process.
2424
*/
25-
public record Bootstrap(LevelService service, AutoCloseable closeable) {}
25+
public record Bootstrap(
26+
LevelService service,
27+
AutoCloseable closeable
28+
) {}
2629

2730
/**
2831
* Initializes and configures the essential parts of the LevelingCore system. This method sets up the leveling
29-
* formula, loads configuration settings, establishes a database connection, and prepares the leveling service.
30-
* It also handles any necessary migration of XP formulas when specified in the configuration.
32+
* formula, loads configuration settings, establishes a database connection, and prepares the leveling service. It
33+
* also handles any necessary migration of XP formulas when specified in the configuration.
3134
*
3235
* @return A {@code Bootstrap} record containing the initialized {@code LevelService} and a {@code closeable}
3336
* resource for managing the cleanup of associated resources.
@@ -37,10 +40,10 @@ public static Bootstrap bootstrap() {
3740
var formulaDescriptor = LevelFormulaFactory.descriptorFromConfig(config);
3841
var formula = LevelFormulaFactory.fromConfig(config);
3942
var ds = DataSourceFactory.create(
40-
config.database.jdbcUrl,
41-
config.database.username,
42-
config.database.password,
43-
config.database.maxPoolSize
43+
config.database.jdbcUrl,
44+
config.database.username,
45+
config.database.password,
46+
config.database.maxPoolSize
4447
);
4548
var repo = new JdbcLevelRepository(ds);
4649

‎src/main/java/com/azuredoom/levelingcore/database/JdbcLevelRepository.java‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -348,9 +348,9 @@ public boolean exists(UUID id) {
348348
/**
349349
* Closes the underlying JDBC datasource if it implements {@link AutoCloseable}.
350350
* <p>
351-
* This method attempts to close the {@code dataSource} resource gracefully. If the {@code dataSource}
352-
* is an instance of {@code AutoCloseable}, its {@code close()} method is invoked. Any exception
353-
* raised during the closing process is caught and wrapped in a {@link LevelingCoreException}.
351+
* This method attempts to close the {@code dataSource} resource gracefully. If the {@code dataSource} is an
352+
* instance of {@code AutoCloseable}, its {@code close()} method is invoked. Any exception raised during the closing
353+
* process is caught and wrapped in a {@link LevelingCoreException}.
354354
*
355355
* @throws LevelingCoreException if an error occurs while closing the {@code dataSource}.
356356
*/

0 commit comments

Comments
 (0)