org.checkerframework.common.value.qual.MinLenFieldInvariant Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of framework-all Show documentation
Show all versions of framework-all Show documentation
The Checker Framework enhances Java's type system to
make it more powerful and useful. This lets software developers
detect and prevent errors in their Java programs.
The Checker Framework includes compiler plug-ins ("checkers")
that find bugs or verify their absence. It also permits you to
write your own compiler plug-ins.
package org.checkerframework.common.value.qual;
import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
import java.lang.annotation.Target;
import org.checkerframework.framework.qual.FieldInvariant;
/**
* A specialization of {@link FieldInvariant} for specifying the minimum length of an array. A class
* can be annotated with both this annotation and a {@link FieldInvariant} annotation.
*
* @checker_framework.manual #field-invariants Field invariants
*/
@Inherited
@Target(ElementType.TYPE)
public @interface MinLenFieldInvariant {
/**
* Min length of the array. Must be greater than the min length of the array as declared in the
* superclass.
*/
int[] minLen();
/**
* The field that has an array length qualifier in the class on which the field invariant is
* written. The field must be final and declared in a superclass.
*/
String[] field();
}