2 package MooseX::Storage::Engine::IO::AtomicFile;
16 # AtomicFile gives us no real
17 # benefit when reading, so why
20 my $fh = IO::File->new($self->file, 'r');
21 return do { local $/; <$fh>; };
25 my ($self, $data) = @_;
26 my $fh = IO::AtomicFile->new($self->file, 'w');
29 || confess "Could not write atomic file (" . $self->file . ") because: $!";
40 MooseX::Storage::Engine::IO::File
54 =item B<store ($data)>
68 All complex software has bugs lurking in it, and this module is no
69 exception. If you find a bug please either email me, or add the bug
74 Chris Prather E<lt>chris.prather@iinteractive.comE<gt>
76 Stevan Little E<lt>stevan.little@iinteractive.comE<gt>
78 =head1 COPYRIGHT AND LICENSE
80 Copyright 2007 by Infinity Interactive, Inc.
82 L<http://www.iinteractive.com>
84 This library is free software; you can redistribute it and/or modify
85 it under the same terms as Perl itself.