diff --git a/make/jdk/src/classes/build/tools/taglet/SealedGraph.java b/make/jdk/src/classes/build/tools/taglet/SealedGraph.java index fd1b73355b3..17867b99595 100644 --- a/make/jdk/src/classes/build/tools/taglet/SealedGraph.java +++ b/make/jdk/src/classes/build/tools/taglet/SealedGraph.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022, 2023, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2022, 2024, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -107,7 +107,7 @@ public String toString(List tags, Element element) { throw new RuntimeException(e); } - String simpleTypeName = element.getSimpleName().toString(); + String simpleTypeName = packagelessCanonicalName(typeElement).replace('.', '/'); String imageFile = simpleTypeName + "-sealed-graph.svg"; int thumbnailHeight = 100; // also appears in the stylesheet String hoverImage = "" @@ -315,14 +315,14 @@ private static Optional packageName(TypeElement element) { case MEMBER -> packageName((TypeElement) element.getEnclosingElement()); }; } + } - private static String packagelessCanonicalName(TypeElement element) { - String result = element.getSimpleName().toString(); - while (element.getNestingKind() == NestingKind.MEMBER) { - element = (TypeElement) element.getEnclosingElement(); - result = element.getSimpleName().toString() + '.' + result; - } - return result; + private static String packagelessCanonicalName(TypeElement element) { + String result = element.getSimpleName().toString(); + while (element.getNestingKind() == NestingKind.MEMBER) { + element = (TypeElement) element.getEnclosingElement(); + result = element.getSimpleName().toString() + '.' + result; } + return result; } } diff --git a/src/java.base/share/classes/java/lang/doc-files/ValueBased.html b/src/java.base/share/classes/java/lang/doc-files/ValueBased.html index 86d9b359557..6a935afe04b 100644 --- a/src/java.base/share/classes/java/lang/doc-files/ValueBased.html +++ b/src/java.base/share/classes/java/lang/doc-files/ValueBased.html @@ -1,6 +1,6 @@