| 1 | package Sisimai::Reason::HasMoved; | ||||||||||||
| 2 | 68 | ▶ | use v5.26; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 3 | 68 | ▶ | use strict; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 4 | 68 | ▶ | use warnings; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 5 | 68 | ▶ | use Sisimai::Eb; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 6 | |||||||||||||
| 7 | 1 | ▶ | sub text { $Sisimai::Eb::ReMOVE } | ||||||||||
|
Subroutine
text: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||||
| 8 | 4 | ▶ | sub description { "Email rejected due to user's mailbox has moved and is not forwarded automatically" } | ||||||||||
|
Subroutine
description: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||
| 9 | 2395 | ▶ | sub match { | ||||||||||
|
Subroutine
match: called CC=3 SCAR=11.0
Pod
documented
| |||||||||||||
| 10 | # Try to match that the given text and regular expressions | ||||||||||||
| 11 | # @param [String] argv1 String to be matched with regular expressions | ||||||||||||
| 12 | # @return [Integer] 0: Did not match | ||||||||||||
| 13 | # 1: Matched | ||||||||||||
| 14 | # @since v4.1.25 | ||||||||||||
| 15 | 2395 | my $class = shift; | |||||||||||
| 16 | 2395 | ▶ | my $argv1 = shift // return 0; | ||||||||||
|
Condition100%2/2
shift() // (return 0)
MC/DC100%1/1
shift() // (return 0)
shift()
Truth table100%2/2
A
A= shift()
| |||||||||||||
| 17 | |||||||||||||
| 18 | 2394 | state $index = [' has been replaced by ']; | |||||||||||
| 19 | 2394 | ▶ | return 1 if grep { rindex($argv1, $_) > -1 } @$index; | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 20 | 2392 | return 0; | |||||||||||
| 21 | } | ||||||||||||
| 22 | |||||||||||||
| 23 | 2109 | ▶ | sub true { | ||||||||||
|
Subroutine
true: called CC=4 SCAR=13.9
Pod
undocumented
| |||||||||||||
| 24 | # Whether the address has moved or not | ||||||||||||
| 25 | # @param [Sisimai::Fact] argvs Object to be detected the reason | ||||||||||||
| 26 | # @return [Integer] 1: The address has moved | ||||||||||||
| 27 | # 0: Has not moved | ||||||||||||
| 28 | # @since v4.1.25 | ||||||||||||
| 29 | # @see http://www.ietf.org/rfc/rfc2822.txt | ||||||||||||
| 30 | 2109 | my $class = shift; | |||||||||||
| 31 | 2109 | ▶ | my $argvs = shift // return 0; | ||||||||||
|
Condition100%2/2
shift() // (return 0)
MC/DC100%1/1
shift() // (return 0)
shift()
Truth table100%2/2
A
A= shift()
| |||||||||||||
| 32 | |||||||||||||
| 33 | 2108 | require Sisimai::SMTP::Command; | |||||||||||
| 34 | 2108 | ▶ | return 1 if $argvs->{'reason'} eq $Sisimai::Eb::ReMOVE; | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 35 | 2107 | ▶ | return 0 if grep { $argvs->{'command'} eq $_ } Sisimai::SMTP::Command->BeforeRCPT->@*; | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 36 | 1880 | return __PACKAGE__->match(lc $argvs->{'diagnosticcode'}); | |||||||||||
| 37 | } | ||||||||||||
| 38 | |||||||||||||
| 39 | 68 | 1; | |||||||||||
| 40 | __END__ | ||||||||||||