| 1 | package Convert::Pheno::Context; | ||||||||||||
| 2 | |||||||||||||
| 3 | 138 | ▶ | use strict; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 4 | 138 | ▶ | use warnings; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 5 | 138 | ▶ | use autodie; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 6 | 138 | ▶ | use Convert::Pheno::BFF::DerivedEntities qw(compatibility_dataset_id); | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 7 | |||||||||||||
| 8 | 209 | ▶ | sub new { | ||||||||||
|
Subroutine
new: called CC=5 SCAR=16.2
Pod
undocumented
| |||||||||||||
| 9 | 209 | my ( $class, $args ) = @_; | |||||||||||
| 10 | 209 | ▶ | $args ||= {}; | ||||||||||
|
Condition50%1/2
$args ||= {}
MC/DC0%0/1
$args ||= {}
$args
Truth table50%1/2
A
A= $args
| |||||||||||||
| 11 | |||||||||||||
| 12 | my $self = { | ||||||||||||
| 13 | source_format => $args->{source_format}, | ||||||||||||
| 14 | target_format => $args->{target_format}, | ||||||||||||
| 15 | 209 | ▶ | entities => $args->{entities} ? [ @{ $args->{entities} } ] : [], | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 16 | 203 | ▶ | options => $args->{options} ? { %{ $args->{options} } } : {}, | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 17 | 209 | ▶ | resources => $args->{resources} ? { %{ $args->{resources} } } : {}, | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 18 | }; | ||||||||||||
| 19 | |||||||||||||
| 20 | 209 | return bless $self, $class; | |||||||||||
| 21 | } | ||||||||||||
| 22 | |||||||||||||
| 23 | 206 | ▶ | sub from_self { | ||||||||||
|
Subroutine
from_self: called CC=2 SCAR=7.1
Pod
undocumented
| |||||||||||||
| 24 | 206 | my ( $class, $self, $args ) = @_; | |||||||||||
| 25 | 206 | ▶ | $args ||= {}; | ||||||||||
|
Condition50%1/2
$args ||= {}
MC/DC0%0/1
$args ||= {}
$args
Truth table50%1/2
A
A= $args
| |||||||||||||
| 26 | |||||||||||||
| 27 | return $class->new( | ||||||||||||
| 28 | { | ||||||||||||
| 29 | source_format => $args->{source_format}, | ||||||||||||
| 30 | target_format => $args->{target_format}, | ||||||||||||
| 31 | entities => $args->{entities}, | ||||||||||||
| 32 | options => { | ||||||||||||
| 33 | method => $self->{method}, | ||||||||||||
| 34 | method_ori => $self->{method_ori}, | ||||||||||||
| 35 | stream => $self->{stream}, | ||||||||||||
| 36 | test => $self->{test}, | ||||||||||||
| 37 | verbose => $self->{verbose}, | ||||||||||||
| 38 | debug => $self->{debug}, | ||||||||||||
| 39 | datasetId => scalar compatibility_dataset_id($self), | ||||||||||||
| 40 | }, | ||||||||||||
| 41 | resources => { | ||||||||||||
| 42 | metaData => $self->{metaData}, | ||||||||||||
| 43 | convertPheno => $self->{convertPheno}, | ||||||||||||
| 44 | data_ohdsi_dict => $self->{data_ohdsi_dict}, | ||||||||||||
| 45 | exposures => $self->{exposures}, | ||||||||||||
| 46 | visit_occurrence => $self->{visit_occurrence}, | ||||||||||||
| 47 | }, | ||||||||||||
| 48 | } | ||||||||||||
| 49 | 206 | ); | |||||||||||
| 50 | } | ||||||||||||
| 51 | |||||||||||||
| 52 | 1 | ▶ | sub source_format { return $_[0]->{source_format} } | ||||||||||
|
Subroutine
source_format: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 53 | 25139 | ▶ | sub target_format { return $_[0]->{target_format} } | ||||||||||
|
Subroutine
target_format: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 54 | 47930 | ▶ | sub entities { return $_[0]->{entities} } | ||||||||||
|
Subroutine
entities: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 55 | 25105 | ▶ | sub options { return $_[0]->{options} } | ||||||||||
|
Subroutine
options: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 56 | 1 | ▶ | sub resources { return $_[0]->{resources} } | ||||||||||
|
Subroutine
resources: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 57 | |||||||||||||
| 58 | 138 | 1; | |||||||||||