Extract couple more stateless functions from DBIHacks (like 497d0451)
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Storage / DBI / SQLAnywhere / Cursor.pm
index 189562e..8fb08a9 100644 (file)
@@ -5,6 +5,9 @@ use warnings;
 use base 'DBIx::Class::Storage::DBI::Cursor';
 use mro 'c3';
 
+use DBIx::Class::ResultSource::FromSpec::Util 'fromspec_columns_info';
+use namespace::clean;
+
 =head1 NAME
 
 DBIx::Class::Storage::DBI::SQLAnywhere::Cursor - GUID Support for SQL Anywhere
@@ -61,7 +64,7 @@ sub next {
 
   $unpack_guids->(
     $self->args->[1],
-    $self->{_colinfos} ||= $self->storage->_resolve_column_info($self->args->[0]),
+    $self->{_colinfos} ||= fromspec_columns_info($self->args->[0]),
     \@row,
     $self->storage
   );
@@ -76,7 +79,7 @@ sub all {
 
   $unpack_guids->(
     $self->args->[1],
-    $self->{_colinfos} ||= $self->storage->_resolve_column_info($self->args->[0]),
+    $self->{_colinfos} ||= fromspec_columns_info($self->args->[0]),
     $_,
     $self->storage
   ) for @rows;
@@ -85,15 +88,19 @@ sub all {
   return @rows;
 }
 
-1;
-
-=head1 AUTHOR
+=head1 FURTHER QUESTIONS?
 
-See L<DBIx::Class/AUTHOR> and L<DBIx::Class/CONTRIBUTORS>.
+Check the list of L<additional DBIC resources|DBIx::Class/GETTING HELP/SUPPORT>.
 
-=head1 LICENSE
+=head1 COPYRIGHT AND LICENSE
 
-You may distribute this code under the same terms as Perl itself.
+This module is free software L<copyright|DBIx::Class/COPYRIGHT AND LICENSE>
+by the L<DBIx::Class (DBIC) authors|DBIx::Class/AUTHORS>. You can
+redistribute it and/or modify it under the same terms as the
+L<DBIx::Class library|DBIx::Class/COPYRIGHT AND LICENSE>.
 
 =cut
+
+1;
+
 # vim:sts=2 sw=2: