Upgraded source/target version of Java from 1.6 to 1.8
authorKai Moritz <kai@juplo.de>
Fri, 5 Apr 2019 08:48:14 +0000 (10:48 +0200)
committerKai Moritz <kai@juplo.de>
Fri, 5 Apr 2019 13:07:38 +0000 (15:07 +0200)
pom.xml
src/main/java/de/juplo/plugins/hibernate/AbstractSchemaMojo.java

diff --git a/pom.xml b/pom.xml
index f4789fa..a75909c 100644 (file)
--- a/pom.xml
+++ b/pom.xml
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-compiler-plugin</artifactId>
         <configuration>
-          <source>1.6</source>
-          <target>1.6</target>
+          <source>1.8</source>
+          <target>1.8</target>
           <encoding>utf8</encoding>
           <showWarnings>true</showWarnings>
         </configuration>
index 72ec9d4..b7acbf0 100644 (file)
@@ -1396,8 +1396,7 @@ public abstract class AbstractSchemaMojo extends AbstractMojo
         PersistenceXmlParser.locatePersistenceUnits(settings);
 
     // Find all persistent units in the located descriptors
-    Map<String, ParsedPersistenceXmlDescriptor> units =
-        new HashMap<String, ParsedPersistenceXmlDescriptor>();
+    Map<String, ParsedPersistenceXmlDescriptor> units = new HashMap<>();
     for (ParsedPersistenceXmlDescriptor descriptor : descriptors)
     {
       String unit = descriptor.getName();