Serializable
, Comparable<Elements.Origin>
, Constable
Elements
public static enum Elements.Origin extends Enum<Elements.Origin>
Note that it is possible additional kinds of origin values will be added in future versions of the platform.
Enum.EnumDesc<E extends Enum<E>>
Enum Constant | Description |
---|---|
EXPLICIT |
Describes a construct explicitly declared in source code. |
MANDATED |
A mandated construct is one that is not explicitly declared in the source code, but whose presence is mandated by the specification. |
SYNTHETIC |
A synthetic construct is one that is neither implicitly nor explicitly declared in the source code. |
Modifier and Type | Method | Description |
---|---|---|
boolean |
isDeclared() |
Returns true for values corresponding to constructs that are implicitly or explicitly declared, false otherwise. |
static Elements.Origin |
valueOf |
Returns the enum constant of this class with the specified name. |
static Elements.Origin[] |
values() |
Returns an array containing the constants of this enum class, in the order they are declared. |
public static final Elements.Origin EXPLICIT
public static final Elements.Origin MANDATED
public static final Elements.Origin SYNTHETIC
public static Elements.Origin[] values()
public static Elements.Origin valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is nullpublic boolean isDeclared()
true
for values corresponding to constructs that are implicitly or explicitly declared, false
otherwise.
© 1993, 2023, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
https://docs.oracle.com/en/java/javase/21/docs/api/java.compiler/javax/lang/model/util/Elements.Origin.html