| Class-DBI documentation | Contained in the Class-DBI distribution. |
Class::DBI::Attribute - A value in a column.
my $column = Class::DBI::Attribute->new($column => $value);
This stores the row-value of a certain column in an object. You probably shouldn't be dealing with this directly, and its interface is liable to change without notice.
| Class-DBI documentation | Contained in the Class-DBI distribution. |
package Class::DBI::Attribute;
use strict; use base 'Class::Accessor::Fast'; __PACKAGE__->mk_accessors(qw/column current_value known/); use overload '""' => sub { shift->current_value }, fallback => 1; sub new { my ($class, $col, $val) = @_; $class->SUPER::new({ column => $col, current_value => $val, known => 1, }); } 1;