1 package SQL::Translator::Producer::Storable;
5 SQL::Translator::Producer::Storable - serializes the SQL::Translator::Schema
6 object via the Storable module
12 my $translator = SQL::Translator->new;
13 $translator->producer('Storable');
17 This module uses Storable to serialize a schema to a string so that it
18 can be saved to disk. Serializing a schema and then calling producers
19 on the stored can realize significant performance gains when parsing
25 use vars qw($DEBUG $VERSION @EXPORT_OK);
26 $DEBUG = 0 unless defined $DEBUG;
31 use base qw(Exporter);
33 @EXPORT_OK = qw(produce);
37 my $args = $t->producer_args;
38 my $schema = $t->schema;
39 my $serialized = Storable::nfreeze($schema);
46 # -------------------------------------------------------------------
52 Paul Harrington E<lt>harringp@deshaw.comE<gt>.
56 SQL::Translator, SQL::Translator::Schema, Storable.