Persistence::ValueGenerator::SequenceGenerator - Unique value generator based on databse sequence
Persistence::ValueGenerator | +----Persistence::ValueGenerator::SequenceGenerator
use Persistence::ValueGenerator::SequenceGenerator; my $generator = Persistence::ValueGenerator::SequenceGenerator->new( entity_manager_name => $entity_manager_name, name => 'pk_generator', sequence_name => 'cust_seq', allocation_size => 1, ); $generator->nextval; or use Persistence::ValueGenerator::SequenceGenerator ':all'; my $generator = sequence_generator 'pk_generator' => ( entity_manager_name => $entity_manager_name, sequence_name => 'cust_seq', allocation_size => 1, )
Represents sequence generator that uses database sequcnce.
sequence_generator by ':all' tag.
Returns next value for the instance generator
Creates a new instance of Persistence::ValueGenerator::TableGenerator
Persistence::ValueGenerator
The Persistence::ValueGenerator::SequenceGenerator module is free software. You may distribute under the terms of either the GNU General Public License or the Artistic License, as specified in the Perl README file.
Adrian Witas, adrian@webapp.strefa.pl
To install Persistence::Entity, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Persistence::Entity
CPAN shell
perl -MCPAN -e shell install Persistence::Entity
For more information on module installation, please visit the detailed CPAN module installation guide.