1171 |
} else { |
} else { |
1172 |
if (@_ > 1) { |
if (@_ > 1) { |
1173 |
## Step 1 |
## Step 1 |
1174 |
require Whatpm::XMLParser; # MUST |
require Whatpm::XML::Parser; # MUST |
1175 |
my $doc = $self->implementation->create_document; |
my $doc = $self->implementation->create_document; |
1176 |
|
|
1177 |
## Step 2 |
## Step 2 |
1178 |
# |
# |
1179 |
|
|
1180 |
## Step 3 |
## Step 3 |
1181 |
$doc = Whatpm::XMLParser->parse_string ($_[1] => $doc); # MUST |
$doc = Whatpm::XML::Parser->parse_char_string ($_[1] => $doc); # MUST |
1182 |
|
|
1183 |
## Step 4 |
## Step 4 |
1184 |
# |
# |
1191 |
for (@cn) { |
for (@cn) { |
1192 |
$self->remove_child ($_); |
$self->remove_child ($_); |
1193 |
} |
} |
1194 |
|
## TODO: strict-document-children option? |
1195 |
|
|
1196 |
## Step 7, 8, 9, 10 |
## Step 7, 8, 9, 10 |
1197 |
for my $node (@{$doc->child_nodes}) { |
for my $node (@{$doc->child_nodes}) { |