diff --git a/java-client/src/main/java/org/opensearch/client/json/JsonpMappingException.java b/java-client/src/main/java/org/opensearch/client/json/JsonpMappingException.java index f410889d06..ee5e3a61db 100644 --- a/java-client/src/main/java/org/opensearch/client/json/JsonpMappingException.java +++ b/java-client/src/main/java/org/opensearch/client/json/JsonpMappingException.java @@ -149,4 +149,3 @@ private static JsonpMappingException from0(Throwable cause, Object ref, Object p return jme.prepend0(ref, pathItem); } } - diff --git a/java-client/src/main/java/org/opensearch/client/json/JsonpUtils.java b/java-client/src/main/java/org/opensearch/client/json/JsonpUtils.java index 899bc60c51..98c87b9e28 100644 --- a/java-client/src/main/java/org/opensearch/client/json/JsonpUtils.java +++ b/java-client/src/main/java/org/opensearch/client/json/JsonpUtils.java @@ -76,7 +76,7 @@ static JsonProvider findProvider() { RuntimeException exception; try { return JsonProvider.provider(); - } catch(RuntimeException re) { + } catch (RuntimeException re) { exception = re; } @@ -85,13 +85,13 @@ static JsonProvider findProvider() { try { return ServiceLoader.load(JsonProvider.class, JsonpUtils.class.getClassLoader()).iterator().next(); - } catch(Exception e) { + } catch (Exception e) { // ignore } try { return ServiceLoader.load(JsonProvider.class, JsonProvider.class.getClassLoader()).iterator().next(); - } catch(Exception e) { + } catch (Exception e) { // ignore } @@ -148,7 +148,7 @@ public static void skipValue(JsonParser parser) { * Skip the value at the current position of the parser. */ public static void skipValue(JsonParser parser, Event event) { - switch(event) { + switch (event) { case START_OBJECT: parser.skipObject(); break; @@ -248,7 +248,10 @@ public static void serialize(T value, JsonGenerator generator, @Nullable Jso * (the object has been consumed from the original one). */ public static Map.Entry lookAheadFieldValue( - String name, String defaultValue, JsonParser parser, JsonpMapper mapper + String name, + String defaultValue, + JsonParser parser, + JsonpMapper mapper ) { JsonLocation location = parser.getLocation();