You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by ah...@apache.org on 2022/02/04 11:56:28 UTC

[isis] branch master updated: ISIS-2877: just adds missing diamond operator

This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
     new 6a7d48c  ISIS-2877: just adds missing diamond operator
6a7d48c is described below

commit 6a7d48cd08db8213e5de89b9896c54406b85eafe
Author: Andi Huber <ah...@apache.org>
AuthorDate: Fri Feb 4 12:56:22 2022 +0100

    ISIS-2877: just adds missing diamond operator
---
 .../isis/viewer/restfulobjects/applib/util/JsonMapper.java     | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/viewers/restfulobjects/applib/src/main/java/org/apache/isis/viewer/restfulobjects/applib/util/JsonMapper.java b/viewers/restfulobjects/applib/src/main/java/org/apache/isis/viewer/restfulobjects/applib/util/JsonMapper.java
index 6aefa52..0faa51d 100644
--- a/viewers/restfulobjects/applib/src/main/java/org/apache/isis/viewer/restfulobjects/applib/util/JsonMapper.java
+++ b/viewers/restfulobjects/applib/src/main/java/org/apache/isis/viewer/restfulobjects/applib/util/JsonMapper.java
@@ -48,7 +48,7 @@ import org.apache.isis.viewer.restfulobjects.applib.JsonRepresentation;
  */
 public final class JsonMapper {
 
-    public static String getEntityAsStringFrom(Response response) {
+    public static String getEntityAsStringFrom(final Response response) {
 
         final Object result = response.getEntity();
 
@@ -74,7 +74,7 @@ public final class JsonMapper {
 
     private static final class JsonRepresentationDeserializer extends JsonDeserializer<JsonRepresentation> {
         @Override
-        public JsonRepresentation deserialize(JsonParser jp, DeserializationContext ctxt) throws IOException {
+        public JsonRepresentation deserialize(final JsonParser jp, final DeserializationContext ctxt) throws IOException {
             JsonNode node = jp.getCodec().readTree(jp);
             return new JsonRepresentation(node);
         }
@@ -89,7 +89,7 @@ public final class JsonMapper {
         }
     }
 
-    private static ObjectMapper createObjectMapper(PrettyPrinting prettyPrinting) {
+    private static ObjectMapper createObjectMapper(final PrettyPrinting prettyPrinting) {
         final ObjectMapper objectMapper = new ObjectMapper();
         final SimpleModule jsonModule = new SimpleModule("json", new Version(1, 0, 0, null, "org.apache", "isis"));
         jsonModule.addDeserializer(JsonRepresentation.class, new JsonRepresentationDeserializer());
@@ -103,7 +103,7 @@ public final class JsonMapper {
         return objectMapper;
     }
 
-    private static Map<PrettyPrinting, JsonMapper> instanceByConfig = new ConcurrentHashMap();
+    private static Map<PrettyPrinting, JsonMapper> instanceByConfig = new ConcurrentHashMap<>();
 
     /**
      * Returns a {@link org.apache.isis.viewer.restfulobjects.applib.util.JsonMapper.PrettyPrinting#ENABLE pretty-printing enabled} JSON mapper.
@@ -126,7 +126,7 @@ public final class JsonMapper {
 
     private final ObjectMapper objectMapper;
 
-    private JsonMapper(PrettyPrinting prettyPrinting) {
+    private JsonMapper(final PrettyPrinting prettyPrinting) {
         objectMapper = createObjectMapper(prettyPrinting);
     }