diff --git a/.idea/modules/enum-mapper-lib/enum-mapper-lib.iml b/.idea/modules/enum-mapper-lib/enum-mapper-lib.iml index 99d610e..e185dd9 100644 --- a/.idea/modules/enum-mapper-lib/enum-mapper-lib.iml +++ b/.idea/modules/enum-mapper-lib/enum-mapper-lib.iml @@ -1,5 +1,5 @@ - + diff --git a/.idea/modules/enum-mapper-lib/enum-mapper-lib_main.iml b/.idea/modules/enum-mapper-lib/enum-mapper-lib_main.iml index 6f5281c..12e982b 100644 --- a/.idea/modules/enum-mapper-lib/enum-mapper-lib_main.iml +++ b/.idea/modules/enum-mapper-lib/enum-mapper-lib_main.iml @@ -1,5 +1,5 @@ - + diff --git a/.idea/modules/enum-mapper-lib/enum-mapper-lib_test.iml b/.idea/modules/enum-mapper-lib/enum-mapper-lib_test.iml index 4b33445..5f96f9a 100644 --- a/.idea/modules/enum-mapper-lib/enum-mapper-lib_test.iml +++ b/.idea/modules/enum-mapper-lib/enum-mapper-lib_test.iml @@ -1,5 +1,5 @@ - + diff --git a/.idea/modules/enum-mapper-processor/enum-mapper-processor.iml b/.idea/modules/enum-mapper-processor/enum-mapper-processor.iml index 3e6649b..e137ddd 100644 --- a/.idea/modules/enum-mapper-processor/enum-mapper-processor.iml +++ b/.idea/modules/enum-mapper-processor/enum-mapper-processor.iml @@ -1,5 +1,5 @@ - + diff --git a/.idea/modules/enum-mapper-processor/enum-mapper-processor_main.iml b/.idea/modules/enum-mapper-processor/enum-mapper-processor_main.iml index cebb517..3080f75 100644 --- a/.idea/modules/enum-mapper-processor/enum-mapper-processor_main.iml +++ b/.idea/modules/enum-mapper-processor/enum-mapper-processor_main.iml @@ -1,5 +1,5 @@ - + @@ -10,14 +10,14 @@ + - - + \ No newline at end of file diff --git a/.idea/modules/enum-mapper-processor/enum-mapper-processor_test.iml b/.idea/modules/enum-mapper-processor/enum-mapper-processor_test.iml index 6c2d3f6..46c5d28 100644 --- a/.idea/modules/enum-mapper-processor/enum-mapper-processor_test.iml +++ b/.idea/modules/enum-mapper-processor/enum-mapper-processor_test.iml @@ -1,5 +1,5 @@ - + @@ -21,6 +21,7 @@ + diff --git a/enum-mapper-lib/src/main/java/com/tmtron/enums/EnumMapperPartial.java b/enum-mapper-lib/src/main/java/com/tmtron/enums/EnumMapperPartial.java index c77a261..11682b7 100644 --- a/enum-mapper-lib/src/main/java/com/tmtron/enums/EnumMapperPartial.java +++ b/enum-mapper-lib/src/main/java/com/tmtron/enums/EnumMapperPartial.java @@ -25,7 +25,7 @@ *

In comparison to {@link EnumMapperFull} it will not check if all enumerations constants are mapped. *

*

- * Note: this class does not allow for {@code null} values. You may use {@link java.util.Optional} as type. + * Note: this class does not allow for {@code null} values. You may use {@code java.util.Optional} as type. *

