| 1 | package Net::Braintree::AdvancedSearch; | ||||||||||
| 2 | |||||||||||
| 3 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 1 | ▶ | use vars qw(@ISA @EXPORT_OK); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 1 | ▶ | use Exporter; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 1 | our @ISA = qw(Exporter); | |||||||||
| 7 | 1 | our @EXPORT_OK = qw(search_to_hash); | |||||||||
| 8 | |||||||||||
| 9 | 0 | ▶ | sub search_to_hash { | ||||||||
|
Subroutine
search_to_hash: not called CC=3 SCAR=24.8
Pod
undocumented
| |||||||||||
| 10 | 0 | my ($self,$search) = @_; | |||||||||
| 11 | 0 | my $hash = {}; | |||||||||
| 12 | 0 | for my $attribute ($search->meta()->get_all_attributes) { | |||||||||
| 13 | 0 | my $field = $attribute->name; | |||||||||
| 14 | 0 | ▶ | if ($search->$field->active()) { | ||||||||
|
Branch: 1 branch
| |||||||||||
| 15 | 0 | $hash->{$field} = $search->$field->criteria; | |||||||||
| 16 | } | ||||||||||
| 17 | } | ||||||||||
| 18 | 0 | return $hash; | |||||||||
| 19 | } | ||||||||||
| 20 | |||||||||||
| 21 | 1 | 1; | |||||||||