1: <?php
2:
3: /**
4: * Copyright 2015, Eduardo Trujillo
5: *
6: * For the full copyright and license information, please view the LICENSE
7: * file that was distributed with this source code.
8: *
9: * This file is part of the Nucleus package
10: */
11:
12: namespace Chromabits\Nucleus\Meditation\Interfaces;
13:
14: use Chromabits\Nucleus\Meditation\SpecResult;
15:
16: /**
17: * Interface CheckableInterface.
18: *
19: * Describes an object that can be checked against a set of constraints (a
20: * specification) and return a result describing the result of the computation.
21: *
22: * @author Eduardo Trujillo <ed@chromabits.com>
23: * @package Chromabits\Nucleus\Meditation\Interfaces
24: */
25: interface CheckableInterface
26: {
27: /**
28: * Check that a certain input passes the spec or constraint collection.
29: *
30: * @param mixed $input
31: *
32: * @return SpecResult
33: */
34: public function check(array $input);
35: }
36: