blib/lib/HTML/Object/DOM/NodeIterator.pm untested

filter: Statementstmt 0.0% 0 / 33 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 13 Podpod 0.0% 0 / 5 totaltotal 0.0% 0 / 51 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
detach
2.0
pointerBeforeReferenceNode
2.0
CRAP 2.0
1 ##----------------------------------------------------------------------------
2 ## HTML Object - ~/lib/HTML/Object/DOM/NodeIterator.pm
3 ## Version v0.2.0
4 ## Copyright(c) 2021 DEGUEST Pte. Ltd.
5 ## Author: Jacques Deguest <jack@deguest.jp>
6 ## Created 2021/12/20
7 ## Modified 2022/09/18
8 ## All rights reserved.
9 ##
10 ##
11 ## This program is free software; you can redistribute it and/or modify it
12 ## under the same terms as Perl itself.
13 ##----------------------------------------------------------------------------
14 package HTML::Object::DOM::NodeIterator;
15 BEGIN
16 {
17 use strict;
18 use warnings;
19 warnings::register_categories( 'HTML::Object' );
20 use parent qw( HTML::Object::DOM::NodeIteratorShared );
21 use vars qw( $VERSION );
22 # To import its constants
23 use HTML::Object::DOM::Node;
24 use HTML::Object::DOM::NodeFilter qw( :all );
25 our $VERSION = 'v0.2.0';
26 };
27  
28 use strict;
29 use warnings;
30  
31 # Note: method init is inherited
32  
33 sub detach { return; }
34  
35 # Note: property expandEntityReferences read-only is inherited
36  
37 # Note: property filter read-only inherited
38  
39 # Note: method nextNode is inherited
40  
41 # Note: property pointerBeforeReferenceNode read-only
42 sub pointerBeforeReferenceNode : lvalue { return( shift->_set_get_boolean( 'pointerbeforereferencenode', @_ ) ); }
43  
44 sub pos { return( shift->{_relative_pos} ); }
45  
46 # Note: method previousNode is inherited
47  
48 # Note: property referenceNode read-only
49 sub referenceNode
50 {
51 my $self = shift( @_ );
52 my $elems = $self->_elements;
53 return( $elems->index( $self->{_pos} ) );
54 }
55  
56 # Note: property root read-only is inherited
57  
58 # Note: property whatToShow read-only is inherited
59  
60 1;
61 # NOTE: POD
62 __END__