line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package JavaScript::Code::Value;
|
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
14
|
use strict;
|
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
68
|
|
4
|
2
|
|
|
2
|
|
10
|
use vars qw[ $VERSION ];
|
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
75
|
|
5
|
2
|
|
|
2
|
|
10
|
use base qw[ Clone ];
|
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
127
|
|
6
|
2
|
|
|
2
|
|
11
|
use JavaScript::Code::Variable ();
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
286
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
$VERSION = '0.08';
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
JavaScript::Code::Value - A JavaScript Value
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=head2 SYNOPSIS
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
use base qw[ JavaScript::Code::Value ];
|
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
=head1 DESCRIPTION
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
A value can e.g. be assigned to a variable.
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=head1 METHODS
|
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=head2 $self->can_be_assigned( )
|
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
=cut
|
27
|
|
|
|
|
|
|
|
28
|
0
|
|
|
0
|
1
|
|
sub can_be_assigned { return 1; }
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=head2 $self->as_variable( ... )
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=cut
|
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub as_variable {
|
36
|
0
|
|
|
0
|
1
|
|
my $self = shift;
|
37
|
0
|
|
|
|
|
|
my $args = $self->args(@_);
|
38
|
|
|
|
|
|
|
|
39
|
0
|
|
|
|
|
|
return JavaScript::Code::Variable->new(
|
40
|
|
|
|
|
|
|
name => $args->{name},
|
41
|
|
|
|
|
|
|
value => $self
|
42
|
|
|
|
|
|
|
);
|
43
|
|
|
|
|
|
|
}
|
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=head1 SEE ALSO
|
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
L, L
|
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 AUTHOR
|
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
Sascha Kiefer, C
|
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head1 LICENSE
|
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
This library is free software, you can redistribute it and/or modify it under
|
56
|
|
|
|
|
|
|
the same terms as Perl itself.
|
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=cut
|
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
1;
|