Serializable, Comparable<Snippet.SubKind>, Constable
Snippetpublic static enum Snippet.SubKind extends Enum<Snippet.SubKind>
kind().Enum.EnumDesc<E extends Enum<E>>
| Enum Constant | Description |
|---|---|
ANNOTATION_TYPE_SUBKIND |
An annotation interface declaration. |
ASSIGNMENT_SUBKIND |
An assignment expression. |
CLASS_SUBKIND |
A class declaration. |
ENUM_SUBKIND |
An enum declaration. |
INTERFACE_SUBKIND |
An interface declaration. |
METHOD_SUBKIND |
A method. |
OTHER_EXPRESSION_SUBKIND |
An expression which has not been wrapped in a temporary variable (reserved). |
RECORD_SUBKIND |
A record declaration. |
SINGLE_STATIC_IMPORT_SUBKIND |
Single-Static-Import Declaration. |
SINGLE_TYPE_IMPORT_SUBKIND |
Single-Type-Import Declaration. |
STATEMENT_SUBKIND |
A statement. |
STATIC_IMPORT_ON_DEMAND_SUBKIND |
Static-Import-on-Demand Declaration. |
TEMP_VAR_EXPRESSION_SUBKIND |
An expression whose value has been stored in a temporary variable. |
TYPE_IMPORT_ON_DEMAND_SUBKIND |
Type-Import-on-Demand Declaration. |
UNKNOWN_SUBKIND |
An unknown snippet. |
VAR_DECLARATION_SUBKIND |
A variable declaration without initializer. |
VAR_DECLARATION_WITH_INITIALIZER_SUBKIND |
A variable declaration with an initializer expression. |
VAR_VALUE_SUBKIND |
A simple variable reference expression. |
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
hasValue() |
Indicates whether this SubKind is executable and is non-void. |
boolean |
isExecutable() |
Indicates whether this SubKind is executable. |
Snippet.Kind |
kind() |
The Snippet.Kind that corresponds to this SubKind. |
static Snippet.SubKind |
valueOf |
Returns the enum constant of this class with the specified name. |
static Snippet.SubKind[] |
values() |
Returns an array containing the constants of this enum class, in the order they are declared. |
public static final Snippet.SubKind SINGLE_TYPE_IMPORT_SUBKIND
public static final Snippet.SubKind TYPE_IMPORT_ON_DEMAND_SUBKIND
public static final Snippet.SubKind SINGLE_STATIC_IMPORT_SUBKIND
public static final Snippet.SubKind STATIC_IMPORT_ON_DEMAND_SUBKIND
public static final Snippet.SubKind CLASS_SUBKIND
SubKind of Snippet.Kind.TYPE_DECL.public static final Snippet.SubKind INTERFACE_SUBKIND
SubKind of Snippet.Kind.TYPE_DECL.public static final Snippet.SubKind ENUM_SUBKIND
SubKind of Snippet.Kind.TYPE_DECL.public static final Snippet.SubKind RECORD_SUBKIND
SubKind of Snippet.Kind.TYPE_DECL.public static final Snippet.SubKind ANNOTATION_TYPE_SUBKIND
SubKind of Snippet.Kind.TYPE_DECL.public static final Snippet.SubKind METHOD_SUBKIND
SubKind for Snippet.Kind.METHOD.public static final Snippet.SubKind VAR_DECLARATION_SUBKIND
SubKind of Snippet.Kind.VAR.public static final Snippet.SubKind VAR_DECLARATION_WITH_INITIALIZER_SUBKIND
SubKind of Snippet.Kind.VAR.public static final Snippet.SubKind TEMP_VAR_EXPRESSION_SUBKIND
SubKind of Snippet.Kind.VAR.public static final Snippet.SubKind VAR_VALUE_SUBKIND
SubKind of Snippet.Kind.EXPRESSION.public static final Snippet.SubKind ASSIGNMENT_SUBKIND
SubKind of Snippet.Kind.EXPRESSION.public static final Snippet.SubKind OTHER_EXPRESSION_SUBKIND
SubKind of Snippet.Kind.EXPRESSION.public static final Snippet.SubKind STATEMENT_SUBKIND
SubKind for Snippet.Kind.STATEMENT.public static final Snippet.SubKind UNKNOWN_SUBKIND
SubKind for Snippet.Kind.ERRONEOUS.public static Snippet.SubKind[] values()
public static Snippet.SubKind 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 isExecutable()
SubKind is executable.true if this SubKind can be executed; otherwise false
public boolean hasValue()
SubKind is executable and is non-void.true if this SubKind has a value; otherwise false
public Snippet.Kind kind()
Snippet.Kind that corresponds to this SubKind.Kind for this SubKind
© 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/jdk.jshell/jdk/jshell/Snippet.SubKind.html