Skip to content

Commit

Permalink
typing annotation: Generics
Browse files Browse the repository at this point in the history
  • Loading branch information
ZZZank committed Jul 2, 2024
1 parent a858843 commit 284c456
Showing 1 changed file with 19 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package dev.latvian.mods.rhino.annotations.typing;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* Provide list of generic types when runtime erases them, usually for method params
*/
@Documented
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.TYPE, ElementType.METHOD, ElementType.FIELD, ElementType.RECORD_COMPONENT, ElementType.PARAMETER})
public @interface Generics {
Class<?>[] value();

Class<?> base() default Object.class;
}

0 comments on commit 284c456

Please sign in to comment.