comparison Lib/IMPL/DOM/Schema/Item.pm @ 7:94d47b388442

Улучшены тесты Исправлены ошибки Улучшена документация Работа над схемой DOM
author Sergey
date Mon, 24 Aug 2009 01:05:34 +0400
parents
children
comparison
equal deleted inserted replaced
6:e2cd73ccc5bd 7:94d47b388442
1 package IMPL::DOM::Schema::Item;
2 use strict;
3 use warnings;
4
5 use base qw(IMPL::DOM::Node);
6 use IMPL::Class::Property;
7 use IMPL::DOM::Property qw(_dom);
8 use IMPL::Class::Property::Direct;
9
10 BEGIN {
11 public _dom property minOccur => prop_all;
12 public _dom property maxOccur => prop_all;
13 public _direct property Schema => prop_get;
14 }
15
16 __PACKAGE__->PassThroughArgs;
17
18 sub CTOR {
19 my ($this,%args) = @_;
20
21 $this->minOccur($args{minOcuur});
22 $this->maxOccur($args{maxOccur});
23 $this->{$Schema} = $args{Schema} or die new IMPL::InvalidArgumentException("A schema should be specified");
24 }
25
26 1;
27
28 __END__
29 =pod
30
31 =head1 SYNOPSIS
32
33 package Restriction;
34 use base qw(IMPL::DOM::Schema::Item);
35
36 sub Validate {
37 my ($this,$node) = @_;
38 }
39
40 =head1 DESCRIPTION
41
42 .
43
44 =cut