line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::Lyskom::DynamicSession; |
2
|
1
|
|
|
1
|
|
6
|
use base qw{Net::Lyskom::Object}; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
73
|
|
3
|
1
|
|
|
1
|
|
6
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
63
|
|
4
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
11
|
|
|
1
|
|
|
|
|
29
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
5
|
use Net::Lyskom::Util qw{:all}; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
531
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
=head1 NAME |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
Net::Lyskom::DynamicSession - dynamic session info object |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
=head1 SYNOPSIS |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
print "This session has been idle for ",$obj->idle_time, " seconds.\n"; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=head1 DESCRIPTION |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
=over |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=item ->session() |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
Session number. |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=item ->person() |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
Person number. |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=item ->working_conference() |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
Number of working conference. |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=item ->idle_time() |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
Number of seconds idle or number of seconds since session was created. |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=item ->what_am_i_doing() |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
What the client says it is doing. |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=item ->invisible() |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
This session has requested that it be invisible. |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=item ->user_active_used() |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
True if the client has issued a C call, which means that |
47
|
|
|
|
|
|
|
the various idle-time counters count idle time rather than time since |
48
|
|
|
|
|
|
|
creation. |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=item ->user_absent() |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
This flag is not used. |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=back |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=cut |
57
|
|
|
|
|
|
|
|
58
|
0
|
|
|
0
|
1
|
0
|
sub session {my $s = shift; return $s->{session}} |
|
0
|
|
|
|
|
0
|
|
59
|
0
|
|
|
0
|
1
|
0
|
sub person {my $s = shift; return $s->{person}} |
|
0
|
|
|
|
|
0
|
|
60
|
0
|
|
|
0
|
1
|
0
|
sub working_conference {my $s = shift; return $s->{working_conference}} |
|
0
|
|
|
|
|
0
|
|
61
|
0
|
|
|
0
|
1
|
0
|
sub idle_time {my $s = shift; return $s->{idle_time}} |
|
0
|
|
|
|
|
0
|
|
62
|
0
|
|
|
0
|
1
|
0
|
sub what_am_i_doing {my $s = shift; return $s->{what_am_i_doing}} |
|
0
|
|
|
|
|
0
|
|
63
|
|
|
|
|
|
|
|
64
|
0
|
|
|
0
|
1
|
0
|
sub invisible {my $s = shift; return $s->{invisible}} |
|
0
|
|
|
|
|
0
|
|
65
|
0
|
|
|
0
|
1
|
0
|
sub user_active_used {my $s = shift; return $s->{user_active_used}} |
|
0
|
|
|
|
|
0
|
|
66
|
0
|
|
|
0
|
1
|
0
|
sub user_absent {my $s = shift; return $s->{user_absent}} |
|
0
|
|
|
|
|
0
|
|
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
sub new_from_stream { |
69
|
261
|
|
|
261
|
0
|
310
|
my $s = {}; |
70
|
261
|
|
|
|
|
306
|
my $class = shift; |
71
|
261
|
|
|
|
|
242
|
my $res = shift; |
72
|
|
|
|
|
|
|
|
73
|
261
|
50
|
|
|
|
430
|
$class = ref($class) if ref($class); |
74
|
261
|
|
|
|
|
483
|
bless $s,$class; |
75
|
|
|
|
|
|
|
|
76
|
261
|
|
|
|
|
229
|
$s->{session} = shift @{$res}; |
|
261
|
|
|
|
|
510
|
|
77
|
261
|
|
|
|
|
248
|
$s->{person} = shift @{$res}; |
|
261
|
|
|
|
|
366
|
|
78
|
261
|
|
|
|
|
231
|
$s->{working_conference} = shift @{$res}; |
|
261
|
|
|
|
|
362
|
|
79
|
261
|
|
|
|
|
225
|
$s->{idle_time} = shift @{$res}; |
|
261
|
|
|
|
|
415
|
|
80
|
261
|
|
|
|
|
238
|
my $flags = shift @{$res}; |
|
261
|
|
|
|
|
333
|
|
81
|
261
|
|
|
|
|
265
|
$s->{what_am_i_doing} = shift @{$res}; |
|
261
|
|
|
|
|
363
|
|
82
|
|
|
|
|
|
|
|
83
|
261
|
|
|
|
|
2006
|
($s->{invisible}, $s->{user_active_used}, $s->{user_absent}) |
84
|
|
|
|
|
|
|
= $flags =~ /./g; |
85
|
|
|
|
|
|
|
|
86
|
261
|
|
|
|
|
1229
|
return $s; |
87
|
|
|
|
|
|
|
} |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
1; |