From 06822398e118ac4594b295f042b6c8259a246737 Mon Sep 17 00:00:00 2001 From: Robert Varga Date: Mon, 6 Sep 2021 16:43:20 +0200 Subject: [PATCH] Correct argument type documentation We have switched to using yang.common.Empty instead of java.lang.Void due to nullability. Unfortunately not all javadocs were correct updated, this corrects that mistake. Change-Id: I1c183fa45374907401c22107e00452184137b43a Signed-off-by: Robert Varga (cherry picked from commit 2d0d3dc452df9c94462ddeca4192291fc378b951) --- .../yang/model/api/meta/DeclaredStatement.java | 3 ++- .../AbstractDeclaredEffectiveStatement.java | 17 +++++++++-------- .../spi/meta/AbstractEffectiveStatement.java | 3 ++- .../AbstractUndeclaredEffectiveStatement.java | 9 +++++---- 4 files changed, 18 insertions(+), 14 deletions(-) diff --git a/model/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/meta/DeclaredStatement.java b/model/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/meta/DeclaredStatement.java index 11e5bb1265..0f45ed79ae 100644 --- a/model/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/meta/DeclaredStatement.java +++ b/model/yang-model-api/src/main/java/org/opendaylight/yangtools/yang/model/api/meta/DeclaredStatement.java @@ -16,11 +16,12 @@ import java.util.Optional; import java.util.stream.Stream; import org.eclipse.jdt.annotation.NonNull; import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.common.Empty; /** * Represents declared statement. * - * @param Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) */ public interface DeclaredStatement extends ModelStatement { /** diff --git a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractDeclaredEffectiveStatement.java b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractDeclaredEffectiveStatement.java index 3d0490b2b3..6848d989c6 100644 --- a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractDeclaredEffectiveStatement.java +++ b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractDeclaredEffectiveStatement.java @@ -17,6 +17,7 @@ import java.util.Map; import java.util.Optional; import org.eclipse.jdt.annotation.NonNull; import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.common.Empty; import org.opendaylight.yangtools.yang.common.QName; import org.opendaylight.yangtools.yang.model.api.DataNodeContainer; import org.opendaylight.yangtools.yang.model.api.DataSchemaNode; @@ -38,7 +39,7 @@ import org.opendaylight.yangtools.yang.model.api.stmt.SchemaTreeEffectiveStateme * {@link UnsupportedOperationException} from {@link #getDeclared()}, rendering any services relying on declared * statement to be not available. * - * @param Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. */ @Beta @@ -56,7 +57,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -89,7 +90,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -112,7 +113,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. */ public abstract static class Default> @@ -139,7 +140,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. */ public abstract static class DefaultArgument> extends Default { @@ -182,7 +183,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. */ public abstract static class DefaultWithArgument> extends Default { @@ -218,7 +219,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -274,7 +275,7 @@ public abstract class AbstractDeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ diff --git a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractEffectiveStatement.java b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractEffectiveStatement.java index d46dbebbe7..8f523381af 100644 --- a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractEffectiveStatement.java +++ b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractEffectiveStatement.java @@ -16,6 +16,7 @@ import java.util.LinkedHashMap; import java.util.Map; import java.util.Optional; import org.eclipse.jdt.annotation.NonNull; +import org.opendaylight.yangtools.yang.common.Empty; import org.opendaylight.yangtools.yang.common.QName; import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement; import org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement; @@ -34,7 +35,7 @@ import org.opendaylight.yangtools.yang.model.api.stmt.SchemaTreeEffectiveStateme * This finds immense value in catering the common case, for example effective statements which can, but typically * do not, contain substatements. * - * @param Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. */ abstract class AbstractEffectiveStatement> diff --git a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractUndeclaredEffectiveStatement.java b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractUndeclaredEffectiveStatement.java index a8799594a3..895f545b8d 100644 --- a/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractUndeclaredEffectiveStatement.java +++ b/model/yang-model-spi/src/main/java/org/opendaylight/yangtools/yang/model/spi/meta/AbstractUndeclaredEffectiveStatement.java @@ -17,6 +17,7 @@ import java.util.Map; import java.util.Optional; import org.eclipse.jdt.annotation.NonNull; import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.common.Empty; import org.opendaylight.yangtools.yang.common.QName; import org.opendaylight.yangtools.yang.model.api.DataNodeContainer; import org.opendaylight.yangtools.yang.model.api.DataSchemaNode; @@ -46,7 +47,7 @@ public abstract class AbstractUndeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -79,7 +80,7 @@ public abstract class AbstractUndeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -101,7 +102,7 @@ public abstract class AbstractUndeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ @@ -147,7 +148,7 @@ public abstract class AbstractUndeclaredEffectiveStatement Argument type ({@link Void} if statement does not have argument.) + * @param Argument type ({@link Empty} if statement does not have argument.) * @param Class representing declared version of this statement. * @param Class representing effective version of this statement. */ -- 2.36.6