| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
# This code is part of Perl distribution Couch-DB version 0.201. |
|
2
|
|
|
|
|
|
|
# The POD got stripped from this file by OODoc version 3.06. |
|
3
|
|
|
|
|
|
|
# For contributors see file ChangeLog. |
|
4
|
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
# This software is copyright (c) 2024-2026 by Mark Overmeer. |
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
# This is free software; you can redistribute it and/or modify it under |
|
8
|
|
|
|
|
|
|
# the same terms as the Perl 5 programming language system itself. |
|
9
|
|
|
|
|
|
|
# SPDX-License-Identifier: Artistic-1.0-Perl OR GPL-1.0-or-later |
|
10
|
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
# SPDX-FileCopyrightText: 2024 Mark Overmeer <mark@overmeer.net> |
|
13
|
|
|
|
|
|
|
# SPDX-License-Identifier: Artistic-2.0 |
|
14
|
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
package Couch::DB::Row;{ |
|
16
|
|
|
|
|
|
|
our $VERSION = '0.201'; |
|
17
|
|
|
|
|
|
|
} |
|
18
|
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
|
|
20
|
1
|
|
|
1
|
|
1456
|
use warnings; |
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
103
|
|
|
21
|
1
|
|
|
1
|
|
8
|
use strict; |
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
34
|
|
|
22
|
|
|
|
|
|
|
|
|
23
|
1
|
|
|
1
|
|
5
|
use Log::Report 'couch-db'; |
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
8
|
|
|
24
|
|
|
|
|
|
|
|
|
25
|
1
|
|
|
1
|
|
343
|
use Couch::DB::Util; |
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
8
|
|
|
26
|
1
|
|
|
1
|
|
8
|
use Scalar::Util qw/weaken/; |
|
|
1
|
|
|
|
|
3
|
|
|
|
1
|
|
|
|
|
396
|
|
|
27
|
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
#-------------------- |
|
29
|
|
|
|
|
|
|
|
|
30
|
0
|
|
|
0
|
1
|
|
sub new(@) { my ($class, %args) = @_; (bless {}, $class)->init(\%args) } |
|
|
0
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
sub init($) |
|
33
|
0
|
|
|
0
|
0
|
|
{ my ($self, $args) = @_; |
|
34
|
|
|
|
|
|
|
|
|
35
|
0
|
0
|
|
|
|
|
$self->{CDR_result} = delete $args->{result} or panic; |
|
36
|
0
|
|
|
|
|
|
weaken $self->{CDR_result}; |
|
37
|
|
|
|
|
|
|
|
|
38
|
0
|
|
|
|
|
|
$self->{CDR_doc} = delete $args->{doc}; |
|
39
|
0
|
0
|
|
|
|
|
$self->{CDR_answer} = delete $args->{answer} or panic; |
|
40
|
0
|
|
|
|
|
|
$self->{CDR_values} = delete $args->{values}; |
|
41
|
0
|
0
|
|
|
|
|
$self->{CDR_rownr} = delete $args->{rownr} or panic; |
|
42
|
0
|
|
|
|
|
|
$self; |
|
43
|
|
|
|
|
|
|
} |
|
44
|
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
#-------------------- |
|
46
|
|
|
|
|
|
|
|
|
47
|
0
|
|
|
0
|
1
|
|
sub result() { $_[0]->{CDR_result} } |
|
48
|
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
|
|
50
|
0
|
|
|
0
|
1
|
|
sub doc() { $_[0]->{CDR_doc} } |
|
51
|
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
|
|
53
|
0
|
|
|
0
|
1
|
|
sub answer() { $_[0]->{CDR_answer} } |
|
54
|
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
|
|
56
|
0
|
0
|
|
0
|
1
|
|
sub values() { $_[0]->{CDR_values} || $_[0]->answer } |
|
57
|
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
#-------------------- |
|
59
|
|
|
|
|
|
|
|
|
60
|
0
|
|
|
0
|
1
|
|
sub pageNumber() { $_[0]->result->pageNumber } |
|
61
|
0
|
|
|
0
|
1
|
|
sub rowNumberInPage() { ... } |
|
62
|
0
|
|
|
0
|
1
|
|
sub rowNumberInSearch() { ... } |
|
63
|
0
|
|
|
0
|
1
|
|
sub rowNumberInResult() { $_[0]->{CDR_rownr} } |
|
64
|
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
1; |