just a little more POD
[catagits/Reaction.git] / lib / Reaction / InterfaceModel / Action / DBIC / ResultSet / DeleteAll.pm
1 package Reaction::InterfaceModel::Action::DBIC::ResultSet::DeleteAll;
2
3 use Reaction::Types::DBIC 'ResultSet';
4 use Reaction::Class;
5 use Reaction::InterfaceModel::Action;
6
7 use namespace::clean -except => [ qw(meta) ];
8 extends 'Reaction::InterfaceModel::Action';
9
10
11
12 has '+target_model' => (isa => ResultSet);
13
14 sub can_apply { 1 }
15 sub do_apply {
16   my $self = shift;
17   return $self->target_model->delete_all;
18 };
19
20 __PACKAGE__->meta->make_immutable;
21
22
23 1;
24
25
26 =head1 NAME
27
28 Reaction::InterfaceModel::Action::DBIC::ResultSet::DeleteAll
29
30 =head1 DESCRIPTION
31
32 Deletes every item in the target_model ResultSet
33
34 =head2 target_model
35
36 =head2 error_for_attribute
37
38 =head2 sync_all
39
40 =head1 AUTHORS
41
42 See L<Reaction::Class> for authors.
43
44 =head1 LICENSE
45
46 See L<Reaction::Class> for the license.
47
48 =cut