From: Justin Hunter Date: Sat, 22 Aug 2009 21:37:32 +0000 (-0700) Subject: add backcompat methods X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=6b4be44bd52c30e8dc44c0ab0c1684b67d43d169;p=dbsrgits%2FSQL-Translator-2.0-ish.git add backcompat methods --- diff --git a/lib/SQL/Translator/Object/Constraint.pm b/lib/SQL/Translator/Object/Constraint.pm index 759b97f..3f46a30 100644 --- a/lib/SQL/Translator/Object/Constraint.pm +++ b/lib/SQL/Translator/Object/Constraint.pm @@ -74,9 +74,11 @@ class SQL::Translator::Object::Constraint { around add_column(Column $column) { $self->$orig($column->name, $column) } - method get_fields { return $self->get_columns } - method fields { return $self->column_ids } - method field_names { return $self->column_ids } + method get_fields { $self->get_columns } + method fields { $self->column_ids } + method field_names { $self->column_ids } + + method reference_fields { $self->reference_columns } method match_type { } } diff --git a/lib/SQL/Translator/Object/Index.pm b/lib/SQL/Translator/Object/Index.pm index 4bfbd69..a8df3ea 100644 --- a/lib/SQL/Translator/Object/Index.pm +++ b/lib/SQL/Translator/Object/Index.pm @@ -52,6 +52,6 @@ class SQL::Translator::Object::Index { around add_column(Column $column) { $self->$orig($column->name, $column) } - method get_fields { return $self->get_columns } - method fields { return $self->column_ids } + method get_fields { $self->get_columns } + method fields { $self->column_ids } } diff --git a/lib/SQL/Translator/Object/Trigger.pm b/lib/SQL/Translator/Object/Trigger.pm index 8501d1e..f7041b5 100644 --- a/lib/SQL/Translator/Object/Trigger.pm +++ b/lib/SQL/Translator/Object/Trigger.pm @@ -50,6 +50,6 @@ class SQL::Translator::Object::Trigger { around add_column(Column $column) { $self->$orig($column->name, $column) } - method get_fields { return $self->get_columns } - method fields { return $self->column_ids } + method get_fields { $self->get_columns } + method fields { $self->column_ids } }