Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export function get,
IteratorT extends std.base.Iterator,
ReverseT extends std.base.ReverseIterator>
(entityGroup: IEntityGroup, key: any): T
{
for (let it = entityGroup.begin(); !it.equals(entityGroup.end()); it = it.next())
if (std.equal_to(it.value.key(), key) == true)
return it.value;
throw new std.OutOfRange("out of range");
}
}