comparison Lib/IMPL/DOM/Schema.pm @ 126:c8dfbbdd8005

Several bug fixes Forms support pre-alfa version
author wizard
date Fri, 11 Jun 2010 04:29:51 +0400
parents 196bf443b5e1
children 1e7f03414b65
comparison
equal deleted inserted replaced
125:a4b0a819bbda 126:c8dfbbdd8005
112 my ($this,$node) = @_; 112 my ($this,$node) = @_;
113 113
114 if ( my ($schemaNode) = $this->selectNodes(sub { $_->isa('IMPL::DOM::Schema::Node') and $_[0]->name eq $node->nodeName })) { 114 if ( my ($schemaNode) = $this->selectNodes(sub { $_->isa('IMPL::DOM::Schema::Node') and $_[0]->name eq $node->nodeName })) {
115 $schemaNode->Validate($node); 115 $schemaNode->Validate($node);
116 } else { 116 } else {
117 return new IMPL::DOM::Schema::ValidationError(Message=> "A specified document doesn't match the schema"); 117 return new IMPL::DOM::Schema::ValidationError(Node => $node, Message=> "A specified document (%Node.nodeName%) doesn't match the schema");
118 } 118 }
119 } 119 }
120 120
121 my $schema; 121 my $schema;
122 122