Mercurial > pub > Impl
comparison Lib/IMPL/DOM/Schema/Node.pm @ 18:818c74b038ae
DOM Schema + tests
| author | Sergey |
|---|---|
| date | Thu, 10 Sep 2009 17:42:47 +0400 |
| parents | |
| children | 1ca530e5c9c5 |
comparison
equal
deleted
inserted
replaced
| 17:7f88e01b58f8 | 18:818c74b038ae |
|---|---|
| 1 package IMPL::DOM::Schema::Node; | |
| 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 _dom property type => prop_all | |
| 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->type($args{type}); | |
| 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 |
