Added the zend framework 2 library, the path is specified in line no.26 in zend_modul...
[openemr.git] / interface / modules / zend_modules / library / Zend / Db / Sql / Predicate / IsNull.php
blobf53f94cac5e85f7ec694360d240a1b9218ca0f5a
1 <?php
2 /**
3 * Zend Framework (http://framework.zend.com/)
5 * @link http://github.com/zendframework/zf2 for the canonical source repository
6 * @copyright Copyright (c) 2005-2013 Zend Technologies USA Inc. (http://www.zend.com)
7 * @license http://framework.zend.com/license/new-bsd New BSD License
8 */
10 namespace Zend\Db\Sql\Predicate;
12 class IsNull implements PredicateInterface
15 /**
16 * @var string
18 protected $specification = '%1$s IS NULL';
20 /**
21 * @var
23 protected $identifier;
25 /**
26 * Constructor
28 * @param string $identifier
30 public function __construct($identifier = null)
32 if ($identifier) {
33 $this->setIdentifier($identifier);
37 /**
38 * Set identifier for comparison
40 * @param string $identifier
41 * @return IsNull
43 public function setIdentifier($identifier)
45 $this->identifier = $identifier;
46 return $this;
49 /**
50 * Get identifier of comparison
52 * @return null|string
54 public function getIdentifier()
56 return $this->identifier;
59 /**
60 * Set specification string to use in forming SQL predicate
62 * @param string $specification
63 * @return IsNull
65 public function setSpecification($specification)
67 $this->specification = $specification;
68 return $this;
71 /**
72 * Get specification string to use in forming SQL predicate
74 * @return string
76 public function getSpecification()
78 return $this->specification;
81 /**
82 * Get parts for where statement
84 * @return array
86 public function getExpressionData()
88 return array(array(
89 $this->getSpecification(),
90 array($this->identifier),
91 array(self::TYPE_IDENTIFIER),
92 ));