OPENDJ-3034 we realized that there is some confusion regarding the use of the term "UNDEFINED" in relation to filter/index evaluation:
- filters: as per RFC 4511, UNDEFINED is one possible result of a filter's tri-state logic, the other results being TRUE and FALSE. Note that UNDEFINED usually yields an overall result of FALSE when matching entries
- indexes: undefined entry ID sets communicate that an index query should be treated as "unindexed". This may occur when an index query is invalid due to an invalid assertion, corrupt index, or when an index key hits all-ids. Note that an "undefined" set implies that all entries are candidates, which is somewhat the opposite to how "undefined" is used for filter evaluation.
Suggested fix: in EntryIDSet replace uses of "defined" and "undefined" with "indexed" and "unindexed" respectively.
In addition, Yannick Lecaillez suggests that we optimize EntryIDSet.DefinedImpl.add() because it systematically resizes arrays.