From 69a459772a92982eb7de384eab247f5b0da76167 Mon Sep 17 00:00:00 2001 From: Robert Varga Date: Mon, 2 Oct 2023 14:09:20 +0200 Subject: [PATCH] Make AbstractNetconfOperation.handle() final We do not want to have a byzantine overrides when there is an extension point. This locks the method down by making it final. Change-Id: I974d6944a51d579607a422a8ced4d6917e470be5 Signed-off-by: Robert Varga --- .../server/api/operations/AbstractNetconfOperation.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/protocol/netconf-server/src/main/java/org/opendaylight/netconf/server/api/operations/AbstractNetconfOperation.java b/protocol/netconf-server/src/main/java/org/opendaylight/netconf/server/api/operations/AbstractNetconfOperation.java index 42b6200869..2d3c8b53fe 100644 --- a/protocol/netconf-server/src/main/java/org/opendaylight/netconf/server/api/operations/AbstractNetconfOperation.java +++ b/protocol/netconf-server/src/main/java/org/opendaylight/netconf/server/api/operations/AbstractNetconfOperation.java @@ -33,9 +33,8 @@ public abstract class AbstractNetconfOperation implements NetconfOperation { } @Override - public HandlingPriority canHandle(final Document message) throws DocumentedException { - OperationNameAndNamespace operationNameAndNamespace = null; - operationNameAndNamespace = new OperationNameAndNamespace(message); + public final HandlingPriority canHandle(final Document message) throws DocumentedException { + final var operationNameAndNamespace = new OperationNameAndNamespace(message); return canHandle(operationNameAndNamespace.getOperationName(), operationNameAndNamespace.getNamespace()); } -- 2.36.6