InvalidSchemaPropertyException::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 1 Features 0
Metric Value
c 2
b 1
f 0
dl 0
loc 6
rs 9.4286
cc 1
eloc 3
nc 1
nop 2
1
<?php
2
/**
3
 * Author: Nil Portugués Calderó <[email protected]>
4
 * Date: 12/18/15
5
 * Time: 10:26 AM.
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
namespace NilPortugues\SchemaOrg;
12
13
/**
14
 * Class InvalidSchemaPropertyException.
15
 */
16
class InvalidSchemaPropertyException extends \InvalidArgumentException
17
{
18
    /**
19
     * @param string $propertyName
20
     * @param string $schemaClass
21
     */
22
    public function __construct($propertyName, $schemaClass)
23
    {
24
        $message = sprintf("Property '%s' is not allowed for schema '%s'.", $propertyName, $schemaClass);
25
26
        parent::__construct($message);
27
    }
28
}
29