line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package DBIx::Class::InflateColumn::DateTimeX::Immutable; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# ABSTRACT: Inflate/deflate DBIx::Class columns to DateTimeX::Immutable objects |
4
|
|
|
|
|
|
|
|
5
|
2
|
|
|
2
|
|
152893
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
67
|
|
6
|
2
|
|
|
2
|
|
8
|
use warnings; |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
47
|
|
7
|
2
|
|
|
2
|
|
8
|
use base qw/DBIx::Class::InflateColumn::DateTime/; |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
1009
|
|
8
|
2
|
|
|
2
|
|
65477
|
use DBIx::Class::Carp; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
8
|
|
9
|
2
|
|
|
2
|
|
503
|
use DateTimeX::Immutable; |
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
use Try::Tiny; |
11
|
|
|
|
|
|
|
use namespace::autoclean; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
our $VERSION = '0.32'; |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub _inflate_to_datetime { |
16
|
|
|
|
|
|
|
my $self = shift; |
17
|
|
|
|
|
|
|
my $rv = $self->next::method(@_); |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
## warn "\$rv isa " . ref $rv . "\n"; |
20
|
|
|
|
|
|
|
bless $rv, 'DateTimeX::Immutable'; |
21
|
|
|
|
|
|
|
return $rv; |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__END__ |