8246098: API for Class::permittedSubclasses should clarify if returned elements are ordered or not

Reviewed-by: chegar
This commit is contained in:
Vicente Romero 2020-06-16 17:25:02 -04:00
parent e7f8e1fdb5
commit dee90e4736

View file

@ -4393,9 +4393,11 @@ public final class Class<T> implements java.io.Serializable,
* features of the Java language.}
*
* Returns an array containing {@code ClassDesc} objects representing all the
* direct subclasses or direct implementation classes permitted to extend or implement this class or interface
* if it is sealed. If this {@code Class} object represents a primitive type, {@code void}, an array type,
* or a class or interface that is not sealed, an empty array is returned.
* direct subclasses or direct implementation classes permitted to extend or
* implement this class or interface if it is sealed. The order of such elements
* is unspecified. If this {@code Class} object represents a primitive type,
* {@code void}, an array type, or a class or interface that is not sealed,
* an empty array is returned.
*
* @return an array of class descriptors of all the permitted subclasses of this class or interface
*