From: lubos-cicut Date: Wed, 7 Feb 2024 09:34:15 +0000 (+0100) Subject: Delete all always null returning methods X-Git-Tag: v7.0.0~50 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=e36bc7c4e26d86dc64c6c1f315a8785219213620;p=netconf.git Delete all always null returning methods Removed methods in restconf-openapi which always return null. These are the remnants from implementation rewrite done in NETCONF-938. Change-Id: I43d8bffeb2ba1df2d6a5bba70715ce0c2e307fa4 Signed-off-by: lubos-cicut --- diff --git a/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/OperationEntity.java b/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/OperationEntity.java index ef7ded61d9..efc64503c1 100644 --- a/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/OperationEntity.java +++ b/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/OperationEntity.java @@ -100,10 +100,6 @@ public abstract sealed class OperationEntity extends OpenApiEntity permits Delet protected @NonNull abstract String operation(); - @Nullable Boolean deprecated() { - return Boolean.FALSE; - } - @NonNull String description() { return schema == null ? "" : schema.getDescription().orElse(""); } diff --git a/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/PathEntity.java b/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/PathEntity.java index 2d5c2ac9ff..cd0ff861dc 100644 --- a/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/PathEntity.java +++ b/restconf/restconf-openapi/src/main/java/org/opendaylight/restconf/openapi/model/PathEntity.java @@ -34,18 +34,6 @@ public final class PathEntity extends OpenApiEntity { @Override public void generate(@NonNull JsonGenerator generator) throws IOException { generator.writeObjectFieldStart(path); - final var ref = ref(); - if (ref != null) { - generator.writeStringField("$ref", ref); - } - final var summary = summary(); - if (summary != null) { - generator.writeStringField("summary", summary); - } - final var description = description(); - if (ref != null) { - generator.writeStringField("description", description); - } final var postOperation = post(); if (postOperation != null) { postOperation.generate(generator); @@ -69,18 +57,6 @@ public final class PathEntity extends OpenApiEntity { generator.writeEndObject(); } - @Nullable String ref() { - return null; - } - - @Nullable String summary() { - return null; - } - - @Nullable String description() { - return null; - } - @Nullable OperationEntity post() { return post; }