top.hendrixshen.magiclib.dependency.api.annotation.Dependency Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of magiclib-1_14_4 Show documentation
Show all versions of magiclib-1_14_4 Show documentation
To beat magic with magic :(
package top.hendrixshen.magiclib.dependency.api.annotation;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
/**
*
* This annotation class represents a valid dependency check where you can
* quickly use a semantic versioning expression to check for the presence of
* a specified dependency.
*
*
*
* Incompatible type settings are also preset, and additionally we support
* custom predicates to help verify that the runtime environment is valid
* for the annotated class.
*
*/
@Retention(RetentionPolicy.RUNTIME)
public @interface Dependency {
/**
* Dependency mod.
*
* @return mod id.
*/
String value();
/**
* Semantic versioning expressions.
*
* @return versionPredicate.
*/
String versionPredicate() default "*";
/**
* Mark this dependency as optional
*
* @return True if this dependency is optional.
*/
boolean optional() default false;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy