APIdia Launch Partner
Top Description Methods
jdk.jfr

public @Interface Name

extends Annotation
Annotations
@Target:TYPE, FIELD, METHOD
@Retention:RUNTIME
@MetadataDefinition
Imports
java.lang.annotation.ElementType, .Retention, .RetentionPolicy, .Target

Annotation that sets the default name for an element.

For event classes, the name must be a legal class name as specified in the Java language, (for example, "com.example.Transaction". For event fields or event settings, the name must be a valid identifier (for example, "message"). See section 3.8 and 3.9 of the Java Language Specification for more information.

If the specified name is invalid, the annotation is ignored.

A stable and easy-to-use event name is of the form:

[org|com|net].[organization|product].EventName

Events without a @Name annotation get their name from the fully qualified class name, which works well for experimentation but should be avoided in production.

Since
9

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

the name
value
()

Returns the name.

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

valueback to summary
public String value()

Returns the name.

Returns:String

the name