++ed by:

2 non-PAUSE users.

Al Newkirk

NAME

Doodle::Table

ABSTRACT

Doodle Table Class

SYNOPSIS

  use Doodle::Table;

  my $self = Doodle::Table->new(
    name => 'users'
  );

DESCRIPTION

Database table representation. This class consumes the Doodle::Table::Helpers role.

METHODS

This package implements the following methods.

column

  column(Str $name, Any @args) : Column

Returns a new Column object.

column example
  my $column = $self->column;

create

  create(Any %args) : Command

Registers a table create and returns the Command object.

create example
  my $create = $self->create;

delete

  delete(Any %args) : Command

Registers a table delete and returns the Command object.

delete example
  my $delete = $self->delete;

index

  index(ArrayRef :$columns, Any %args) : Index

Returns a new Index object.

index example
  my $index = $self->index(columns => ['email', 'password']);

relation

  relation(Str $column, Str $ftable, Str $fcolumn, Any %args) : Relation

Returns a new Relation object.

relation example
  my $relation = $self->relation('profile_id', 'profiles', 'id');

rename

  rename(Any %args) : Command

Registers a table rename and returns the Command object.

rename example
  my $rename = $self->rename;