* * @param the enum-type diff --git a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFull.java b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFull.java index 2b1204a..d151736 100644 --- a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFull.java +++ b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFull.java @@ -75,24 +75,24 @@ public void testMapperOfThrowsOnMissingValues8() { } @Test(expected = IllegalArgumentException.class) - public void testBuilderThrowsOnMissingValues() throws Exception { + public void testBuilderThrowsOnMissingValues() { EnumMapperFull mapper = EnumMapperFull.builder(I1, "1") .put(I2, "2") .build(); } @Test - public void testGetOrDefault() throws Exception { + public void testGetOrDefault() { assertEquals(I7, fullMapper.getEnumOrDefault(77, I7)); } @Test - public void testGetOrNull() throws Exception { + public void testGetOrNull() { assertNull(fullMapper.getEnumOrNull(77)); } @Test(expected = IllegalArgumentException.class) - public void testGetOrRaise() throws Exception { + public void testGetOrRaise() { fullMapper.getEnumOrRaise(77); } diff --git a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFullExamples.java b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFullExamples.java index 4388530..14e05e5 100644 --- a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFullExamples.java +++ b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestEnumMapperFullExamples.java @@ -22,7 +22,7 @@ public class TestEnumMapperFullExamples { @Test - public void testBool() throws Exception { + public void testBool() { EnumMapperFull boolMapper = BoolEnum_MapperFull.setOFF("off") .setON("on"); assertEquals(TwoEnums_Source.BoolEnum.OFF, boolMapper.getEnumOrRaise("off")); @@ -33,7 +33,7 @@ public void testBool() throws Exception { } @Test - public void testColor() throws Exception { + public void testColor() { EnumMapperFull boolMapper = ColorEnum_MapperFull.setRED("red") .setBLUE("blue"); assertEquals(TwoEnums_Source.ColorEnum.RED, boolMapper.getEnumOrRaise("red")); diff --git a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestLauncherAge.java b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestLauncherAge.java index 6cfe0bc..d137afc 100644 --- a/enum-mapper-lib/src/test/java/com/tmtron/enums/TestLauncherAge.java +++ b/enum-mapper-lib/src/test/java/com/tmtron/enums/TestLauncherAge.java @@ -31,14 +31,14 @@ enum LauncherAge { .setOFFLINE("offline"); @Test - public void testLauncherAgeGetEnum() throws Exception { + public void testLauncherAgeGetEnum() { assertEquals(LauncherAge.ONLINE, testMapper.getEnumOrRaise("online")); assertEquals(LauncherAge.OLD, testMapper.getEnumOrRaise("old")); assertEquals(LauncherAge.OFFLINE, testMapper.getEnumOrRaise("offline")); } @Test - public void testLauncherAgeGetValues() throws Exception { + public void testLauncherAgeGetValues() { assertEquals("online", testMapper.getValue(LauncherAge.ONLINE)); assertEquals("old", testMapper.getValue(LauncherAge.OLD)); assertEquals("offline", testMapper.getValue(LauncherAge.OFFLINE)); diff --git a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapAllEnumsHandler.java b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapAllEnumsHandler.java index e912a0d..b80e9c3 100644 --- a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapAllEnumsHandler.java +++ b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapAllEnumsHandler.java @@ -43,7 +43,6 @@ class MapAllEnumsHandler { private static final String ENUMS_ID = "value"; private final ProcessingEnvironment processingEnvironment; private final Set annotatedElements; - ; /** * Will process an element (e.g. a class) which must have the {@link EnumMappers} annotation. diff --git a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapEnumElement.java b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapEnumElement.java index dd20d07..fc92460 100644 --- a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapEnumElement.java +++ b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/MapEnumElement.java @@ -44,7 +44,7 @@ class MapEnumElement { * Will process a single Enum class of the {@link EnumMappers} annotation. * * @param processingEnvironment the processing environment - * @param annotatedElements the element/s (e.g. classe) which has/have the {@link EnumMappers} annotation + * @param annotatedElements the element/s (e.g. classes) which has/have the {@link EnumMappers} annotation * @param enumsClassTypeElement a single Enum class from the "values" array of the {@link EnumMappers} annotation */ MapEnumElement(ProcessingEnvironment processingEnvironment, Collection annotatedElements, diff --git a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/WriteMapperFull.java b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/WriteMapperFull.java index 8b6f8da..9b96de3 100644 --- a/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/WriteMapperFull.java +++ b/enum-mapper-processor/src/main/java/com/tmtron/enums/processor/WriteMapperFull.java @@ -91,7 +91,7 @@ private AnnotationSpec createGeneratedAnnotation(Class annotationProcessorCla /** * Will add the required interfaces for the build-stages to the mapperFullTypeBuilder. *
    - *
  • we need no interface for the first enum-constant, becuase we create a static method for this
  • + *
  • we need no interface for the first enum-constant, because we create a static method for this
  • *
  • the last interface will return the fully initialized mapper
  • *
* diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMapper4Seasons.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMapper4Seasons.java index ee87525..fc63f42 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMapper4Seasons.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMapper4Seasons.java @@ -22,7 +22,7 @@ */ public class TestMapper4Seasons extends AnnotationProcessorTest { @Test - public void test() throws Exception { + public void test() { assertAboutEnumsProcessing(getJfoResource("Seasons.java")) .compilesWithoutWarnings() .and() diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4AllAnnotations.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4AllAnnotations.java index 873ce7c..e9e5a68 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4AllAnnotations.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4AllAnnotations.java @@ -23,7 +23,7 @@ */ public class TestMappers4AllAnnotations extends AnnotationProcessorTest { @Test - public void test() throws Exception { + public void test() { assertAboutEnumsProcessing(getJfoResource("AllAnnotations_Source.java")) .compilesWithoutWarnings() .and() diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4DuplicateEnums.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4DuplicateEnums.java index 3156394..102eda2 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4DuplicateEnums.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4DuplicateEnums.java @@ -27,7 +27,7 @@ public class TestMappers4DuplicateEnums extends AnnotationProcessorTest { *

*/ @Test - public void test() throws Exception { + public void test() { assertAboutEnumsProcessing(getJfoResource("DuplicateEnums_Source.java")) .compilesWithoutWarnings() .and() diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4SingleEnum.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4SingleEnum.java index 31d8a93..4b78b19 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4SingleEnum.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4SingleEnum.java @@ -41,7 +41,7 @@ public void testWarningMessage() { } @Test - public void testLauncherAgeMappingFull() throws Exception { + public void testLauncherAgeMappingFull() { assertAboutEnumsProcessing(source) .compilesWithoutWarnings() .and() diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4TwoEnums.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4TwoEnums.java index 2856421..e274d10 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4TwoEnums.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappers4TwoEnums.java @@ -19,7 +19,7 @@ public class TestMappers4TwoEnums extends AnnotationProcessorTest { @Test - public void test() throws Exception { + public void test() { assertAboutEnumsProcessing(getJfoResource("TwoEnums_Source.java")) .compilesWithoutWarnings() .and() diff --git a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappersOn2Classes.java b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappersOn2Classes.java index fb8bd0d..6bff851 100644 --- a/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappersOn2Classes.java +++ b/enum-mapper-processor/src/test/java/com/tmtron/enums/processor/TestMappersOn2Classes.java @@ -19,7 +19,7 @@ public class TestMappersOn2Classes extends AnnotationProcessorTest { @Test - public void test() throws Exception { + public void test() { assertAboutEnumsProcessing(getJfoResource("TwoClasses_Source.java")) .compilesWithoutWarnings() .and()