sub class_of{
my($class_or_instance) = @_;
return undef unless defined $class_or_instance;
- return $METAS{ blessed($class_or_instance) || $class_or_instance };
+ return $METAS{ ref($class_or_instance) || $class_or_instance };
}
# Means of accessing all the metaclasses that have
# add_attribute is an abstract method
-sub get_attribute_map { $_[0]->{attributes} }
+sub get_attribute_map {
+ Carp::cluck('get_attribute_map() has been deprecated');
+ return $_[0]->{attributes};
+}
+
sub has_attribute { exists $_[0]->{attributes}->{$_[1]} }
sub get_attribute { $_[0]->{attributes}->{$_[1]} }
sub get_attribute_list{ keys %{$_[0]->{attributes}} }