Skip to content

Commit

Permalink
Resolved most linting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
barrycaceres committed Jan 17, 2025
1 parent 1596fb0 commit 10813a7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
8 changes: 2 additions & 6 deletions src/main/java/com/senzing/sdk/core/SzCoreEnvironment.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,6 @@
import com.senzing.sdk.SzConfigManager;
import com.senzing.sdk.SzEngine;
import com.senzing.sdk.SzDiagnostic;
import com.senzing.sdk.SzUnknownDataSourceException;
import com.senzing.sdk.SzReplaceConflictException;
import com.senzing.sdk.SzNotFoundException;
import com.senzing.sdk.SzBadInputException;

/**
* Provides the core implementation of {@link SzEnvironment} that directly
Expand Down Expand Up @@ -79,8 +75,8 @@ public final class SzCoreEnvironment implements SzEnvironment {
private static final Map<Integer, Class<? extends SzException>> EXCEPTION_MAP;

static {
Map<Integer,Class<? extends SzException>> map = new LinkedHashMap<>();
Map<Integer,Class<? extends SzException>> result = new LinkedHashMap<>();
Map<Integer, Class<? extends SzException>> map = new LinkedHashMap<>();
Map<Integer, Class<? extends SzException>> result = new LinkedHashMap<>();
SzExceptionMapper.registerExceptions(map);
map.forEach((errorCode, exceptionClass) -> {
if (exceptionClass != SzException.class) {
Expand Down
5 changes: 4 additions & 1 deletion src/main/java/com/senzing/sdk/core/SzExceptionMapper.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* Package-access class for mapping Senzing error code to
* instances of {@link SzException}.
*/
class SzExceptionMapper {
final class SzExceptionMapper {
/**
* Private constructor since all methods are static.
*/
Expand All @@ -17,6 +17,9 @@ private SzExceptionMapper() {

/**
* Obtains the exception class for the specified error code.
*
* @param map The {@link Map} to which to add the mappings of
* error code keys and exception class objects.
*/
public static void registerExceptions(Map<Integer, Class<? extends SzException>> map) {
map.put(2, SzBadInputException.class);
Expand Down

0 comments on commit 10813a7

Please sign in to comment.