1 package DBIx::Class::Cursor;
10 my ($it_class, $db_class, $sth, $args, $cols) = @_;
11 $sth->execute(@{$args || []}) unless $sth->{Active};
17 return bless ($new, $it_class);
22 my @row = $self->{sth}->fetchrow_array;
24 #unless (@row) { $self->{sth}->finish; return; }
25 return $self->{class}->_row_to_object($self->{cols}, \@row);
29 return scalar $_[0]->all; # So inefficient
36 while (my $obj = $self->next) {
44 $_[0]->{sth}->finish if $_[0]->{sth}->{Active};
45 $_[0]->{sth}->execute(@{$_[0]->{args} || []});
50 return $_[0]->reset->next;