diff lib/IMPL/DOM/XMLReader.pm @ 411:ee36115f6a34 ref20150831

sync
author cin
date Mon, 21 Sep 2015 00:53:10 +0300
parents c6e90e02dd17
children
line wrap: on
line diff
--- a/lib/IMPL/DOM/XMLReader.pm	Mon Sep 14 01:11:53 2015 +0300
+++ b/lib/IMPL/DOM/XMLReader.pm	Mon Sep 21 00:53:10 2015 +0300
@@ -2,25 +2,35 @@
 use strict;
 use warnings;
 
-use parent qw(IMPL::Object IMPL::Object::Autofill);
+use XML::Parser;
 
-use IMPL::Class::Property;
-use XML::Parser;
+use IMPL::declare {
+	require => {
+		Schema => 'IMPL::DOM::Schema', # IMPL::DOM::Schema references IMPL::DOM::XML::Reader
+    	Builder => 'IMPL::DOM::Navigator::Builder',
+    	SimpleBuilder => 'IMPL::DOM::Navigator::SimpleBuilder'		
+	},
+	base => [
+		'IMPL::Object' => undef
+	],
+	props => [
+		Navigator => '*r',
+		SkipWhitespace => '*r',
+		_current => '*rw',
+		_text => '*rw',
+		_textHistory => '*rw'
+	]
+};
 
 use IMPL::require {
-    Schema => 'IMPL::DOM::Schema', # IMPL::DOM::Schema references IMPL::DOM::XML::Reader
-    Builder => 'IMPL::DOM::Navigator::Builder',
-    SimpleBuilder => 'IMPL::DOM::Navigator::SimpleBuilder'
+    
 };
 
-__PACKAGE__->PassThroughArgs;
-
-BEGIN {
-    public _direct property Navigator => prop_get | owner_set;
-    public _direct property SkipWhitespace => prop_get | owner_set;
-    private _direct property _current => prop_all;
-    private _direct property _text => prop_all;
-    private _direct property _textHistory => prop_all;
+sub CTOR {
+	my ($this, %params) = @_;
+	
+	$this->{$Navigator} = $params{Navigator} if $params{Navigator};
+	$this->{$SkipWhitespace} = $params{SkipWhitespace} if $params{SkipWhitespace};
 }
 
 sub Parse {