-
-
17 May 2022 10:49:29 UTC
- Distribution: DBIx-Class
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Repository
- Issues (120)
- Testers (195 / 0 / 0)
- Kwalitee
Bus factor: 1- % Coverage
- License: perl_5
- Perl: v5.8.1
- Activity
24 month- Tools
- Download (858.78KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
and 210 contributors-
mst: Matt S Trout (project founder - original idea, architecture and implementation)
-
castaway: Jess Robinson (lions share of the reference documentation and manuals)
-
abraxxa: Alexander Hartmaier
-
acca: Alexander Kuznetsov
-
acme: Leon Brocard
-
aherzog: Adam Herzog
-
Alexander Keusch
-
alexrj: Alessandro Ranellucci
-
alnewkirk: Al Newkirk
-
Altreus: Alastair McGowan-Douglas
-
amiri: Amiri Barksdale
-
amoore: Andrew Moore
-
Andrew Mehta
-
andrewalker: Andre Walker
-
andyg: Andy Grundman
-
ank: Andres Kievsky
-
arc: Aaron Crane
-
arcanez: Justin Hunter
-
ash: Ash Berlin
-
bert: Norbert Csongrádi
-
bfwg: Colin Newell
-
blblack: Brandon L. Black
-
bluefeet: Aran Deltac
-
boghead: Bryan Beeley
-
bphillips: Brian Phillips
-
brd: Brad Davis
-
Brian Kirkbride
-
bricas: Brian Cassidy
-
brunov: Bruno Vecchi
-
caelum: Rafael Kitover
-
caldrin: Maik Hentsche
-
chorny: Alexandr Ciornii
-
cj: C.J. Adams-Collier
-
claco: Christopher H. Laco
-
clkao: CL Kao
- Ctrl-O http://ctrlo.com/
-
da5id: David Jack Olrik
-
dams: Damien Krotkine
-
dandv: Dan Dascalescu
-
dariusj: Darius Jokilehto
-
davewood: David Schmidt
-
daxim: Lars Dɪᴇᴄᴋᴏᴡ 迪拉斯
-
dduncan: Darren Duncan
-
debolaz: Anders Nor Berle
-
dew: Dan Thomas
-
dim0xff: Dmitry Latin
-
dkubb: Dan Kubb
-
dnm: Justin Wheeler
-
dpetrov: Dimitar Petrov
-
Dr^ZigMan: Robert Stone
-
dsteinbrunner: David Steinbrunner
-
duncan_dmg: Duncan Garland
-
dwc: Daniel Westermann-Clark
-
dyfrgi: Michael Leuchtenburg
-
edenc: Eden Cardim
- Eligo http://eligo.co.uk/
-
ether: Karen Etheridge
-
evdb: Edmund von der Burg
-
faxm0dem: Fabien Wernli
-
felliott: Fitz Elliott
-
fgabolde: Fabrice Gabolde
-
freetime: Bill Moseley
-
frew: Arthur Axel "fREW" Schmidt
-
gbjk: Gareth Kirwan
-
geotheve: Georgina Thevenet
-
Getty: Torsten Raudssus
-
goraxe: Gordon Irving
-
gphat: Cory G Watson
- Grant Street Group http://www.grantstreet.com/
-
gregoa: Gregor Herrmann
-
groditi: Guillermo Roditi
-
gshank: Gerda Shank
-
guacamole: Fred Steinberg
-
Haarg: Graham Knop
-
hobbs: Andrew Rodland
-
Ian Wells
-
idn: Ian Norton
-
ilmari: Dagfinn Ilmari Mannsåker
-
ingy: Ingy döt Net
-
initself: Mike Baas
-
ironcamel: Naveed Massjouni
-
jasonmay: Jason May
-
jawnsy: Jonathan Yu
-
jegade: Jens Gassmann
-
jeneric: Eric A. Miller
-
jesper: Jesper Krogh
-
Jesse Sheidlower
-
jgoulah: John Goulah
-
jguenther: Justin Guenther
-
jhannah: Jay Hannah
-
jmac: Jason McIntosh
-
jmmills: Jason M. Mills
-
jnapiorkowski: John Napiorkowski
-
Joe Carlson
-
jon: Jon Schutz
-
Jordan Metzmeier
-
jshirley: J. Shirley
- kaare: Kaare Rasmussen
-
kd: Kieren Diment
-
kentnl: Kent Fredric
-
kkane: Kevin L. Kane
-
konobi: Scott McWhirter
-
lejeunerenard: Sean Zellmer
-
leont: Leon Timmermans
-
littlesavage: Alexey Illarionov
-
lukes: Luke Saunders
-
marcus: Marcus Ramberg
-
mateu: Mateu X. Hunter
-
Matt LeBlanc
-
Matt Sickler
- mattlaw: Matt Lawrence
-
mattp: Matt Phillips
-
mdk: Mark Keating
-
melo: Pedro Melo
-
metaperl: Terrence Brannon
-
michaelr: Michael Reddick
-
milki: Jonathan Chu
-
minty: Murray Walker
-
mithaldu: Christian Walde
-
mjemmeson: Michael Jemmeson
- mna: Maya
-
mo: Moritz Onken
-
moltar: Roman Filippov
-
moritz: Moritz Lenz
-
mrf: Mike Francis
-
mstratman: Mark A. Stratman
-
ned: Neil de Carteret
-
nigel: Nigel Metheringham
-
ningu: David Kamholz
-
Nniuq: Ron "Quinn" Straight"
-
norbi: Norbert Buchmuller
-
nothingmuch: Yuval Kogman
-
nuba: Nuba Princigalli
-
Numa: Dan Sully
-
oalders: Olaf Alders
-
Olly Betts
-
osfameron: Hakim Cassimally
-
ovid: Curtis "Ovid" Poe
-
oyse: Øystein Torget
-
paulm: Paul Makepeace
-
penguin: K J Cheetham
-
perigrin: Chris Prather
-
Peter Siklósi
-
Peter Valdemar Mørch
-
peter: Peter Collingbourne
-
phaylon: Robert Sedlacek
-
plu: Johannes Plunien
-
pmooney: Paul Mooney
-
Possum: Daniel LeWarne
-
pplu: Jose Luis Martinez
-
quicksilver: Jules Bean
-
racke: Stefan Hornburg
-
rafl: Florian Ragwitz
-
rainboxx: Matthias Dietrich
-
rbo: Robert Bohne
-
rbuels: Robert Buels
-
rdj: Ryan D Johnson
-
Relequestual: Ben Hutton
-
renormalist: Steffen Schwigon
-
rjbs: Ricardo Signes
-
Robert Krimen
-
Robert Olson
-
robkinyon: Rob Kinyon
-
Roman Ardern-Corris
-
ruoso: Daniel Ruoso
-
Sadrak: Felix Antonius Wilhelm Ostmann
- sc_: Just Another Perl Hacker
-
schwern: Michael G Schwern
-
Scott R. Godin
-
scotty: Scotty Allen
-
semifor: Marc Mims
-
Simon Elliott
-
SineSwiper: Brendan Byrd
-
skaufman: Samuel Kaufman
-
solomon: Jared Johnson
-
spb: Stephen Bennett
-
Squeeks
-
srezic: Slaven Rezic
-
sszabo: Stephan Szabo
-
Stephen Peters
-
stonecolddevin: Devin Austin
-
talexb: Alex Beamish
-
tamias: Ronald J Kimball
-
TBSliver: Tom Bloor
-
teejay: Aaron Trevena
-
theorbtwo: James Mastros
-
Thomas Kratz
-
timbunce: Tim Bunce
-
tinita: Tina Mueller
- Todd Lipcon
-
Tom Hukins
-
tommy: Tommy Butler
-
tonvoon: Ton Voon
-
triode: Pete Gamache
-
typester: Daisuke Murase
-
uree: Oriol Soriano
-
uwe: Uwe Voelker
-
vanstyn: Henry Van Styn
-
victori: Victor Igumnov
-
wdh: Will Hawes
-
wesm: Wes Malone
-
willert: Sebastian Willert
-
wintermute: Toby Corkindale
-
wreis: Wallace Reis
-
x86-64
-
xenoterracide: Caleb Cushing
-
xmikew: Mike Wisener
-
yrlnry: Mark Jason Dominus
-
zamolxes: Bogdan Lucaciu
-
Zefram: Andrew Main
- Dependencies
- Class::Accessor::Grouped
- Class::C3::Componentised
- Class::Inspector
- Config::Any
- Context::Preserve
- DBI
- Data::Dumper::Concise
- Devel::GlobalDestruction
- Hash::Merge
- MRO::Compat
- Module::Find
- Moo
- Path::Class
- SQL::Abstract::Classic
- Scope::Guard
- Sub::Name
- Text::Balanced
- Try::Tiny
- namespace::clean
- Reverse dependencies
- CPAN Testers List
- Dependency graph
- NAME
- SYNOPSIS
- DESCRIPTION
- SETUP METHODS
- METHODS
- connect
- resultset
- sources
- source
- class
- txn_do
- txn_scope_guard
- txn_begin
- txn_commit
- txn_rollback
- storage
- populate
- connection
- compose_namespace
- svp_begin
- svp_release
- svp_rollback
- clone
- throw_exception
- deploy
- deployment_statements
- create_ddl_dir
- ddl_filename
- thaw
- freeze
- dclone
- schema_version
- register_class
- register_source
- unregister_source
- register_extra_source
- compose_connection (DEPRECATED)
- FURTHER QUESTIONS?
- COPYRIGHT AND LICENSE
NAME
DBIx::Class::Schema - composable schemas
SYNOPSIS
package Library::Schema; use base qw/DBIx::Class::Schema/; # load all Result classes in Library/Schema/Result/ __PACKAGE__->load_namespaces(); package Library::Schema::Result::CD; use base qw/DBIx::Class::Core/; __PACKAGE__->load_components(qw/InflateColumn::DateTime/); # for example __PACKAGE__->table('cd'); # Elsewhere in your code: my $schema1 = Library::Schema->connect( $dsn, $user, $password, { AutoCommit => 1 }, ); my $schema2 = Library::Schema->connect($coderef_returning_dbh); # fetch objects using Library::Schema::Result::DVD my $resultset = $schema1->resultset('DVD')->search( ... ); my @dvd_objects = $schema2->resultset('DVD')->search( ... );
DESCRIPTION
Creates database classes based on a schema. This is the recommended way to use DBIx::Class and allows you to use more than one concurrent connection with your classes.
NB: If you're used to Class::DBI it's worth reading the "SYNOPSIS" carefully, as DBIx::Class does things a little differently. Note in particular which module inherits off which.
SETUP METHODS
load_namespaces
package MyApp::Schema; __PACKAGE__->load_namespaces(); __PACKAGE__->load_namespaces( result_namespace => 'Res', resultset_namespace => 'RSet', default_resultset_class => '+MyApp::Othernamespace::RSet', );
With no arguments, this method uses Module::Find to load all of the Result and ResultSet classes under the namespace of the schema from which it is called. For example,
My::Schema
will by default find and load Result classes namedMy::Schema::Result::*
and ResultSet classes namedMy::Schema::ResultSet::*
.ResultSet classes are associated with Result class of the same name. For example,
My::Schema::Result::CD
will get the ResultSet classMy::Schema::ResultSet::CD
if it is present.Both Result and ResultSet namespaces are configurable via the
result_namespace
andresultset_namespace
options.Another option,
default_resultset_class
specifies a custom default ResultSet class for Result classes with no corresponding ResultSet.All of the namespace and classname options are by default relative to the schema classname. To specify a fully-qualified name, prefix it with a literal
+
. For example,+Other::NameSpace::Result
.Warnings
You will be warned if ResultSet classes are discovered for which there are no matching Result classes like this:
load_namespaces found ResultSet class $classname with no corresponding Result class
If a ResultSource instance is found to already have a ResultSet class set using resultset_class to some other class, you will be warned like this:
We found ResultSet class '$rs_class' for '$result_class', but it seems that you had already set '$result_class' to use '$rs_set' instead
Examples
# load My::Schema::Result::CD, My::Schema::Result::Artist, # My::Schema::ResultSet::CD, etc... My::Schema->load_namespaces; # Override everything to use ugly names. # In this example, if there is a My::Schema::Res::Foo, but no matching # My::Schema::RSets::Foo, then Foo will have its # resultset_class set to My::Schema::RSetBase My::Schema->load_namespaces( result_namespace => 'Res', resultset_namespace => 'RSets', default_resultset_class => 'RSetBase', ); # Put things in other namespaces My::Schema->load_namespaces( result_namespace => '+Some::Place::Results', resultset_namespace => '+Another::Place::RSets', );
To search multiple namespaces for either Result or ResultSet classes, use an arrayref of namespaces for that option. In the case that the same result (or resultset) class exists in multiple namespaces, later entries in the list of namespaces will override earlier ones.
My::Schema->load_namespaces( # My::Schema::Results_C::Foo takes precedence over My::Schema::Results_B::Foo : result_namespace => [ 'Results_A', 'Results_B', 'Results_C' ], resultset_namespace => [ '+Some::Place::RSets', 'RSets' ], );
load_classes
"load_classes" is an alternative method to "load_namespaces", both of which serve similar purposes, each with different advantages and disadvantages. In the general case you should use "load_namespaces", unless you need to be able to specify that only specific classes are loaded at runtime.
With no arguments, this method uses Module::Find to find all classes under the schema's namespace. Otherwise, this method loads the classes you specify (using use), and registers them (using "register_class").
It is possible to comment out classes with a leading
#
, but note that perl will think it's a mistake (trying to use a comment in a qw list), so you'll need to addno warnings 'qw';
before your load_classes call.If any classes found do not appear to be Result class files, you will get the following warning:
Failed to load $comp_class. Can't find source_name method. Is $comp_class really a full DBIC result class? Fix it, move it elsewhere, or make your load_classes call more specific.
Example:
My::Schema->load_classes(); # loads My::Schema::CD, My::Schema::Artist, # etc. (anything under the My::Schema namespace) # loads My::Schema::CD, My::Schema::Artist, Other::Namespace::Producer but # not Other::Namespace::LinerNotes nor My::Schema::Track My::Schema->load_classes(qw/ CD Artist #Track /, { Other::Namespace => [qw/ Producer #LinerNotes /], });
storage_type
- Arguments: $storage_type|{$storage_type, \%args}
- Return Value: $storage_type|{$storage_type, \%args}
- Default value: DBIx::Class::Storage::DBI
Set the storage class that will be instantiated when "connect" is called. If the classname starts with
::
, the prefixDBIx::Class::Storage
is assumed by "connect".You want to use this to set subclasses of DBIx::Class::Storage::DBI in cases where the appropriate subclass is not autodetected.
If your storage type requires instantiation arguments, those are defined as a second argument in the form of a hashref and the entire value needs to be wrapped into an arrayref or a hashref. We support both types of refs here in order to play nice with your Config::[class] or your choice. See DBIx::Class::Storage::DBI::Replicated for an example of this.
exception_action
When "throw_exception" is invoked and "exception_action" is set to a code reference, this reference will be called instead of "throw" in DBIx::Class::Exception, with the exception message passed as the only argument.
Your custom throw code must rethrow the exception, as "throw_exception" is an integral part of DBIC's internal execution control flow.
Example:
package My::Schema; use base qw/DBIx::Class::Schema/; use My::ExceptionClass; __PACKAGE__->exception_action(sub { My::ExceptionClass->throw(@_) }); __PACKAGE__->load_classes; # or: my $schema_obj = My::Schema->connect( .... ); $schema_obj->exception_action(sub { My::ExceptionClass->throw(@_) });
stacktrace
Whether "throw_exception" should include stack trace information. Defaults to false normally, but defaults to true if
$ENV{DBIC_TRACE}
is true.sqlt_deploy_hook
An optional sub which you can declare in your own Schema class that will get passed the SQL::Translator::Schema object when you deploy the schema via "create_ddl_dir" or "deploy".
For an example of what you can do with this, see "Adding Indexes And Functions To Your SQL" in DBIx::Class::Manual::Cookbook.
Note that sqlt_deploy_hook is called by "deployment_statements", which in turn is called before "deploy". Therefore the hook can be used only to manipulate the SQL::Translator::Schema object before it is turned into SQL fed to the database. If you want to execute post-deploy statements which can not be generated by SQL::Translator, the currently suggested method is to overload "deploy" and use dbh_do.
METHODS
connect
Creates and returns a new Schema object. The connection info set on it is used to create a new instance of the storage backend and set it on the Schema object.
See "connect_info" in DBIx::Class::Storage::DBI for DBI-specific syntax on the
@connectinfo
argument, or DBIx::Class::Storage in general.Note that
connect_info
expects an arrayref of arguments, butconnect
does not.connect
wraps its arguments in an arrayref before passing them toconnect_info
.Overloading
connect
is a convenience method. It is equivalent to calling $schema->clone->connection(@connectinfo). To write your own overloaded version, overload "connection" instead.resultset
- Arguments: $source_name
- Return Value: $resultset
my $rs = $schema->resultset('DVD');
Returns the DBIx::Class::ResultSet object for the registered source name.
sources
- Return Value: @source_names
my @source_names = $schema->sources;
Lists names of all the sources registered on this Schema object.
source
- Arguments: $source_name
- Return Value: $result_source
my $source = $schema->source('Book');
Returns the DBIx::Class::ResultSource object for the registered source name.
class
- Arguments: $source_name
- Return Value: $classname
my $class = $schema->class('CD');
Retrieves the Result class name for the given source name.
txn_do
Executes
$coderef
with (optional) arguments@coderef_args
atomically, returning its result (if any). Equivalent to calling $schema->storage->txn_do. See "txn_do" in DBIx::Class::Storage for more information.This interface is preferred over using the individual methods "txn_begin", "txn_commit", and "txn_rollback" below.
WARNING: If you are connected with
AutoCommit => 0
the transaction is considered nested, and you will still need to call "txn_commit" to write your changes when appropriate. You will also want to connect withauto_savepoint => 1
to get partial rollback to work, if the storage driver for your database supports it.Connecting with
AutoCommit => 1
is recommended.txn_scope_guard
Runs
txn_scope_guard
on the schema's storage. See "txn_scope_guard" in DBIx::Class::Storage.txn_begin
Begins a transaction (does nothing if AutoCommit is off). Equivalent to calling $schema->storage->txn_begin. See "txn_begin" in DBIx::Class::Storage for more information.
txn_commit
Commits the current transaction. Equivalent to calling $schema->storage->txn_commit. See "txn_commit" in DBIx::Class::Storage for more information.
txn_rollback
Rolls back the current transaction. Equivalent to calling $schema->storage->txn_rollback. See "txn_rollback" in DBIx::Class::Storage for more information.
storage
my $storage = $schema->storage;
Returns the DBIx::Class::Storage object for this Schema. Grab this if you want to turn on SQL statement debugging at runtime, or set the quote character. For the default storage, the documentation can be found in DBIx::Class::Storage::DBI.
populate
- Arguments: $source_name, [ \@column_list, \@row_values+ ] | [ \%col_data+ ]
- Return Value: \@result_objects (scalar context) | @result_objects (list context)
A convenience shortcut to "populate" in DBIx::Class::ResultSet. Equivalent to:
$schema->resultset($source_name)->populate([...]);
- NOTE
-
The context of this method call has an important effect on what is submitted to storage. In void context data is fed directly to fastpath insertion routines provided by the underlying storage (most often "execute_for_fetch" in DBI), bypassing the new and insert calls on the Result class, including any augmentation of these methods provided by components. For example if you are using something like DBIx::Class::UUIDColumns to create primary keys for you, you will find that your PKs are empty. In this case you will have to explicitly force scalar or list context in order to create those values.
connection
Similar to "connect" except sets the storage object and connection data in-place on the Schema class. You should probably be calling "connect" to get a proper Schema object instead.
Overloading
Overload
connection
to change the behaviour ofconnect
.compose_namespace
For each DBIx::Class::ResultSource in the schema, this method creates a class in the target namespace (e.g. $target_namespace::CD, $target_namespace::Artist) that inherits from the corresponding classes attached to the current schema.
It also attaches a corresponding DBIx::Class::ResultSource object to the new $schema object. If
$additional_base_class
is given, the new composed classes will inherit from first the corresponding class from the current schema then the base class.For example, for a schema with My::Schema::CD and My::Schema::Artist classes,
$schema->compose_namespace('My::DB', 'Base::Class'); print join (', ', @My::DB::CD::ISA) . "\n"; print join (', ', @My::DB::Artist::ISA) ."\n";
will produce the output
My::Schema::CD, Base::Class My::Schema::Artist, Base::Class
svp_begin
Creates a new savepoint (does nothing outside a transaction). Equivalent to calling $schema->storage->svp_begin. See "svp_begin" in DBIx::Class::Storage for more information.
svp_release
Releases a savepoint (does nothing outside a transaction). Equivalent to calling $schema->storage->svp_release. See "svp_release" in DBIx::Class::Storage for more information.
svp_rollback
Rollback to a savepoint (does nothing outside a transaction). Equivalent to calling $schema->storage->svp_rollback. See "svp_rollback" in DBIx::Class::Storage for more information.
clone
Clones the schema and its associated result_source objects and returns the copy. The resulting copy will have the same attributes as the source schema, except for those attributes explicitly overridden by the provided
%attrs
.throw_exception
Throws an exception. Obeys the exemption rules of DBIx::Class::Carp to report errors from outer-user's perspective. See "exception_action" for details on overriding this method's behavior. If "stacktrace" is turned on,
throw_exception
's default behavior will provide a detailed stack trace.deploy
Attempts to deploy the schema to the current storage using SQL::Translator.
See "METHODS" in SQL::Translator for a list of values for
\%sqlt_args
. The most common value for this would be{ add_drop_table => 1 }
to have the SQL produced include aDROP TABLE
statement for each table created. For quoting purposes supplyquote_identifiers
.Additionally, the DBIx::Class parser accepts a
sources
parameter as a hash ref or an array ref, containing a list of source to deploy. If present, then only the sources listed will get deployed. Furthermore, you can use theadd_fk_index
parser parameter to prevent the parser from creating an index for each FK.deployment_statements
- Arguments: See "deployment_statements" in DBIx::Class::Storage::DBI
- Return Value: $listofstatements
A convenient shortcut to
$self->storage->deployment_statements($self, @args)
. Returns the statements used by "deploy" and "deploy" in DBIx::Class::Storage.create_ddl_dir
- Arguments: See "create_ddl_dir" in DBIx::Class::Storage::DBI
A convenient shortcut to
$self->storage->create_ddl_dir($self, @args)
.Creates an SQL file based on the Schema, for each of the specified database types, in the given directory.
ddl_filename
my $filename = $table->ddl_filename($type, $version, $dir, $preversion)
This method is called by
create_ddl_dir
to compose a file name out of the supplied directory, database type and version number. The default file name format is:$dir$schema-$version-$type.sql
.You may override this method in your schema if you wish to use a different format.
WARNING Prior to DBIx::Class version 0.08100 this method had a different signature: my $filename = $table->ddl_filename($type, $dir, $version, $preversion) In recent versions variables $dir and $version were reversed in order to bring the signature in line with other Schema/Storage methods. If you really need to maintain backward compatibility, you can do the following in any overriding methods: ($dir, $version) = ($version, $dir) if ($DBIx::Class::VERSION < 0.08100);
thaw
Provided as the recommended way of thawing schema objects. You can call
Storable::thaw
directly if you wish, but the thawed objects will not have a reference to any schema, so are rather useless.freeze
This doesn't actually do anything beyond calling nfreeze, it is just provided here for symmetry.
dclone
Recommended way of dcloning DBIx::Class::Row and DBIx::Class::ResultSet objects so their references to the schema object (which itself is not cloned) are properly maintained.
schema_version
Returns the current schema class' $VERSION in a normalised way.
register_class
This method is called by "load_namespaces" and "load_classes" to install the found classes into your Schema. You should be using those instead of this one.
You will only need this method if you have your Result classes in files which are not named after the packages (or all in the same file). You may also need it to register classes at runtime.
Registers a class which isa DBIx::Class::ResultSourceProxy. Equivalent to calling:
$schema->register_source($source_name, $component_class->result_source_instance);
register_source
- Arguments: $source_name, $result_source
This method is called by "register_class".
Registers the DBIx::Class::ResultSource in the schema with the given source name.
unregister_source
Removes the DBIx::Class::ResultSource from the schema for the given source name.
register_extra_source
- Arguments: $source_name, $result_source
As "register_source" but should be used if the result class already has a source and you want to register an extra one.
compose_connection (DEPRECATED)
DEPRECATED. You probably wanted compose_namespace.
Actually, you probably just wanted to call connect.
FURTHER QUESTIONS?
Check the list of additional DBIC resources.
COPYRIGHT AND LICENSE
This module is free software copyright by the DBIx::Class (DBIC) authors. You can redistribute it and/or modify it under the same terms as the DBIx::Class library.
Module Install Instructions
To install DBIx::Class, copy and paste the appropriate command in to your terminal.
cpanm DBIx::Class
perl -MCPAN -e shell install DBIx::Class
For more information on module installation, please visit the detailed CPAN module installation guide.