Adapt to Gerrit 2.14 and Java 8

Change-Id: I78f9c208ffaa87bc24a61784ed37c20722034f47
diff --git a/src/main/java/com/googlesource/gerrit/plugins/scripting/scala/ScalaPluginScanner.java b/src/main/java/com/googlesource/gerrit/plugins/scripting/scala/ScalaPluginScanner.java
index e3135dd..ab170ae 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/scripting/scala/ScalaPluginScanner.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/scripting/scala/ScalaPluginScanner.java
@@ -13,7 +13,7 @@
 // limitations under the License.
 package com.googlesource.gerrit.plugins.scripting.scala;
 
-import com.google.common.base.Optional;
+import java.util.Optional;
 import com.google.gerrit.server.plugins.AbstractPreloadedPluginScanner;
 import com.google.gerrit.server.plugins.InvalidPluginException;
 import com.google.gerrit.server.plugins.Plugin;
diff --git a/src/main/java/com/googlesource/gerrit/plugins/web/WebPluginScanner.java b/src/main/java/com/googlesource/gerrit/plugins/web/WebPluginScanner.java
index f2af09b..2a8815c 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/web/WebPluginScanner.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/web/WebPluginScanner.java
@@ -13,7 +13,7 @@
 // limitations under the License.
 package com.googlesource.gerrit.plugins.web;
 
-import com.google.common.base.Optional;
+import java.util.Optional;
 import com.google.common.collect.Lists;
 import com.google.gerrit.server.plugins.InvalidPluginException;
 import com.google.gerrit.server.plugins.PluginContentScanner;
@@ -62,7 +62,7 @@
     if (Files.exists(resourceFile) && Files.size(resourceFile) > 0) {
       return resourceOf(resourcePath);
     } else {
-      return Optional.absent();
+      return Optional.empty();
     }
   }
 
@@ -78,7 +78,7 @@
             Optional.of(fileSize)));
       }
     } else {
-      return Optional.absent();
+      return Optional.empty();
     }
   }