Annotation Type EnvironmentInterface


@Retention(CLASS)
@Repeatable(EnvironmentInterfaces.class)
@Target(TYPE)
@Documented
public @interface EnvironmentInterface
Applied to declare that a class implements an interface only in the specified environment.

Use with caution, as Fabric-loader will remove the interface from implements declaration of the class in a mismatched environment!

Implemented methods are not removed. To remove implemented methods, use Environment.

See Also:
Environment
  • Required Element Summary

    Required Elements
    Modifier and Type Required Element Description
    Class<?> itf
    Returns the interface class.
    EnvType value
    Returns the environment type that the specific interface is only implemented in.
  • Element Details

    • value

      EnvType value
      Returns the environment type that the specific interface is only implemented in.
    • itf

      Class<?> itf
      Returns the interface class.