includes

includes(value: MemberType): Boolean;

The includes method of the MemberKeyDictionary class searches the dictionary using the member keys of the object and returns true if the object is located with its current member key values.

This method will not find an object if its key has changed since it was added to a manually maintained dictionary. (A manually maintained dictionary can contain an object with a key that differs from the value that is currently in the attribute on which the dictionary is keyed.)

This method returns true only if the object is in the dictionary with its current key values; for example:

if self.myEmployees.includes(emp) then
    return true;
else
    foreach child in self.myEmployees do
        if child.isEmployee(emp) = true then
            return true;
            break;
        endif;
    endforeach;
endif;