From: Dagfinn Ilmari Mannsåker Date: Wed, 4 Sep 2013 11:02:59 +0000 (+0100) Subject: Document fully-qualified constraint/exclude X-Git-Tag: 0.07036_02~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=90f93317d7f353a9ccc1b3dd5199b8fa9793cb80;p=dbsrgits%2FDBIx-Class-Schema-Loader.git Document fully-qualified constraint/exclude --- diff --git a/lib/DBIx/Class/Schema/Loader/Base.pm b/lib/DBIx/Class/Schema/Loader/Base.pm index 3df396d..06a451c 100644 --- a/lib/DBIx/Class/Schema/Loader/Base.pm +++ b/lib/DBIx/Class/Schema/Loader/Base.pm @@ -547,11 +547,28 @@ database and/or schema. =head2 constraint -Only load tables matching regex. Best specified as a qr// regex. +Only load matching tables. =head2 exclude -Exclude tables matching regex. Best specified as a qr// regex. +Exclude matching tables. + +These can be specified either as a regex (preferrably on the C +form), or as an arrayref of arrayrefs. Regexes are matched against +the (unqualified) table name, while arrayrefs are matched according to +L. + +For example: + + db_schema => [qw(some_schema other_schema)], + moniker_parts => [qw(schema name)], + constraint => [ + [ qr/\Asome_schema\z/ => qr/\A(?:foo|bar)\z/ ], + [ qr/\Aother_schema\z/ => qr/\Abaz\z/ ], + ], + +In this case only the tables C and C in C and +C in C will be dumped. =head2 moniker_map