All tests pass except for the transaction tests under MySQL. InnoDB sucks
[dbsrgits/DBM-Deep.git] / lib / DBM / Deep / Sector / DBI / Scalar.pm
CommitLineData
a4d36ff6 1package DBM::Deep::Sector::DBI::Scalar;
2
3use strict;
4use warnings FATAL => 'all';
5
6use base qw( DBM::Deep::Sector::DBI );
7
8sub table { 'datas' }
9
10sub _init {
11 my $self = shift;
12
cf4a1344 13 if ( $self->offset ) {
a4d36ff6 14 my ($rows) = $self->engine->storage->read_from(
15 datas => $self->offset,
1f1f7e24 16 qw( id data_type key value ),
a4d36ff6 17 );
18
1f1f7e24 19 $self->{$_} = $rows->[0]{$_} for qw( data_type key value );
a4d36ff6 20 }
21
22 return;
23}
24
25sub data {
26 my $self = shift;
27 $self->{value};
28}
29
a4d36ff6 301;
31__END__