DB::Introspector::Util::RelInspect
use DB::Introspector::Util::RelInspect; my @paths = DB::Introspector::Util::RelInspect ->find_mapped_paths_between_tables( $parent_table, $child_table );
DB::Introspector::Util::RelInspect is a utility class that contains methods that deal with relationship traversal.
Params:
$table_1 - the first element of each path DB::Introspector::Base::Table
$table_2 - the last element of each path DB::Introspector::Base::Table
$option_stop_at_first_contact (1|0) - stop once the destination table ($table_2) has been encountered, rather than continuing to find paths from the destination back to the destination
Returns: (\@) of DB::Introspector::ForeignKeyPath instances. All paths between $parent_table and $child_table.
$parent_table - the first element of each path
$child_table - the last element of each path
Returns: (\@) of DB::Introspector::MappedPath instances. All paths between $parent_table and $child_table where $child_table depends on $parent_table, even indirectly.
DB::Introspector
Masahji C. Stewart
The DB::Introspector::Util::RelInspect module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install DB::Introspector, copy and paste the appropriate command in to your terminal.
cpanm
cpanm DB::Introspector
CPAN shell
perl -MCPAN -e shell install DB::Introspector
For more information on module installation, please visit the detailed CPAN module installation guide.