← Index
NYTProf Performance Profile   « line view »
For ./view
  Run on Fri Jul 31 19:05:14 2015
Reported on Fri Jul 31 19:08:10 2015

Filename/var/www/foswiki11/lib/Foswiki/If/OP_isempty.pm
StatementsExecuted 10 statements in 348µs
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
11124µs48µsFoswiki::If::OP_isempty::::newFoswiki::If::OP_isempty::new
11123µs41µsFoswiki::If::OP_isempty::::BEGIN@11Foswiki::If::OP_isempty::BEGIN@11
11113µs20µsFoswiki::If::OP_isempty::::BEGIN@12Foswiki::If::OP_isempty::BEGIN@12
1115µs5µsFoswiki::If::OP_isempty::::BEGIN@14Foswiki::If::OP_isempty::BEGIN@14
0000s0sFoswiki::If::OP_isempty::::evaluateFoswiki::If::OP_isempty::evaluate
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1# See bottom of file for license and copyright information
2
3=begin TML
4
5---+ package Foswiki::If::OP_isempty
6
7=cut
8
9package Foswiki::If::OP_isempty;
10
11241µs259µs
# spent 41µs (23+18) within Foswiki::If::OP_isempty::BEGIN@11 which was called: # once (23µs+18µs) by Foswiki::If::Parser::new at line 11
use strict;
# spent 41µs making 1 call to Foswiki::If::OP_isempty::BEGIN@11 # spent 18µs making 1 call to strict::import
12238µs227µs
# spent 20µs (13+7) within Foswiki::If::OP_isempty::BEGIN@12 which was called: # once (13µs+7µs) by Foswiki::If::Parser::new at line 12
use warnings;
# spent 20µs making 1 call to Foswiki::If::OP_isempty::BEGIN@12 # spent 7µs making 1 call to warnings::import
13
142231µs15µs
# spent 5µs within Foswiki::If::OP_isempty::BEGIN@14 which was called: # once (5µs+0s) by Foswiki::If::Parser::new at line 14
use Foswiki::Query::UnaryOP ();
# spent 5µs making 1 call to Foswiki::If::OP_isempty::BEGIN@14
15111µsour @ISA = ('Foswiki::Query::UnaryOP');
16
17
# spent 48µs (24+24) within Foswiki::If::OP_isempty::new which was called: # once (24µs+24µs) by Foswiki::If::Parser::new at line 31 of /var/www/foswiki11/lib/Foswiki/If/Parser.pm
sub new {
181800ns my $class = shift;
19122µs124µs return $class->SUPER::new( name => 'isempty', prec => 600 );
# spent 24µs making 1 call to Foswiki::Query::UnaryOP::new
20}
21
22sub evaluate {
23 my $this = shift;
24 my $node = shift;
25 my $a = $node->{params}->[0];
26 my %domain = @_;
27 my $session = $domain{tom}->session;
28 throw Error::Simple(
29 'No context in which to evaluate "' . $a->stringify() . '"' )
30 unless $session;
31 my $eval = $a->_evaluate(@_);
32 return 1 unless $eval;
33 return 0 if ( $session->{request}->param($eval) );
34 return 0 if ( $session->{prefs}->getPreference($eval) );
35 return 1;
36}
37
3814µs1;
39__END__