Mercurial > pub > Impl
view Lib/IMPL/DOM/Transform.pm @ 381:ced5937ff21a
Custom getters/setters support method names in theirs definitions
Initial support for localizable labels in DOM schemas
author | cin |
---|---|
date | Wed, 22 Jan 2014 16:56:10 +0400 |
parents | d1676be8afcc |
children |
line wrap: on
line source
package IMPL::DOM::Transform; use strict; use warnings; use parent qw(IMPL::Transform); __PACKAGE__->PassThroughArgs; sub GetClassForObject { my ($this,$object) = @_; if (my $class = ref $object) { if (UNIVERSAL::isa($object,'IMPL::DOM::Node')) { return $object->nodeName; } else { return $class; } } else { return undef; } } 1; __END__ =pod =head1 DESCRIPTION Преобразование для DOM документа, использует имя узла для применения подходящего преобразования. =cut