Annotation Type LTOMLengthOf
-
@Documented @Retention(RUNTIME) @Target({TYPE_USE,TYPE_PARAMETER}) @SubtypeOf(LTLengthOf.class) public @interface LTOMLengthOf
The annotated expression evaluates to an integer whose value is at least 2 less than the lengths of all the given sequences.For example, an expression with type
@LTLengthOf({"a", "b"})
is less than or equal to botha.length-2
andb.length-2
. Equivalently, it is less than botha.length-1
andb.length-1
. The sequencesa
andb
might have different lengths.In the annotation's name, "LTOM" stands for "less than one minus".
@LTOMLengthOf({"a"})
=@LTLengthOf(value={"a"}, offset=1)
, and
@LTOMLengthOf(value={"a"}, offset=x)
=@LTLengthOf(value={"a"}, offset=x+1)
for any x.- See the Checker Framework Manual:
- Index Checker
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.String[]
value
Sequences, each of whose lengths is at least 1 larger than the annotated expression's value.
-
-
-
Element Detail
-
value
@JavaExpression java.lang.String[] value
Sequences, each of whose lengths is at least 1 larger than the annotated expression's value.
-
-