this.limit = limit;
}
public EObject select() {
int count = 0;
ESeq vals = ERT.NIL;
ISeq map_seq = this.ent;
while (seq_has_more(map_seq) && (limit < 0 || count < limit)) {
IMapEntry mape = (IMapEntry) map_seq.first();
map_seq = map_seq.next();
ETuple candidate = (ETuple) mape.getValue();
EObject res;
if ((res = matcher.match(candidate)) != null) {
count += 1;
vals = vals.cons(res);
}
}
if (ordered) vals = vals.reverse();
if (vals == ERT.NIL) {
return Native.am_$end_of_table;
} else if (!seq_has_more(map_seq)) {
return new ETuple2(vals, Native.am_$end_of_table);