annotate Lib/IMPL/DOM/Document.pm @ 36:1828103371d0

DOM in works
author Sergey
date Fri, 20 Nov 2009 16:48:08 +0300
parents 7f00786f8210
children c2e7f7c96bcd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
1 package IMPL::DOM::Document;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
2 use strict;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
3 use warnings;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
4
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
5 use base qw(IMPL::DOM::Node);
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
6
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
7 __PACKAGE__->PassThroughArgs;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
8
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
9 sub Create {
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
10 my ($this,$nodeName,$class,$refProps) = @_;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
11
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
12 $refProps ||= {};
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
13
24
7f00786f8210 Первая рабочая реазизация схемы и навигаторов
Sergey
parents: 18
diff changeset
14 delete $refProps->{nodeName};
7f00786f8210 Первая рабочая реазизация схемы и навигаторов
Sergey
parents: 18
diff changeset
15
15
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
16 return $class->new(
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
17 nodeName => $nodeName,
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
18 %$refProps
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
19 );
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
20 }
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
21
36
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
22 {
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
23 my $empty;
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
24 sub Empty() {
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
25 return $empty ? $empty : $empty = __PACKAGE__->new(nodeName => 'Empty');
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
26 }
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
27 }
1828103371d0 DOM in works
Sergey
parents: 24
diff changeset
28
15
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
29 1;
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
30 __END__
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
31
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
32 =pod
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
33
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
34 =head1 DESCRIPTION
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
35
18
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
36 =head1 METHODS
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
37
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
38 =over
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
39
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
40 =item C<<$doc->Create>>
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
41
15
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
42 .
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
43
18
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
44 =back
818c74b038ae DOM Schema + tests
Sergey
parents: 15
diff changeset
45
15
16795016e70b Dom schema in progress
Sergey
parents:
diff changeset
46 =cut