Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
0.00% covered (danger)
0.00%
0 / 3
0.00% covered (danger)
0.00%
0 / 2
CRAP
0.00% covered (danger)
0.00%
0 / 1
No_Validator_Exception
0.00% covered (danger)
0.00%
0 / 3
0.00% covered (danger)
0.00%
0 / 2
6
0.00% covered (danger)
0.00%
0 / 1
 __construct
0.00% covered (danger)
0.00%
0 / 2
0.00% covered (danger)
0.00%
0 / 1
2
 get_address
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
1<?php
2/**
3 * If there is no validator available for the address, return this exception.
4 */
5
6namespace BrianHenryIE\WC_Address_Validation\API\Validators;
7
8use Exception;
9use Throwable;
10
11class No_Validator_Exception extends Exception {
12
13    public function __construct( array $address, $message = '', $code = 0, Throwable $previous = null ) {
14        parent::__construct( $message, $code, $previous );
15        $this->address = $address;
16    }
17
18    protected array $address;
19
20    /**
21     * @return array
22     */
23    public function get_address(): array {
24        return $this->address;
25    }
26}