NAME
DBIx::NinjaORM::Schema::Table - Store information about a table used by DBIx::NinjaORM.
VERSION
Version 3.1.0
DESCRIPTION
DBIx::NinjaORM::Schema::Table currently uses DBIx::Inspector to retrieve various information about the tables used. This may however change in the future, so this package encapsulates various functions to make it easier to replace the dependencies and internals later if needed.
SYNOPSIS
use DBIx::NinjaORM::Schema::Table;
my $table_schema = DBIx::NinjaORM::Schema::Table->new(
dbh => $dbh,
name => $name,
);
my $column_names = $table_schema->get_column_names();
METHODS
new()
Create a new DBIx::NinjaORM::Schema::Table object.
my $table_schema = DBIx::NinjaORM::Schema::Table->new(
dbh => $dbh,
name => $name,
);
Arguments:
dbh (mandatory)
The database handle to use to access the table.
name (mandatory)
The name of the table.
get_name()
Return the table name.
my $table_name = $table_schema->get_name();
get_dbh()
Return the database handle associated with the table.
my $dbh = $table_schema->get_dbh();
get_column_names()
Return the name of the columns that exist in the underlying table.
my $column_names = $table_schema->get_column_names();
INTERNAL METHODS
Warning: the API for the internal methods may change in the future. Use or subclass with caution.
get_inspector()
Return a cached "DBIx::Inspector object".
my $inspector = $table_schema->get_inspector();
get_table()
Return the cached DBIx::Inspector::Table object associated with the underlying table.
my $table = $table_schema->get_table();
get_columns()
Return the cached arrayref of DBIx::Inspector::Column objects corresponding to the columns of the underlying table.
my $columns = $table_schema->get_columns();
BUGS
Please report any bugs or feature requests through the web interface at https://github.com/guillaumeaubert/DBIx-NinjaORM/issues/new. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc DBIx::NinjaORM::Schema::Table
You can also look for information at:
GitHub's request tracker
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
MetaCPAN
AUTHOR
Guillaume Aubert, <aubertg at cpan.org>
.
COPYRIGHT & LICENSE
Copyright 2009-2017 Guillaume Aubert.
This code is free software; you can redistribute it and/or modify it under the same terms as Perl 5 itself.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the LICENSE file for more details.